Small amount of clipping despite perfect sizes

Hi!
I’ve recently been building in Studio while working with negated unions. Despite working with integer and decimal multiples of five, when zooming in closer, I notice a tiny amount of clipping while building, and I’m trying to get rid of it; it’s not visible from the side.
I’ve checked the orientation of the unions, and they are not rotated slightly.
Why does this happen, and how can I fix it?


2 Likes

By this do you mean you are working with e.g. 0.2, 0.4, 0.6 and so on? Unfortunately those numbers cause floating point errors. Decimal numbers in binary are represented as negative powers of 2, so 2^-1 = 1/2, 2^-2 = 1/4, 2^-3 = 1/8 and so on. So you will not be able to accurately describe 0.4 as a number in binary. 0.375 however can be described accurately as it’s the sum of 1/4 + 1/8.

Another tricky part with unions is that the size of the bounding box seems to cause problems sometimes as well. I do not have any concrete data on this, but it seems that you will want to keep the bounding box of a union operation as a multiple of 2. In the image below you can see me unioning a 4x1x4 part with a wedge and a 3x1x3 part with a wedge. The 3x1x3 part causes a thin line to appear on the side, despite the two parts being lined up correctly. I suspect that this is because the bounding box of the union is not a multiple of 2 (e.g. 0.25, 0.5, 1, 2, 4, 8, etc.)

image

image

Honestly the best solution is to create your mesh using a modelling program such as Blender or Maya, though I understand those have a high learning curve.

4 Likes

The decimal multiples of five that I use in the model always end with 5.
I will look further into the topic of floating point errors though, thank you!