Struct comfy_wgpu::egui::epaint::textures::TextureMeta
pub struct TextureMeta {
pub name: String,
pub size: [usize; 2],
pub bytes_per_pixel: usize,
pub retain_count: usize,
pub options: TextureOptions,
}Expand description
Meta-data about an allocated texture.
Fields§
§name: StringA human-readable name useful for debugging.
size: [usize; 2]width x height
bytes_per_pixel: usize4 or 1
retain_count: usizeFree when this reaches zero.
options: TextureOptionsThe texture filtering mode to use when rendering.
Implementations§
§impl TextureMeta
impl TextureMeta
pub fn bytes_used(&self) -> usize
pub fn bytes_used(&self) -> usize
Size in bytes.
width x height x Self::bytes_per_pixel.
Trait Implementations§
§impl Clone for TextureMeta
impl Clone for TextureMeta
§fn clone(&self) -> TextureMeta
fn clone(&self) -> TextureMeta
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read more§impl Debug for TextureMeta
impl Debug for TextureMeta
§impl PartialEq<TextureMeta> for TextureMeta
impl PartialEq<TextureMeta> for TextureMeta
§fn eq(&self, other: &TextureMeta) -> bool
fn eq(&self, other: &TextureMeta) -> bool
This method tests for
self and other values to be equal, and is used
by ==.impl Eq for TextureMeta
impl StructuralEq for TextureMeta
impl StructuralPartialEq for TextureMeta
Auto Trait Implementations§
impl RefUnwindSafe for TextureMeta
impl Send for TextureMeta
impl Sync for TextureMeta
impl Unpin for TextureMeta
impl UnwindSafe for TextureMeta
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<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.