pyvista-support
pyvista-support copied to clipboard
boolean operations errors
Hello I want to know how to do boolean operations on two meshes and I'm getting this error ERROR:root:No points to subdivide ERROR:root:No points/cells to operate on ERROR:root:No points/cells to operate on I think the problem is that I don't have the two meshes aligned do you know how can I align the two meshes and get the boolean difference? I've been trying to do it but I haven't been able to find a solution. Thank you.
Hi and welcome! Thanks for posting your first issue in the PyVista project! Someone from @pyvista/developers will chime in before too long. If your question is support related, it may be automatically transferred to https://github.com/pyvista/pyvista-support
you may need to share the meshes you're using and the code you're running for us to help
objects.zip These are the 2 objects, there are a human. obj file and pants. obj file. Thank you very much.
I forgot to ask if it's possible to save the resulting mesh in a .obj file? Thank you for your help
Were you ever able to resolve this error? I have also encountered this and would like to know if you encountered a solution @josepereiroml. Thanks!
For the exact files included above I don't think there exists an intersection between the pants.obj and human.obj files? From what I saw the human object would need to be scaled and rotated. In general as long as the polydata are represented as only triangles boolean operations should work (from my experience). So something like the following line might work in this case after some manipulation of the human or pants objects.
union_object = object_1.triangulate().boolean_union(object_2.triangulate())
Hopefully this is helpful! (apologies if it isn't)