New Boolean

I am getting closer to hopefully putting my new boolean code into master. This code is meant to be more robust than the current BMesh boolean. The new code is a fairly faithful implementation of “Mesh Arrangements for Solid Geometry”, by Zhou, Grinspun, Zorin, Jacobson. Siggraph 2016., including the use of exact arithmetic.

I know that many of the addon writers here build on top of the builtin Boolean. It might be time to start testing this new boolean to see if it breaks your code, and let me know in this thread if so. I have started putting builds of my branch on the experimental buildbot site: https://builder.blender.org/download/newboolean/ .

Here’s an example of where the new boolean does better than the existing one - cases where there is exact coincidence between geometry of the two sides of the boolean. The old boolean leaves a hole; the new one does not.

Other cases that work in the new one involve coplanar intersections.

One thing that I have not yet implemented: the ability to use non-closed-volume objects as operands. So no “plane cutter” yet. I do intend to add that. (It is not something the cited paper handles, so needs more development).

96 Likes

Hi Howardt,
This is awsome, thank you for the hard work !
Looks like union fails to merge objects when not touching - empty geometry ?
Using nested union + difference, disabling any union operand in “AutoBoolean” object does work, but fails when both are enabled.

new_boolean_fails_to_union.blend (1.2 MB)

Wow! I always wanted a boolean tool that can handle coplanar faces. This is awesome!

4 Likes

Brilliant! Been looking forward to this.

5 Likes

Hi Howard,

Great work. And nice to see a Blender developer communicating with the user community at Blender Artists. :+1:

11 Likes

Thanks Stephen. I only recently added the code that handles disjoint meshes (a surprisingly hard case for the algorithm in the paper!), and seem to have a bug here. I will fix it.

4 Likes

History is being made here!!
For so long that Blender has that wooden leg that I thought it will never evolve.
Thank you so much for all of the hard work and the passion at taking that challenge up to the end!
Mr Howard, you rock!!

2 Likes

Yeah. Reading the paper, it seems like this will be a very robust method , which sounds awesome! Most of it is way over my head , but I’m super happy you were able to accomplish this. :raised_hands::exploding_head::star_struck:

Yes, thank you, Howard. This is very much appreciated.

3 Likes

When I try to snap the target of boolean to the object with the boolean modifier it doesn’t work.

Hey @howardt,
That will be one of the most needed improvements for me.
I just tried it with an existing (quite complex) model, and it crashes Blender. The only output I get in console is: zsh: floating point exception (core dumped).

There are new builds up at the buildbot link. They fix Stephen’s bug and another regarding reversed normals.

@cdog and @blndrusr - I need .blend files if you want me to look at the problems, preferably as simple as possible. That said, I already have several examples of crashing .blend’s that I am working on fixing, so you might also want to wait until I have fixed my known crashing problems and then try again.

9 Likes

I’m excited for the possibilities of what this could offer. We have long preached to avoid “hotlining” or placing a bool directly on top of an edge precisely. It cant download quick enough.
image

5 Likes

Hi , I tried to make boolean (difference)
with this 2 co-planar object with new build,
but it is not working.
Thanks

1 Like

I tried that - I added a cube, duplicated it, scaled the second by .5 in z, moved it up .5 and 1 in y. Then put a boolean modifier on the first cube subtracting the second. It worked for me. If you can upload a .blend, I can look to see what is different.

I should caution that when I say “coplanar”, I mean exactly coplanar. There is no snapping to planes if they are within some epsilon tolerance. That said, the boolean should still work if things are not exactly coplanar – there just will be some very skinny triangles in the result. So I don’t think that’s what is going on here. Did you check the “Exact” box in the modifier? It is the default in my builds, but if you made this model in another Blender, it will be off by default.

1 Like

first test. dizamn. Thats some good hotline reaction.

8 Likes

In this tool that converts a face to a solidified boolean it appears to show some stress even on an i9.

5 Likes

admittedly plane on plane violence was my first test with it.

theres a workflow where a mesh is used as a difference but can be shifted into a slice or intersect / inset / outset. The solidification portion of modifier evaluation seems to be hit heavily. The smaller window is current 29 and the bigger is the branch.

this is the best thing i have seen since mirror got bisect.

I see changes happening to like 20 different systems off the top of my head. So amazing.

One more thing. So I have been working on an idea to make booleans handle bevels dynamically. And well, youve done it.

Im not joking when I say I had plans that depended on this solve. I see so many possibilities already!

20 Likes

I was waiting for you to enter this thread…

3 Likes

yeah he specially must be very happy with this…