I am playing around with trying to subtract text from a mesh using csg2 and not having much luck with it. I am getting the error: Error while creating the CSG: Not manifold
I have done a lot of searching and try different things but nothing seems to work, any ideas?
But I can guess the issue. 3D text is simply not manifold, not watertight, as it has hard edges (distinct front and back faces). You’d likely need to merge all duplicate points and possibly also separate each manifold letter mesh and subtract one at a time.
Even after doing this, I’d be very surprised if you got reliable and clean results from using 3D text (a complex mesh) in a CSG operation.
You’d need to also update the PG link in the original post, as I tried again and it’s still broken.
As I said, you’d first need to make the text mesh manifold/watertight by merging mesh vertices and possibly also separating each manifold letter mesh and subtract them one at a time. That’s technically possible I guess but honestly not worth the effort and the results I can guarantee will not be reliable, repeatable or clean.
Just my opinion. Maybe someone else will have better ideas …
I think this is the right track. Changing A to I (capital I has no holes) results in no CSG2 error. However, subtract doesn’t appear to do anything, and intersect results in “Unable to build mesh. Manifold has 0 vertex.”
This indicates to me that ‘I’ is not watertight. Not sure why it couldn’t be constructed as watertight. Just speculating.
I tried a similar thing - using an “l” (lower case l) which essentially is a box. What I found though was that even after mesh.forceSharedVertices() there were double the number of faces i.e. 24 instead of the expected 12, even though vertices was the correct 8. So I think the text is built as double-sided which could cause issues.
I got this to work using a stl. I subtract the stl from the cube, then add a shorter cube to the original since the subtract seems to goes all the way through the cube.