pub struct TextureRowLayout {
pub unpadded_bytes_per_row: u32,
pub padded_bytes_per_row: u32,
pub total_bytes: u64,
}Expand description
Texture upload layout under WebGPU’s 256-byte row-alignment rule.
Fields§
§unpadded_bytes_per_row: u32Unpadded bytes of actual pixel data per row (width * bytes_per_texel).
padded_bytes_per_row: u32Padded bytes_per_row (a multiple of 256) to pass to wgpu.
total_bytes: u64Total bytes for the whole image (padded_bytes_per_row * height).
Trait Implementations§
Source§impl Clone for TextureRowLayout
impl Clone for TextureRowLayout
Source§fn clone(&self) -> TextureRowLayout
fn clone(&self) -> TextureRowLayout
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 moreimpl Copy for TextureRowLayout
Source§impl Debug for TextureRowLayout
impl Debug for TextureRowLayout
impl Eq for TextureRowLayout
Source§impl PartialEq for TextureRowLayout
impl PartialEq for TextureRowLayout
Source§fn eq(&self, other: &TextureRowLayout) -> bool
fn eq(&self, other: &TextureRowLayout) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for TextureRowLayout
Auto Trait Implementations§
impl Freeze for TextureRowLayout
impl RefUnwindSafe for TextureRowLayout
impl Send for TextureRowLayout
impl Sync for TextureRowLayout
impl Unpin for TextureRowLayout
impl UnsafeUnpin for TextureRowLayout
impl UnwindSafe for TextureRowLayout
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.