I would attest to @qythium’s post.
Telepathy can help you organize your canvas in very distinct groups, separated according to functionality.
In an example bellow, there is a small definition where all inputs are on the left, and all outputs on the right:
that way, no matter how many such groups you have on your canvas, there is no spaghetti between them and you can move them (the groups) around as you wish.
In my experience it is best to avoid letting definitions get that big in the first place. Once a gh file gets really large, it’s pretty unlikely it will solve interactively, so there’s not a whole lot of benefit keeping it all together.
I’m a big fan of this approach, Elefront enables you to break projects up into multiple files. For example an architectural project might be structured like this:
- massing.gh
- panelization.gh
- rationalisation.gh
- fabrication.gh
where the input for each gh is the previous file. Since Elefront allows you to re-reference your data-structure as it was when it was baked in the previous step, the hassle of re selecting inputs disappears. You can think of each gh file as a node in your project graph as this paper describes.
I find breaking large projects up into multiple files makes maintenance,collaboration and re-use much easier.
Thanks for all the valuable info.
I am aware that big GH definitions should be avoided and clean separation and organization is a must, but when you are searching for a solution the project gets messy, once found the path then you can rebuild and organize it.
If you have access to Rhino6, check out the Data Input and Data Output components (Params.Util panel). They allow you to store any number of data trees in separate files.
For those of us who have to maintain compatibility with Rhino5, is there any way via Python/C# scripting for data trees to be serialized into a file and referenced from another Grasshopper definition?
I’ve been using data = clr.Serialize(param.VolatileData[0][0].Value)andparam.SetPersistentData(clr.Deserialize(data)) as an ad-hoc way of saving Grasshopper geometry into JSON files, where param
is of type GH_PersistentParam\<T>
But of course this only works when the param tree has a single branch and leaf - when I attempt the above with the entire GH_Structure, it produces a not marked as Serializable
error.
@dave_stasiuk’s Pack Data
and Unpack Data
from TreeSloth does this (if I recall correctly). Maybe have a look at those.
Thanks David, I have Rhino6 at home, but work hasn’t upgraded yet Will check it out when i get a chance, sounds like very powerful functionality.
You mean the Corporate license?
ps. Wire colours can be editing by modifying the grasshopper_gui.xml
file:
<item name="wire_default" type_name="gh_drawing_color" type_code="36">
<ARGB>150;0;0;0</ARGB>
</item>
<item name="wire_empty" type_name="gh_drawing_color" type_code="36">
<ARGB>180;255;60;0</ARGB>
</item>
<item name="wire_selected_a" type_name="gh_drawing_color" type_code="36">
<ARGB>255;125;210;40</ARGB>
</item>
<item name="wire_selected_b" type_name="gh_drawing_color" type_code="36">
<ARGB>50;0;0;0</ARGB>
</item>
wire_selected_a
is the selected end of a wire, wire_selected_b
is the unselected end of a wire (assuming the other end is selected). If neither end is selected then wire_default
is used, unless the wire transports no data, in which case wire_empty
is used.
Do note that even if you make wires invisible, they will still ‘be’ there and when you double click a relay may be inserted into seemingly empty space. I predict you will loathe not seeing wires within the hour. You can however make them very transparent.
Please explain, is this a thing? Since when? Is this based on Rhino License or a separate license?
The ‘Corporate
’ license refers to pirated copies of Rhino that appear on the forum once in a while…
And, no, those definitely don’t have any added features.
Well, I thought someone would understand the joke…:
how can you have multiple wire colours if you just have four xml entries?. How can you override wire appearance. That’s not possible with an unhacked grasshopper. You did not present any possibility to override them traditionally, so I modified it in areas not intended. I’m not sure if this already violates GH License agreements, but as long as I don’t share this, I’m not doing anything illegal
I’m basically just posting that its possible.
So no, I’m not referring to a pirated version of Rhino.
Downloaded Telepathy but it does not show up
I see this message on the Rhino prompt:
Exception System.NotSupportedException:
Message: An attempt was made to load an assembly from a network location which would have caused the assembly to be sandboxed in previous versions of the .NET Framework
Not sure what to do here
rightclick onto the .gha/.dll and make sure its unblocked. Reopen Rhino/GH
I was just joking because cracked copies of Rhino show up as ‘Corporate’. It’s not a real type of license, we only have Commercial, Educational, and Trial (all have the same functionality, it’s only a legal difference).
Since @TomTom (h/cr)acked his Grasshopper I thought it would be more appropriate. To be clear, he’s doing nothing unethical, just unesthetical
I’m just trying hard to find a way against spaghetti style, without spending hours in rearranging components for each definition.
I indeed believe that different colour can simplify reading more complex definitions. Jagged wires improve top-to-bottom arrangement of components. You might noticed the difference between last versions. I’m not saying that’s it. I’m just playing around
Unblocked it but message comes up
and component does not load
could send an empty 3dm file?
I know, it’s all good. I’m just glad there’s no surviving images on the web from the first few internal versions of GH. That stuff looked horrible.
@TomTom that’s funny… this is an old wish, from early days it was always possible to change GH canvas and people interested in it: