Let's take a look at another application where UGFs are the appropriate setting: chamfers, in particular the constant-width flavor.
(UGFs are a generalization of SDFs considering fields with unit gradient magnitude. https://www.blakecourter.com/2023/05/18/field-notation.html)
Images are from #nTop .
(1/n)
(UGFs are a generalization of SDFs considering fields with unit gradient magnitude. https://www.blakecourter.com/2023/05/18/field-notation.html)
Images are from #nTop .
(1/n)
Comments
In the next session, we'll look at that two-surface coordinate system more closely, treating it as a basis for remapping any kind of edge treatment!
(10/n, n = 10)
Algebraic geometers call this family a "pencil".
With such an angled face at any angle and offset, we can describe any surface from the edge in "Hesse normal form".
(9/n)
A * t + B * (1 - t)
Indeed, such interpolating will create suitable geometry, but how do we control it with CAD-like parameters?
(8/n)
(7/n)
(6/n)
(It's a bit subtle.)
(5/n)
Defining:
S = A + B
D = A - B
Interactive version: https://www.shadertoy.com/view/dd2cWy
(4/n)
This corner, A ∩ B, is what we want to chamfer. Note that this result is not an SDF, but a UGF, because the field extending up from the corner is sharp.
(3/n)
Here's A. B will just be it's mirror image across the vertical axis:
(2/n)