Open richardrl opened 3 years ago
I see the same behavior... but it seems random on my end, so I ended with a temporary dirty solution such as
try:
while(True):
sectionMesh=skull_mesh.intersection(box)
print(sectionMesh.volume)
break
except AttributeError as err:
if "'Scene' object has no attribute 'volume'" in str(err):
p.print("Repeating CSG boolean since once in while it returns an scene instead of a mesh....")
else:
raise err
this eventually ends working on the second time it re-tries the intersection...
Intersection returns a Trimesh Scene when there is actually an intersection. This does not seem correct according to the API. Plus, I can't access the vertices in the intersection like I want.