pub struct Texture2DArray { /* private fields */ }
Expand description
2d array texture
Implementations§
Source§impl Texture2DArray
impl Texture2DArray
Sourcepub fn new_empty() -> Texture2DArray
pub fn new_empty() -> Texture2DArray
Create an empty texture 2D array.
Sourcepub fn new(
format: Format,
extent: Extent2d,
layers: usize,
levels: usize,
) -> Texture2DArray
pub fn new( format: Format, extent: Extent2d, layers: usize, levels: usize, ) -> Texture2DArray
Create a texture2d_array and allocate a new storage_linear.
Sourcepub fn new_with_mipmap_chain(
format: Format,
extent: Extent2d,
layers: usize,
) -> Texture2DArray
pub fn new_with_mipmap_chain( format: Format, extent: Extent2d, layers: usize, ) -> Texture2DArray
Create a texture2d_array and allocate a new storage_linear with a complete mipmap chain.
Create a texture2d_array view with an existing storage_linear.
Create a texture2d_array view with an existing storage_linear.
Create a texture2d_array view, reference a subset of an existing texture2d_array instance.
Trait Implementations§
Source§impl GliTexture for Texture2DArray
impl GliTexture for Texture2DArray
const TARGET_TYPE: Target = Target::TARGET_2D_ARRAY
type ExtentType = Extent2d
Source§fn extent(&self, level: usize) -> Self::ExtentType
fn extent(&self, level: usize) -> Self::ExtentType
Return the corresponding extent type of the texture instance,
which represents the size of a specific mip-level of this texture(width, height and depth).
fn set_swizzles(&mut self, swizzles: Swizzles)
Source§fn base_face(&self) -> usize
fn base_face(&self) -> usize
Return the base face of the texture instance, effectively a memory offset in the actual texture storage_type
to identify where to start reading the faces.
Source§fn base_layer(&self) -> usize
fn base_layer(&self) -> usize
Return the base layer of the texture instance, effectively a memory offset in the actual texture storage_type
to identify where to start reading the layers.
Source§fn base_level(&self) -> usize
fn base_level(&self) -> usize
Return the base level of the texture instance, effectively a memory offset in the actual texture storage_type
to identify where to start reading the levels.
Source§fn copy(
&mut self,
src_texture: &Self,
src_layer: usize,
src_face: usize,
src_level: usize,
dst_layer: usize,
dst_face: usize,
dst_level: usize,
)
fn copy( &mut self, src_texture: &Self, src_layer: usize, src_face: usize, src_level: usize, dst_layer: usize, dst_face: usize, dst_level: usize, )
Copy a specific image of a texture.
Source§fn copy_subset(
&mut self,
src_texture: &Self,
src_layer: usize,
src_face: usize,
src_level: usize,
src_offset: Extent3d,
dst_layer: usize,
dst_face: usize,
dst_level: usize,
dst_offset: Extent3d,
extent: Extent3d,
)
fn copy_subset( &mut self, src_texture: &Self, src_layer: usize, src_face: usize, src_level: usize, src_offset: Extent3d, dst_layer: usize, dst_face: usize, dst_level: usize, dst_offset: Extent3d, extent: Extent3d, )
Copy a subset of a specific image of a texture.
Source§fn data(&self) -> *const c_void
fn data(&self) -> *const c_void
Return a pointer to the beginning of the texture instance data.
unsafe fn data_mut(&mut self) -> *mut c_void
Source§fn empty(&self) -> bool
fn empty(&self) -> bool
Return whether the texture instance is empty, no storage_type or description have been assigned to the instance.
Source§fn max_face(&self) -> usize
fn max_face(&self) -> usize
Return the max face of the texture instance, effectively a memory offset to the beginning of the last face
in the actual texture storage_type that the texture instance can access.
Source§fn max_layer(&self) -> usize
fn max_layer(&self) -> usize
Return the max layer of the texture instance, effectively a memory offset to the beginning of the last layer
in the actual texture storage_type that the texture instance can access.
Source§fn max_level(&self) -> usize
fn max_level(&self) -> usize
Return the max level of the texture instance, effectively a memory offset to the beginning of the last level
in the actual texture storage_type that the texture instance can access.
Source§fn size_at_level(&self, level: usize) -> usize
fn size_at_level(&self, level: usize) -> usize
Return the memory size of a specific level identified by Level.
Source§impl PartialEq for Texture2DArray
impl PartialEq for Texture2DArray
Source§fn eq(&self, other: &Texture2DArray) -> bool
fn eq(&self, other: &Texture2DArray) -> bool
Compare two textures. Two textures are the same when the data, the format and the targets are the same.
Source§fn ne(&self, other: &Texture2DArray) -> bool
fn ne(&self, other: &Texture2DArray) -> bool
Compare two textures. Two textures are the same when the data, the format and the targets are the same.
impl Eq for Texture2DArray
Auto Trait Implementations§
impl Freeze for Texture2DArray
impl RefUnwindSafe for Texture2DArray
impl Send for Texture2DArray
impl Sync for Texture2DArray
impl Unpin for Texture2DArray
impl UnwindSafe for Texture2DArray
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