What's the difference: CSG1 and CSG2?

So lately while wandering the dev forum, I’ve noticed people briefly mentioning a CSG engine version 1 and 2 build. After some searching, I discovered a setting that allows you to turn V2 off. I haven’t touched it yet since I honestly don’t know the differences between the two. I was wondering what the pros and cons of each engine version are and if one is particularly superior (I’m betting V2 is since it’s the default version).

2 Likes

I’m not sure what else, but if I remember right CSGv2 fails much less, whereas CSGv1 seems to regularly fail to union.

4 Likes

To add onto this, CSGv2 doesn’t allow for smooth shading very much, and the Negate parts don’t transfer their color once unioned to another part.

2 Likes

I stick to V1. My main reason is that CSGV1 optimizes the models, (it gets rid of unnecessary triangles, look inside a union) it has smooth shading, and clipping parts properly negate.

1 Like

I don’t believe that to be true.
And inside faces is an issue in both v1 and v2 related to Floating Point inaccuracies.

1 Like

I haven’t checked recently, but when it first came out, CSGV1 had more efficient unions.

2 Likes

Thanks for the replies guys! I’ll keep this in mind going on in the future. To anyone who reads this post later on, I have another question: does changing the version change any already created union operations?

No, if you made it in V1 it"ll stay as V1 even after enabling V2 unless you separate and union again.

1 Like

Agree with this statement.

CSG v1 allowed for corners/edges where you union to be smoothed out. (Bevel)

Example as shown here in a past dev forum post:

I exported two identical unions, one made with V1, and one with V2. I popped them both into blender and here are the results:

V1

V2

While V2 has significantly less errors, I largely prefer V1 for the reasons stated previously.

2 Likes

That’s because CSGv2 in itself is not optimized yet. But it tries to optimize the mesh on the run. For example, when the union is nearing the triangle limit, it tries to save up triangles from one region, to allow creation of new triangles somewhere else.

CSGv1 doesn’t optimize the mesh on the run, it only adds new triangles without removing unnecessary ones.