pub struct TextureLease { /* private fields */ }Expand description
A leased pooled texture. Move-only — holding the lease IS
the right to use the texture (see the module doc for the
honest tier statement). Dropping a lease without
TexturePool::release simply lets wgpu free the texture;
safe, just forfeits reuse.
Implementations§
Source§impl TextureLease
impl TextureLease
pub fn key(&self) -> TextureKey
pub fn texture(&self) -> &Texture
pub fn view(&self) -> &TextureView
Sourcepub fn bound_resource(&self) -> BoundResource
pub fn bound_resource(&self) -> BoundResource
The dispatch-path bridge: a BoundResource::Texture
carrying a clone of the leased view, ready for
crate::BoundResources.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for TextureLease
impl !UnwindSafe for TextureLease
impl Freeze for TextureLease
impl Send for TextureLease
impl Sync for TextureLease
impl Unpin for TextureLease
impl UnsafeUnpin for TextureLease
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