Pro Builder - StackOverflowException with Boolean Tool

Some of us are having those errors when Applying Boolean with the experimental tool. Is this bug logged please?
Related thread : Pro Builder - boolean removed?

StackOverflowException: The requested operation caused a stack overflow.
System.Collections.Generic.List`1[T].set_Capacity (System.Int32 value) (at <437ba245d8404784b9fbab9b439ac908>:0)
System.Collections.Generic.List`1[T].EnsureCapacity (System.Int32 min) (at <437ba245d8404784b9fbab9b439ac908>:0)
System.Collections.Generic.List`1[T].Add (T item) (at <437ba245d8404784b9fbab9b439ac908>:0)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Plane.SplitPolygon (UnityEngine.ProBuilder.Experimental.CSG.CSG_Polygon polygon, System.Collections.Generic.List`1[T] coplanarFront, System.Collections.Generic.List`1[T] coplanarBack, System.Collections.Generic.List`1[T] front, System.Collections.Generic.List`1[T] back) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Plane.cs:66)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:112)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System.Collections.Generic.List`1[T] list) (at Library/PackageCache/com.unity.probuilder@4.2.3/Runtime/MeshOperations/CSG/Classes/CSG_Node.cs:120)
UnityEngine.ProBuilder.Experimental.CSG.CSG_Node.Build (System<message truncated>
6 Likes

I’m seeing this too. If you haven’t already, please log a bug for it.

6 Likes

You know…it’s funny ProBuilder was BUILT around CSG. Which is Boolean Operations, and yet they were always “might work, might not”…and now just a “Nope”
No offense, but this is just aggravating as all @#$%^&
Just about every other True CSG (not using shader tricks that don’t actually change the mesh) all have flaws in Unity. Why is this??

1 Like

Hey,

I was having a similar issue where I was trying to cut a cylinder into another cylinder. Figured out the issue was too much geometry (I imagine too much vertices makes calculating subtraction a bit too much). I figured out how to remedy this by making the object I was subtracting from my main object have fewer sides to it. Hope this helps!

-Noxirus

There has got to be a better way to perform a boolean operation on the mesh. Probuilder just isn’t doing the job.

This is happening for me too. It worked in previous versions. I’m in a HDRP project, if that makes a difference.

same here. boolean operations reliably crash unity now.

2 Likes

Having this issue too.

Yeeppppp… 2019.4.9f1 – Regular 3D project, Probuilder CSG ops is borked with a stack overflow.

It also happens to me right now. I need a csg api to get intersect some meshes . Any idea ???

I don’t actually know how but I got it working. I tried creating a new script and forgot to check what script it was in but i can’t find it.

Change the sizing of the intended shape that you are cutting, it worked for me after a restart of the editor. I hope this helps.

when you press substruction make sure that u see the new game object wish is the boolean that you are looking for …

fyi Fix CSG Crash by karl- · Pull Request #400 · Unity-Technologies/com.unity.probuilder · GitHub

Probuilder is just buggy as all heck even beyond the issue that boolean operations crash unity/don’t work. Is probuilder going to be supported going forward or is something else going to be responsible for boolean operations. Thanks!

Hey there, is this bug fix merged with 2021.2 branches, if not, do you know when it will be? thanks!

Fixed!!! FYI, I’m on 2021.2.13f. I would get 100% repro of the unity crashing on boolean: subtraction operation and it is working really good once i moved to 2021.2.13f. Thanks!

Im still getting this, and its a year on, is there likely a fix for the boolean tool soon?

@bugfinders what version of ProBuilder are you using?

i tried the 5.0.7 package provided through package manager, and the 5.1.0rc off github.