Jump to content

Working with multiple groups procedurally

Recommended Posts


I have a number of layers consisting of a certain amount of primitive curves. 
Level_1, Level_2, Level_3, etc. So it's kind of like a tree. I have promoted these primitive curves to point groups with same the name. I then grouped the first point of each curve on all layers to a point group called “start”.
So what groups I have is:

Level_1, Level_2, Level_3, Start.

What I want to do and need help with is to fuse these curves together procedurally as they are disconnected. 

As the groups are layered the fusing has to occur layer by layer aswell.
So I want the “Start” group of Layer_2 to fuse together with any points on Level_1. Then the “Start” group of Level_3 to fuse with any points onLevel_2. So only the starting points will fuse with the underlying layer.

Manually this is easy but since the layer amount will change it's not a solid option.

Hopefully I made myself somewhat clear. 
Have a nice day!

Picture below shows and example of how I am thinking. Level_2's start points gets fused to Level_1's curve.


Link to comment
Share on other sites

Thank you for your reply!
I looked into using for loops and I am pretty sure this is the way to go, however I am uncertain how to get more control of whats going on in the for loop. 


In the picture I have a couple of primitive groups that gets looped. Trunk, Group_1, Group_2, Group_3, Twigs.

What I want now is to use Ray Sop to fuse the groups in order. 

Group_2 fuses with Trunk.

Group_3 fuses with Group_2.

Group_4 fuses with Group_3.

Twigs fuses with Group_4.

So I thought all I had to do was to delete the Trunk group and then insert to the Ray Sop to get the order I wanted. But it doesn't work.

Edited by hampuseh
Link to comment
Share on other sites

This could be done using a single wrangle node in point mode as well I think.

masking use of the following function.
int  nearpoint(<geometry>geometry, string ptgroup, vector pt)
the pseudo code would look something like this

// Create string with corrcet group name "Level_%D", own_level-1

//find near point using created group string

// if point found move self to location of found point

Afterwards use the fuse node to fuse everything together.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...