Feature Request: Graft Input by Lists

@DavidRutten

Hello David!

I’d like to suggest a new type of grafting: To me it would be very useful to be able to graft inputs by lists. Meaning, that if I connect 2 or more lists into a component, I could graft them in a way that each list is a new branch in the resulting tree, rather than each item is its own branch. This feature would save me a lot of time, since by now I’ve got to use the “Flatten Tree” component every time. This way I could process multiple lists whithin the same component easier and with fewer additional components, which also would increase my definition’s legibility.

Cheers,
Henry

@henry.langner Can you provide a small example where this would be useful?

I’m not entirely sure I get the process. ‘List’ and ‘Branch’ are basically the same thing, which adds to my confusion. Are you saying that if a parameter has more than one source, you want to ensure all the branches are kept separate during the tree merge? Or is this an operation which can be performed on a single tree as well?

I may have misunderstood, but doesn’t entwine do this already? Just make sure to right click and disable flatten inputs

I just made a definition to show what I mean. list-grafting-example.gh (12.3 KB)

As @dharman mentioned, you can use Entwine or Merge and Flip components to achieve what you want:


Henry Langner.gh (11.9 KB)

1 Like

I see, so it is a way to keep all the branches in all the trees which are plugged into a single parameter apart. The QuickGraph component actually does this because it seemed to me to be more likely that different sources represent different graphs rather than contributing to the same graph.

It’s not a bad idea to have such a feature readily available on all parameters, but I’m not sure I want to add it to GH1 at this stage. It would make files even less forwards compatible than they already are.

I’ve logged this under RH-50628.

1 Like