pub struct TextureDescriptor {
pub width: usize,
pub height: usize,
pub depth: usize,
pub address_mode: AddressMode,
pub filter_mode: FilterMode,
pub normalized_coords: bool,
}Expand description
Texture descriptor
Fields§
§width: usize§height: usize§depth: usize§address_mode: AddressMode§filter_mode: FilterMode§normalized_coords: boolImplementations§
Source§impl TextureDescriptor
impl TextureDescriptor
Sourcepub fn new_3d(width: usize, height: usize, depth: usize) -> Self
pub fn new_3d(width: usize, height: usize, depth: usize) -> Self
Create a 3D texture descriptor
Sourcepub fn with_address_mode(self, mode: AddressMode) -> Self
pub fn with_address_mode(self, mode: AddressMode) -> Self
Set address mode
Sourcepub fn with_filter_mode(self, mode: FilterMode) -> Self
pub fn with_filter_mode(self, mode: FilterMode) -> Self
Set filter mode
Sourcepub fn with_normalized_coords(self, normalized: bool) -> Self
pub fn with_normalized_coords(self, normalized: bool) -> Self
Enable normalized coordinates
Trait Implementations§
Source§impl Clone for TextureDescriptor
impl Clone for TextureDescriptor
Source§fn clone(&self) -> TextureDescriptor
fn clone(&self) -> TextureDescriptor
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for TextureDescriptor
impl RefUnwindSafe for TextureDescriptor
impl Send for TextureDescriptor
impl Sync for TextureDescriptor
impl Unpin for TextureDescriptor
impl UnsafeUnpin for TextureDescriptor
impl UnwindSafe for TextureDescriptor
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