
@Dansolo, I mixed the versions. I uploaded a new version of the plugin, please try it now.

@Dansolo, I mixed the versions. I uploaded a new version of the plugin, please try it now.
Yep worked straight away. Congrats and like others have said its great that it has history and can be animated.

Awesome work @zoharl! Glad to see Mayaās boolean work the way it should have from the start. ![]()
I like what you have done here. However, I do have one request. Can you have the operation not triangulate the whole mesh? Perhaps have the triangulation happen only at the intersection of the meshes? Iām not sure if this would be an easy thing to do. I am no coder that is for sure, but it would make this plugin so much better. 
Btw, thanks for this!
Hmmm, I tried it on two primitives and got the below result???

Before script executed

After
@ChewyPixels, in itās current version curve lib supports only triangulations, so the output is triangulated. Itās future version might include a more general solution, which Iāll try to employ in this plugin. Also I considered to add as an alternative CGAL boolean ops. Although it is much slower, and demands a clean output, it supports a general mesh (the input doesnāt have to be triangulated), and it uses exact computation, which should be able to handle the trickiest cases. In a few days Iāll add this to the future work.
In the meantime we can consider a post processing step, which can remove new edges that werenāt in the original triangulation, if their incident faces didnāt change. The friends in the forum are invited to help me here.
@Hamburger, as I noted before, I welcome tricky examples that would help us know better the plugin limitations, but Iāll need two models (.obj or .fbx), and the boolean operation that you performed.
Hi Zoharl, itās just two cubes (run this code in blank scene):
polyCube -ch on -o on -w 1.082833 -h 1.082833 -d 1.082833 -cuv 4 ;
duplicate -rr;
move -r -os -wd 0 0 -1 ;
setAttr āpCube2.rotateYā 45;
After selecting both cubes and running the script, it creates a corrupt copy of the two cubes:

This corrupt result happens with every object I try this so far, from complex ngon objects to basic maya primitives⦠some reason itās breaking 100% - but this is the most basic example I can give.
Edit: Thought I might add, Iām on 2012x64 SAP. Also have those MS patches installed.
@ChewyPixels, my mistake, carve lib does support polyhedra with general valence. I updated the plugin, please give it a try.
@Hamburger, please do the following:
Computing CSG 0, mesh1 has 8 ver, mesh2 has 8 ver
polySphere -r 1 -sx 20 -sy 20 -ax 0 1 0 -cuv 2 -ch 1;
polySphere -r 1 -sx 20 -sy 20 -ax 0 1 0 -cuv 2 -ch 1;
setAttr "pSphere2.translateZ" 1;
Thanks zoharl, actually.
I was misunderstanding the workflow but after trying out what you said I get it now. Initially I expected the original objects to be deleted. But now I understand that its defaulting to āUnionā and keeping the original objects. My mistake in the end!
BTW, the new update is very good. Thanks a bunch again.
@zoharl - The normals preservation does not seem to be working for me. Here is an example:
![]()
Notice how I am getting messed up normals on the cutout area. I am using the latest build.
I also have another request.
Can you implement a UV preservation feature? This would be so useful!
Keep up the great work! ![]()
Some questions:
How should the normals be?
Do you have a simpler example?
Does a union of two spheres, one hard edge and one soft edge, work for you?
Can you share the problematic meshes?
Actually it looks fine to me, not what you wanted, but how it should be. The black surface on the intersection part has the normals pointing down, the same as the original surface that these faces came from. Do you have another algorithm in mind?
If I think of it, for intersection it make sense to invert the normals on the intersection part, but I need to consider if it covers all the cases. In your specific case, if you manually invert the normals of the to faces, does it produce what you want?
The UV preservation is in the future work along with vertex color preservation. But Iām not sure when Iāll have the time for it though.
The normals are pointing in the correct direction. The problem is that the cutout area normals become messed up causing the polygons to turn black. Not a huge problemā¦since it is fixable by unlocking the normals on the mesh then applying a smooth/harden normals. 
I am also interested in a 2013 compile (win 7 x64)ā¦beers for whomever can find the time. Thanks,
-nb