![]() |
|
Mesh containing another mesh - Printable Version +- AB4D Forum (https://forum.ab4d.com) +-- Forum: Products Forums (https://forum.ab4d.com/forumdisplay.php?fid=4) +--- Forum: Ab3d.PowerToys (https://forum.ab4d.com/forumdisplay.php?fid=9) +--- Thread: Mesh containing another mesh (/showthread.php?tid=4259) |
Mesh containing another mesh - kreativasas - 05-03-2021 Hi, I have 2 close geometrymodel. With a rotatetransform i intersect the first object with the second, then and i need to know wich positions of the first object is contained in the second. I tried to check if the positions of the first mesh are in the bounting box of the second but doesn't work (because some of the positions contained in the bounting box are not inside of the second) i tried with Ab3d.Utilities.MeshBooleanOperations.Intersect(geometrymodel1.geometry,geometrymodel2.geometry) but it seems not working. It seems that the transformation is not applied and the object are in the initial position. Any ideas? RE: Mesh containing another mesh - abenedik - 05-05-2021 You can use TransformMeshGeometry3D method to transform the positions of the MeshGeometry3D before you call the MeshBooleanOperations.Intersect: Code: var transformedMesh = MeshUtils.TransformMeshGeometry3D(originalMeshGeometry3D, transform, transformNormals: false);RE: Mesh containing another mesh - kreativasas - 05-05-2021 great!! Thanks RE: Mesh containing another mesh - kreativasas - 05-31-2021 Hi, now works... but still have a question.... How i can measure the dimention (width,height,depth) of the mesh resulting with boolean intersect? RE: Mesh containing another mesh - abenedik - 06-01-2021 Each MeshGeometry3D (and also each Model3D) object has Bounds property that defines an axis aligned bounding box with SizeX, SizeY and SizeZ |