Skip to main content

ChunkStage

Struct ChunkStage 

Source
pub struct ChunkStage {
    pub desc_bytes: Vec<u8>,
    pub realize_count: u32,
    pub instance_bytes: Vec<u8>,
    pub instance_count: u32,
    pub surface_enabled: f32,
    pub surface_height_scale: f32,
    pub surface_patches: Vec<(u32, Vec<u8>, Vec<f32>, Vec<u8>)>,
    pub scatter_aux_bytes: Vec<u8>,
    pub scatter_vis_bytes: Vec<u8>,
    pub scatter_vis_count: u32,
    pub scatter_layer_params: Vec<Vec<u8>>,
}
Expand description

One chunk batch’s CPU-staged data, handed from the main thread to the render thread. desc_bytes is pack_chunks output; instance_bytes is pack_instances output.

Fields§

§desc_bytes: Vec<u8>§realize_count: u32§instance_bytes: Vec<u8>§instance_count: u32§surface_enabled: f32

Global CPU-surface toggle (1.0 once the provider’s base is ready, else 0.0).

§surface_height_scale: f32

Per-metre displaced-radius factor for CPU-surface heights.

§surface_patches: Vec<(u32, Vec<u8>, Vec<f32>, Vec<u8>)>

Per realized chunk: (slot, rgba8 color [tile_res²·4], elevation metres [tile_res²], rgba8-packed world normal [tile_res²·4]).

§scatter_aux_bytes: Vec<u8>

CEL-73 scatter: per-realize-chunk {path_lo, path_hi, face, pad} aux (pack_scatter_aux), parallel to desc_bytes. Empty when no layers.

§scatter_vis_bytes: Vec<u8>

CEL-73 scatter: per-visible-instance {slot, depth} list (pack_scatter_vis) the compact pass gathers from.

§scatter_vis_count: u32§scatter_layer_params: Vec<Vec<u8>>

CEL-73 scatter: one packed ScatterParamsGpu snapshot per layer — re-read every stage so density/height edits flow through as pure uniform updates.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.