Add Component (Location) - Multiple 'bakes' (transactions?) to Revit

I am currently using Rhino Inside Revit to place Enscape Planting Families on named Revit topo subregions.

There is a bit of scattering and density changes that I want to only display in Rhino as bounding boxes (quick!) and delay the placement of the actual component with a boolean+gate.

This works once, but subsequent toggles just replace the previous component. The undo from the previous series of place components remain listed, but the components themselves disappear.

Is this because the entirety of the script is wrapped in a single transaction? Are there ways to have independent ‘bakes’ to Revit? (beyond saving, closing and reopening)

try adding a separate Add Component for the Sub2

Thanks Rickson,

If I understand you correctly, I can just add multiple subregions and the script to write accordingly. (see images) That’s not the problem.

I think the idea I am striving for is that this is an interface for any number of subregions and settings. I don’t want to explicitly place an add component for each sub region. I want the user to be able to select a single or multiple, change density (per regions selected) and then bake… and then possibly repeat as many times as they want without overwriting previous iterations. It is a step-wise process.

@kike
@eirannejad

So many ways to do this. The question is what works best?

For selecting between 2 inputs at the press of a button, I sometimes use Pick N Choose with a Boolean:
image

For selecting between detailed and not detailed display, you could use a Shared Parameter on the objects to use View Filters between the detailed and the not detailed version of the trees. Of course both versions are then baked into the Revit file.

We are also experimenting with a Sub-category creator. You could create a Tree Family with all the Trees in the Site Category, then have the detailed trees in one custom sub-category and the simple trees in a different custom sub-category.

1 Like

Thanks @scottd! All exciting developments.

I think I am trying and failing to describe the exact problem. It is really about persistence - when I send different data to the Component by Location - it replaces the previous iteration. Which makes sense to some degree - I want to know a mechanism for breaking that realtime connection in Revit ala baking geometry in Rhino.

I want to let a user select a sub region, change density and mix for that sub region and then ‘bake’ to components in Revit.

I want them then to repeat this step for a different subregion, with possibly different scattering settings.

I have this all working. The problem is that each subsequent push of the ‘Bake’ button unleashing the component info to the Add Component (By Location) then replaces the previous iteration.

I already have a button that acts as a data dam that lets me iterate in rhino/gh and then save the most expensive (read slowest) step for last - placing the component. It is not a problem of Sub 1 or 2 - I want this to work with a topo with 30 sub regions or 2 or 4 or 5…

What I have now - does what my very first gif shows - each ‘bake’ unleashed by pressing the button - replaces the previous ‘bake’.

Button

Gate

i still don’t quite follow,do you want to keep part of the previous iteration?

Sub1 gets baked. A partial selection of Sub1 is mo
dified and replaces part of Sub1 as Sub2? But currently all of Sub1 is replaced with Sub2.

yes, i want to know if there is a mechanism to remove outputs from the garbage collection that occurs in every grasshopper cycle.

like in grasshopper - when you bake an output, it is no longer modified by any component.

an absolutely filthy hack:

Here is a rough workflow, something like this might work. Requires Revit Filters based on parameter then referenced in a Graphical Element.

sub1sub2delete.gh (16.4 KB)

Sub1Sub2Delete.zip (1.4 MB) (revit 2019 blank file with filters created)

change param

push toggle, refresh

So as long as the filters were setup a user could select the desired area, select sub param, do GH adjustments and bake, leaving sub1, sub2 intact, adding sub3

Hey @Rickson - sorry for the late reply. But this is an epic test - much appreciated.

I also found a way to make this work without 1. making filters 2. closing and reopening gh

If I unpin the elements, that seems to break the binding and allows multiple ‘bakes’

Ultimately, this Rhino Inside test has made we just want to understand how all of this is being handled on the backend. Ideally, we could ‘bake’ things without having a user build up infrastructure (filters) beforehand or have to right click an output.

I feel like the larger discussion of the GH loop, Revit Database and insertion would be tackled in https://www.rhino3d.com/inside/revit/beta/reference/rir-arch#element-binding

@kike
@eirannejad

Yes, unpinning right now does break the bond with Rhino.Inside. That probably will always be true, but we are also working on a more official Binding scheme that should allow binding across multiple sessions. Once we get that prototyped we will let everyone play with it and also start filling out the docs.

2 Likes

Hi all,

I’m facing the same problem, but it seems like the “unpin” solution doesn’t work anymore.
As soon as I unpin the first family it fails to generate the second.

I’m trying to create a simple generic geometry transfer script for some of my colleagues with little to no grasshopper experience, therefore it would be great if there was a “non-hacky” solution for it.

I uploaded my files below, thank you in advance.

RhinoInside_GeometryTransfer_TroubleShoot.gh (672.0 KB) RhinoInside_GeometryTransfer_TroubleShoot.gh.3dm (56.7 KB)

I believe they are on the verge of releasing a big change which allows better persistence control in the Rhino-Revit exchange – probably best to hold off until this gets implemented.

1 Like

Hi all,

is there any update on the element binding feature? Unpinning elements is still not working.

Yes, Element Binding is fully functioning but now referred to as Element Tracking.

https://www.rhino3d.com/inside/revit/1.0/guides/rir-grasshopper#element-tracking

1 Like