pub(crate) struct BlasTracker {
metadata: ResourceMetadata<Arc<Blas>>,
size: usize,
}
Expand description
A tracker that holds tracks BLASes.
This is mostly a safe shell around ResourceMetadata
Fields§
§metadata: ResourceMetadata<Arc<Blas>>
§size: usize
Implementations§
Source§impl BlasTracker
impl BlasTracker
pub fn new() -> Self
Sourcepub fn insert_single(&mut self, resource: Arc<Blas>) -> &Arc<Blas>
pub fn insert_single(&mut self, resource: Arc<Blas>) -> &Arc<Blas>
Inserts a single resource into the resource tracker.
Returns a reference to the newly inserted resource. (This allows avoiding a clone/reference count increase in many cases.)
Sourcepub fn set_size(&mut self, size: usize)
pub fn set_size(&mut self, size: usize)
Sets the size of all the vectors inside the tracker.
Must be called with the highest possible Texture ID before all unsafe functions are called.
Sourcefn allow_index(&mut self, index: usize)
fn allow_index(&mut self, index: usize)
Extend the vectors to let the given index be valid.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for BlasTracker
impl !RefUnwindSafe for BlasTracker
impl Send for BlasTracker
impl Sync for BlasTracker
impl Unpin for BlasTracker
impl !UnwindSafe for BlasTracker
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