THREE.JS / FOUNDATIONS 49

A cloud is a shader with memory.

A custom RaymarchingBox loop walks through a 3D noise field, accumulating soft density until the cloud becomes a thing you can see.

Initializing cloud—
Preparing the 3D texture and raymarch material…

More steps reveal finer cloud edges but cost more texture samples. Threshold shapes the cloud; range softens its boundary; opacity controls front-to-back accumulation. This route preserves the pinned source contract; exact page, presentation, pixel, and whole-example fidelity remain separate.

LAB 49 / VOLUMETRIC CLOUD