Get bounding box of whole CAD assembly in SpaceClaim/Disovery.
Rajesh Meena
Moderator, Employee Posts: 85
✭✭✭✭
I would like to get the bounding box of the whole CAD using script. Is that any way to do that?
Tagged:
0
Best Answer
-
You can sum the bounding boxes. I would do something like this:
comp = ComponentSelection.Create(GetRootPart().Components[0]) box = Box.Empty bodies = comp.ConvertToBodies() for body in bodies: box = box | body.Shape.GetBoundingBox(Matrix.Identity) curves = comp.ConvertToCurves() for curve in curves: box = box | curve.Shape.GetBoundingBox(Matrix.Identity)
0