Skip to main content

Module indirect_cull

Module indirect_cull 

Source
Expand description

Canonical indirect visibility, HZB and multi-representation stream delegation.

Structs§

CullUniformsGpu
Uniform buffer layout for instance_cull_indirect.wgsl (288 bytes).
DrawIndexedIndirectCommand
WebGPU-standard 20-byte DrawIndexedIndirect command payload.
HzbPyramidView
Lightweight zero-heap view over a 2-phase Hierarchical Z-Buffer (HZB) mip chain.
IndirectCullPipelineGpu
GPU-resident compute pipeline and indirect stream buffers for INSTANCE_CULL_INDIRECT_WGSL.
IndirectCullStreamCounts
Output stream counts produced by cull_and_select_lod_indirect_zero_heap.
InstanceCullDescriptor
GPU-aligned per-instance culling & multi-modal routing descriptor (80 bytes, 5 x vec4).

Enums§

RepresentationPolicy
Multi-modal representation policy encoded in InstanceCullDescriptor::rep_policy.

Constants§

DEFAULT_LOD_HYSTERESIS
Default fractional hysteresis deadband around LOD thresholds (10%).
DEFAULT_LOD_THRESHOLDS_PX
Default screen-space projected radius thresholds in pixels ([LOD0, LOD1, LOD2]).
DEFAULT_MIN_CULL_RADIUS_PX
Default minimum projected radius in pixels below which an instance is sub-pixel culled.

Functions§

build_hzb_mip_chain_zero_heap
Returns (total_texels_written, mip_slices, mip_count).
cull_and_select_lod_indirect_zero_heap
Zero-heap CPU/GPU parity execution of 6-plane frustum culling, 2-phase HZB depth-pyramid occlusion culling, 4-tier hybrid LOD selection with hysteresis, and multi-modal stream routing.
select_lod_tier_with_hysteresis
Selects the 4-tier LOD index (0..=3) from an epistemic-weighted screen-space projected radius in pixels, applying a fractional hysteresis deadband around threshold transitions.