Cold Start
- ..
- .metadata17 B
- README.md1.7 KB
- bindings.yaml181 B
- shader.wgsl21.1 KB
README.md
asc_dust
ASCENSION's sandstorm medium. One invocation per pixel of a half-resolution
target; the pixel's view ray is rebuilt from the inverse view-projection in U,
clipped at scene geometry with the engine depth blit, and integrated front to
back through an analytic dust field — extinction and inscatter — into
out_tex as vec4(scatter, 1 - transmittance), the premultiplied form
preseed.shaders.asc_dustmix blends over the scene at post priority 6.
The field is four multiplied terms, each one sentence of the brief's beat sheet:
a dense ground layer under a wall body with a noise-ragged top; a lobed haboob
FACE at an along-wind coordinate, with clear air ahead of it and the storm's own
density behind; a vortex CURL about the tornado's axis on a 1/r law, with the
column clearing its own local air; and three octaves of value noise advected
downwind by the bus's windAccum, so the medium travels as a pure function of
t and a seek reproduces it exactly.
Extinction is density / visRange and nothing else — visRange is published on
the clock bus precisely so the sand, the sky and this medium agree on one
number. Inscatter is mixed between two ends solved from the dome's own rows on a
Henyey-Greenstein phase against the sun, so looking into the sun through the
dust is the bright part of the frame and the horizon carries no seam.
The clip range is REVERSED: inv_vp * (ndc, 1, 1) is the near plane and
(ndc, 0, 1) the far one, and a surface is depth > 0 rather than < 1.
Reading it the other way starts the march at the far plane and walks backwards.
Dispatched by preseed.asc.asc_dust (the module) with resources in
bindings.yaml order: out_tex, U, scene_depth.