pub struct ScreenPrimitiveBudget { /* private fields */ }Expand description
Explicit primitive, resident CPU/GPU and per-update upload limits. During capacity growth old/new resources may overlap, bounded by twice the resident limits. Input slices and driver/in-flight allocations are excluded.
Implementations§
Source§impl ScreenPrimitiveBudget
impl ScreenPrimitiveBudget
Sourcepub const fn new(
max_primitives: usize,
max_retained_bytes: usize,
max_buffer_bytes: usize,
max_upload_bytes: usize,
) -> Self
pub const fn new( max_primitives: usize, max_retained_bytes: usize, max_buffer_bytes: usize, max_upload_bytes: usize, ) -> Self
Constructs explicit limits; zero count is a valid empty-only budget. Even an empty batch needs one 64-byte GPU buffer slot.
Sourcepub const fn max_primitives(self) -> usize
pub const fn max_primitives(self) -> usize
Maximum submitted primitive count, never silently truncated.
Sourcepub const fn max_retained_bytes(self) -> usize
pub const fn max_retained_bytes(self) -> usize
Retained instance and clip-span CPU capacity ceiling.
Sourcepub const fn max_buffer_bytes(self) -> usize
pub const fn max_buffer_bytes(self) -> usize
GPU instance-buffer capacity ceiling.
Sourcepub const fn max_upload_bytes(self) -> usize
pub const fn max_upload_bytes(self) -> usize
Maximum host instance payload for creation or one complete update.
Trait Implementations§
Source§impl Clone for ScreenPrimitiveBudget
impl Clone for ScreenPrimitiveBudget
impl Copy for ScreenPrimitiveBudget
Source§impl Debug for ScreenPrimitiveBudget
impl Debug for ScreenPrimitiveBudget
Source§impl Default for ScreenPrimitiveBudget
impl Default for ScreenPrimitiveBudget
impl Eq for ScreenPrimitiveBudget
Source§impl PartialEq for ScreenPrimitiveBudget
impl PartialEq for ScreenPrimitiveBudget
impl StructuralPartialEq for ScreenPrimitiveBudget
Auto Trait Implementations§
impl Freeze for ScreenPrimitiveBudget
impl RefUnwindSafe for ScreenPrimitiveBudget
impl Send for ScreenPrimitiveBudget
impl Sync for ScreenPrimitiveBudget
impl Unpin for ScreenPrimitiveBudget
impl UnsafeUnpin for ScreenPrimitiveBudget
impl UnwindSafe for ScreenPrimitiveBudget
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.