pub struct SlotRewriteQueue { /* private fields */ }Expand description
Defers draw-slot rewrites until every in-flight frame has retired.
Implementations§
Source§impl SlotRewriteQueue
impl SlotRewriteQueue
Sourcepub fn new(frames_in_flight: usize) -> Self
pub fn new(frames_in_flight: usize) -> Self
A queue sized for frames_in_flight in-flight frames.
Sourcepub fn queue(&mut self, slot: usize)
pub fn queue(&mut self, slot: usize)
Queue pool slot for rewriting in every per-frame copy. Re-queueing a
slot mid-propagation restarts its countdown, so every copy ends on the
view the caller swapped in last (the rewrite reads the pool at apply
time, not at queue time).
Sourcepub fn begin_frame(&mut self) -> Vec<usize>
pub fn begin_frame(&mut self) -> Vec<usize>
The slots whose descriptor must be rewritten in the frame copy about to record. Call exactly once per frame, after the frame slot’s fence wait. Entries that have now covered every copy are dropped.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for SlotRewriteQueue
impl RefUnwindSafe for SlotRewriteQueue
impl Send for SlotRewriteQueue
impl Sync for SlotRewriteQueue
impl Unpin for SlotRewriteQueue
impl UnsafeUnpin for SlotRewriteQueue
impl UnwindSafe for SlotRewriteQueue
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