Hey there. I am trying to group some items that might be inside of boxes and then group them if they are in the same layer. So far I have been able to group them if they are inside of the same box, but I havent been able to then group them again if they are in the same layer also.
I am using LunchBox for the ObjectAttributes which gives you the layer the item is in.
Hey Rickson! Thank you for the help, but I tried to replicate your solution and it doesnt seem to work at my end. Some breps just get ignored and others get duplicated.
Sorry if I am doing something obviously wrong but I tried the files Rickson provided and its the same thing. Some breps get duplicated and some just ignored as you can see in this images.
If the box contains the brep it gets branched accordingly, if objects in the first branch are on a layer they are broken out into a sub branch. Best seen in Branch {1;0} and {1;1}
The amount of objects is the same, no breps are duplicated, just passed down stream… into their respective branches.
Yes, the number of breps are the same, but some objects get ignored and others get duplicated to fill the previous number of breps.
Could you try to bake the objets from your example and see if this also happens to you? Maybe could be something with my computer but I am almost sure that this is not working.
Hey Rickson! Thanks for the reply, I am using the same files that you provided but once I bake them its the same result where I get duplicates and some breps ignored. Could you bake them in your computer to test this?
ok. So whats the objective? You have 11 items on various layers you are then dividing by zone then layer (the same layers they are on). You would like these baked how?
In this instance i would probably create an attribute on the Rhino Geometry that say what box its in (1 thru 8) and not bake anything. Really depends on what you are trying to do.
I have a huge model of a building with different layers of floors, ceilings, pipes, etc. All layers have a lot of meshes.
I want to be able to divide the building in small boxes and then merge the meshes that share the same box and the same layer. And then bake these items again into their original layers.
So finally I would have one merged mesh for each box for each layer.
I hope this makes some sense.
So just apply an attribute instead, no need to do any of the baking.
Floor 3 has layers of mechanical [Pipes, Lights, Hvac, Sprinklers], you create a container box for Floor 3, apply that to all (FloorAtt : 03). If you need to sub divide Floor 3 add Floor 3.1, 3.2 boxes and apply that attribute. (FloorSubAtt : 3.1, 3.2). Once attributes are applies you can do what ever is next to the filtered objects.