pub struct FroxelBuffers {
pub params: BufferHandle,
pub froxels: BufferHandle,
pub lighting: BufferHandle,
}Expand description
The buffers one frame’s froxel column lives in.
A window for a test, and the froxel path’s only public surface. The
column is checked against crcbl_shaders::volumetric on the host, per
froxel, which is the one thing that can tell a wrong scatter from a wrong
scan: the frame-level checks compare a picture against the closed form, and
at a single-scattering albedo of one those two mistakes compose to the same
answer. Handing out the handles is what lets that comparison exist without
this module’s internals leaving it.
DrawGen::visible_count is the
same shape and the precedent for it.
Fields§
§params: BufferHandleThe parameter block both compute passes and the composite read —
crcbl_shaders::volumetric::PARAMS_SIZE bytes, in the layout
VolumetricParams::from_bytes decodes.
froxels: BufferHandleThe column: FROXEL_STRIDE bytes per froxel, holding the exclusive
prefix in front of each slice once the frame’s passes have run.
lighting: BufferHandleWhat each froxel’s lights put into it — LIGHTING_STRIDE bytes per
froxel: the punctual glow in rgb, the sun’s visibility in w, as the
scatter pass left them and the scan did not touch them.