Fixed the issue I had with the color. I used to just take a weighted sum doing something like min(1/(dist+1)^2, 1) where dist was to the center of a shape. This resulted in confusion when shapes where inside others, you couldnt tell which was bigger and what kind they where. After many tries and iterations I changed dist to be the distance to the edge of a shape, I already had that as thats how the rendering works. and changed from an inverse function that had a sharp edge to a modified sigmoid: -1/(1 + e^(-(dist - k)/k)) + 1 where k is my smoothing constant * object size.
The project is really close to completion. I think i will add a shape adder using polylines, but that might be out of scope, we’ll see.
Log in to leave a comment
Added UI to change display parameters and add new shapes. Shapes can now either subtract or union. – Subtract only applies to shapes created before – this was an accident, but it allows for more flexibility so it’s staying that way. I dont like the way I’m handling color mixing so I will probably fix that next.
Log in to leave a comment
Works with smooth-min, the main idea why i wanted to do this, but will probably add other ways later. Color is also implemented.
up next probably boolean geometries or ui for addition of more objects
current objects: square and circle. but i can add any object for which i can design a distance function.
Multiple view modes available: Output, Real, and distance.
Log in to leave a comment