Mesh containing another mesh
#1
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?
#2
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);
Andrej Benedik
#3
great!! Thanks
#4
Hi,
now works... but still have a question....
How i can measure the dimention (width,height,depth) of the mesh resulting with boolean intersect?
#5
Each MeshGeometry3D (and also each Model3D) object has Bounds property that defines an axis aligned bounding box with SizeX, SizeY and SizeZ
Andrej Benedik
  


Forum Jump:


Users browsing this thread:
1 Guest(s)