Skip to main content

Module uniforms

Module uniforms 

Source
Expand description

The #[repr(C)] blocks the CPU uploads into the single-source .slang shaders, declared once for every backend (see uniforms/mod.rs).

Re-exports§

pub use bindless::BINDLESS_POOL_SIZE;
pub use geometry::DecalParams;
pub use geometry::DecalView;
pub use geometry::GpuParticle;
pub use geometry::LineView;
pub use geometry::ParticleView;
pub use geometry::SkinParams;
pub use post::AutoExposureParams;
pub use post::HizParams;
pub use post::TaaParams;
pub use probe::MAX_PROBES;
pub use probe::ProbeSet;
pub use probe::ProbeUniforms;
pub use transparent::GlassMeshParams;
pub use transparent::GlassParams;
pub use transparent::TransparentView;
pub use transparent::WATER_MAX_WAVES;
pub use transparent::WaterParams;
pub use transparent::WaterWaveGpu;
pub use view::GBufferModel;
pub use view::GBufferView;
pub use view::ViewUniforms;

Modules§

bindless
The bindless texture pool’s capacity, shared by every backend that declares the pool as a fixed-size array.
geometry
The passes that draw their own geometry into the main target: projected decals, world-space lines, and the GPU particle system.
post
The small parameter blocks the fullscreen post passes and the two compute helpers that feed them take.
probe
The reflection-probe set the forward, SSR and ray-traced resolves all read. Matches ProbeUniforms / ProbeSet in shaders/probe_types.slang, whose MAX_PROBES is baked in from the constant below.
transparent
What the transparent pass binds: the shared per-frame view block, and the per-record tunables of its producers – glass panes, see-through glass meshes, and water surfaces.
view
The camera blocks: what the forward pass and the G-buffer pre-pass need to place a fragment, and the per-draw model pair the pre-pass differentiates for motion vectors.