pub struct TextureDescriptor<'a> {
pub label: Label<'a>,
pub size: Extent3d,
pub mip_level_count: u32,
pub sample_count: u32,
pub dimension: TextureDimension,
pub format: TextureFormat,
pub usage: TextureUses,
pub memory_flags: MemoryFlags,
pub texture_binding_view_dimension: Option<TextureViewDimension>,
pub view_formats: Vec<TextureFormat>,
}Fields§
§label: Label<'a>§size: Extent3d§mip_level_count: u32§sample_count: u32§dimension: TextureDimension§format: TextureFormat§usage: TextureUses§memory_flags: MemoryFlags§texture_binding_view_dimension: Option<TextureViewDimension>The view dimension texture bindings will use.
Must be Some on devices without
ARBITRARY_BINDING_VIEW_DIMENSIONS
(GLES), ignored otherwise.
view_formats: Vec<TextureFormat>Allows views of this texture to have a different format than the texture does.
Implementations§
Source§impl TextureDescriptor<'_>
impl TextureDescriptor<'_>
pub fn copy_extent(&self) -> CopyExtent
pub fn is_cube_compatible(&self) -> bool
pub fn array_layer_count(&self) -> u32
Trait Implementations§
Source§impl<'a> Clone for TextureDescriptor<'a>
impl<'a> Clone for TextureDescriptor<'a>
Auto Trait Implementations§
impl<'a> Forget for TextureDescriptor<'a>
impl<'a> Freeze for TextureDescriptor<'a>where
&'a str: Freeze,
InternalBitFlags: Freeze,
InternalBitFlags: Freeze,
*const u8 is !null: Freeze,
PhantomData<TextureFormat>: Freeze,
impl<'a> Move for TextureDescriptor<'a>
impl<'a> RefUnwindSafe for TextureDescriptor<'a>where
InternalBitFlags: RefUnwindSafe,
InternalBitFlags: RefUnwindSafe,
impl<'a> Send for TextureDescriptor<'a>
impl<'a> Sync for TextureDescriptor<'a>
impl<'a> Unpin for TextureDescriptor<'a>
impl<'a> UnsafeUnpin for TextureDescriptor<'a>where
&'a str: UnsafeUnpin,
InternalBitFlags: UnsafeUnpin,
InternalBitFlags: UnsafeUnpin,
*const u8 is !null: UnsafeUnpin,
PhantomData<TextureFormat>: UnsafeUnpin,
impl<'a> UnwindSafe for TextureDescriptor<'a>where
&'a str: UnwindSafe,
InternalBitFlags: UnwindSafe,
InternalBitFlags: UnwindSafe,
RawVecInner: 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