Log inGet started
World

Builtin Library

Branchmain
Branchesmainpublish
Commitcc6939bf11

README.md

atmo_aerial

Builds the aerial perspective volume for the camera being drawn: the light the air scatters toward the camera and the optical depth of that air, from the camera out to each depth boundary of every view direction. The volume is a fixed grid (atmo_aerial_volume), so this pass costs the same at every output resolution. It runs at the seam after the sky pass, so everything later in the view reads it through atmo_aerial_lookup: atmo_composite for every surface and the cloud layer's raymarch for every cloud.

Each invocation marches one slice of one direction, in one step for every 8 of aerialSteps, rounded up, over the air that direction crosses (ap_depth). A workgroup holds every slice of two directions and sums them from the camera outward, so no stretch of a direction is marched twice.

Includes

  • atmo_common
  • atmo_transmittance_lookup
  • atmo_multiscatter_lookup
  • atmo_integrator
  • atmo_aerial_volume

Bindings

namekind
frame_cambuffer
atmo_paramsbuffer
transmittance_luttexture2d
multiscatter_luttexture2d
aerial_outstorage2d (rgba16f)

The pass states its own dispatch: (AP_COLS / 2, AP_ROWS, 1).