water_extinction
The medium DEADLIGHT swims in, as one full-screen pass. Every pixel is re-lit for the water standing between it and the lens: what the surface sent toward the camera is attenuated by per-channel Beer-Lambert extinction over the real distance, and what the water itself scatters in…
water_extinction
The medium DEADLIGHT swims in, as one full-screen pass. Every pixel is re-lit for the water standing between it and the lens: what the surface sent toward the camera is attenuated by per-channel Beer-Lambert extinction over the real distance, and what the water itself scatters into the eye path is added over it.
Red dies at 0.19 per metre against 0.032 for blue, which is why rust reads brown
at two metres and blue-grey at twelve, and why nothing past the lamps' reach is
visible at all. The black at the edge of frame is absence, not fog — with no
light in the water there is nothing to scatter in, which is what inscatter
falling to void_color says.
Distance is unprojected from the depth buffer through the frame's own inverse view-projection, so every camera measures its own water rather than inheriting the main camera's near and far planes. A pixel with no surface behind it is measured to the far plane, so an empty direction — straight up included — fills with the same water and the frame never shows a sky.
inscatter, void_color, surface_y and column_falloff are written once per
film frame from Film.depthAt(t): one number carries the descent from cobalt
through prussian to void.
Scoped to this part · feeds back into the world's score.