Uniting All Objects on a Layer
Uniting All Objects on a Layer
(OP)
Is there a function that can be used in a journal to unite all bodies on a given layer? We often have scenarios where we copy all bodies in view to a single layer and then unite all and I am looking to automate this process. I already know how to automate the copying portion, and am hoping that the uniting is similarly simple.
We run NX8. Thanks in advance for any help.
We run NX8. Thanks in advance for any help.





RE: Uniting All Objects on a Layer
www.nxjournaling.com
RE: Uniting All Objects on a Layer
RE: Uniting All Objects on a Layer
Proud Member of the Reality-Based Community..
To the Toolmaker, your nice little cartoon drawing of your glass looks cool, but your solid model sucks. Do you want me to fix it, or are you going to take all week to get it back to me so I can get some work done?
RE: Uniting All Objects on a Layer
CODE
www.nxjournaling.com
RE: Uniting All Objects on a Layer
All the bodies should be intersecting any time we perform this function, so it should be fine. As you say, the unite function is always something we can edit.
As this worked so well, would it then be possible to subtract all the bodies from another layer from the bodies on the layer that just got united. So, let's say we used what you have already written to unite everything on layer 200. I would want to then subtract some bodies on layer 205 from the united bodies on layer 200. It would be preferable if the bodies used for the subtraction on layer 205 could be kept (like choosing the 'Keep Tool' box in the 'Subtract' interface). Would this work?
RE: Uniting All Objects on a Layer
This is a lot of cut & paste from the journal recorder, so it could probably stand a little more cleanup but seems to do the job.
CODE
www.nxjournaling.com
RE: Uniting All Objects on a Layer