advanced

#15 Smooth Blending (SDF)

Smooth min for organic shapes

Normally, min(a, b) combines two SDFs with a hard crease where they meet. The smooth minimum function smin() replaces that sharp join with a soft, organic blend — shapes melt into each other like liquid mercury or lava lamp blobs. The parameter k controls the blend radius: larger values create wider, gooier connections while smaller values keep shapes more distinct. This is the foundation of metaball effects and any shader art with an organic, blobby aesthetic.

Key Concepts

Try this shader live in the Shader Sandbox editor with real-time preview.
Open in Sandbox

Source Code


    
← Previous Domain Repetition Next → Voronoi Noise

All Tutorials