Struct comfy_wgpu::egui::util::cache::FrameCache
source · pub struct FrameCache<Value, Computer> { /* private fields */ }Expand description
Caches the results of a computation for one frame. If it is still used next frame, it is not recomputed. If it is not used next frame, it is evicted from the cache to save memory.
Implementations§
source§impl<Value, Computer> FrameCache<Value, Computer>
impl<Value, Computer> FrameCache<Value, Computer>
pub fn new(computer: Computer) -> FrameCache<Value, Computer>
sourcepub fn evice_cache(&mut self)
pub fn evice_cache(&mut self)
Must be called once per frame to clear the cache.
source§impl<Value, Computer> FrameCache<Value, Computer>
impl<Value, Computer> FrameCache<Value, Computer>
Trait Implementations§
source§impl<Value, Computer> CacheTrait for FrameCache<Value, Computer>where
Value: 'static + Send + Sync,
Computer: 'static + Send + Sync,
impl<Value, Computer> CacheTrait for FrameCache<Value, Computer>where Value: 'static + Send + Sync, Computer: 'static + Send + Sync,
source§impl<Value, Computer> Default for FrameCache<Value, Computer>where
Computer: Default,
impl<Value, Computer> Default for FrameCache<Value, Computer>where Computer: Default,
source§fn default() -> FrameCache<Value, Computer>
fn default() -> FrameCache<Value, Computer>
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl<Value, Computer> RefUnwindSafe for FrameCache<Value, Computer>where Computer: RefUnwindSafe, Value: RefUnwindSafe,
impl<Value, Computer> Send for FrameCache<Value, Computer>where Computer: Send, Value: Send,
impl<Value, Computer> Sync for FrameCache<Value, Computer>where Computer: Sync, Value: Sync,
impl<Value, Computer> Unpin for FrameCache<Value, Computer>where Computer: Unpin, Value: Unpin,
impl<Value, Computer> UnwindSafe for FrameCache<Value, Computer>where Computer: UnwindSafe, Value: UnwindSafe,
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