Re:SDF Fractal Noise
by pasabagi on Tuesday July 13, 2021 @05:15AM
(#27818931)
If you want to generate textures which you then read at runtime, this kind of technique is very useful - for instance, imagine you want to create the normal map of a cloud, or create a height map to displace vertices with (for a procedural landscape).
[ Parent
| on HN ]
Re:SDF Fractal Noise
by anentropic on Tuesday July 13, 2021 @06:08AM
(#27819235)
But using noise to generate textures isn't directly related to SDF (I think?)
from other replies I think the point here is there are no "vertices", i.e. no mesh geometry
Well yeah, but you can obviously use signed distance functions to create a texture (that's what a shader is doing) that can be used at runtime. Imagine you want to make the normal map for a bubbly surface, for example, but you also want the bubbles to be animated. One way of doing this would be to render the normals from a bunch of sdf spheres onto a 3d texture, which would then be used later.
I don't use this a work - it's just an approach that I've had some success with at home. On my machine, complex fragment shaders are always slow - so maybe this kind of sdf-based approach works in realtime for other people.