pub struct SceneData<'a> {
pub vertices: &'a [Vertex],
pub indices: &'a [u32],
pub draw_objects: Vec<DrawObject>,
pub instanced_clusters: Vec<InstancedCluster>,
pub n_skinned: usize,
pub n_chunk_max: usize,
}Expand description
Static scene geometry and the draw lists built over it.
Fields§
§vertices: &'a [Vertex]The world’s shared static vertex buffer.
indices: &'a [u32]The world’s shared static index buffer.
draw_objects: Vec<DrawObject>One draw record per static placement.
instanced_clusters: Vec<InstancedCluster>One record per instanced-prop cluster.
n_skinned: usizeSkinned draw-object count (the world’s SkinnedMesh count). Sizes each
backend’s shared GPU-cull buffers for the merged total (static +
instances + skinned) at init; the skinned geometry itself is uploaded
later via upload_skinned.
n_chunk_max: usizeWorst-case resident chunk count for a streaming VoxelWorld (0 otherwise). Reserves a chunk record region in the shared GPU-cull buffers at init; resident chunks fold into the indirect path each frame. Honoured by DirectX + Vulkan; Metal’s per-frame rebuild already covers chunks, so it needs no reserve.
Auto Trait Implementations§
impl<'a> Freeze for SceneData<'a>
impl<'a> RefUnwindSafe for SceneData<'a>
impl<'a> Send for SceneData<'a>
impl<'a> Sync for SceneData<'a>
impl<'a> Unpin for SceneData<'a>
impl<'a> UnsafeUnpin for SceneData<'a>
impl<'a> UnwindSafe for SceneData<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<S, T> Duplex<S> for Twhere
T: FromSample<S> + ToSample<S>,
Source§impl<S> FromSample<S> for S
impl<S> FromSample<S> for S
fn from_sample_(s: S) -> S
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more