Struct gfx::tex::ImageInfoCommon [] [src]

pub struct ImageInfoCommon<F> {
    pub xoffset: u16,
    pub yoffset: u16,
    pub zoffset: u16,
    pub width: u16,
    pub height: u16,
    pub depth: u16,
    pub format: F,
    pub mipmap: u8,
}

Describes a subvolume of a texture, which image data can be uploaded into.

Fields

xoffset
yoffset
zoffset
width
height
depth
format

Format of each texel.

mipmap

Which mipmap to select.

Methods

impl<F> ImageInfoCommon<F>

fn get_texel_count(&self) -> usize

Get the total number of texels.

fn convert<T>(&self, new_format: T) -> ImageInfoCommon<T>

Convert into a differently typed format.

fn is_inside(&self, (u16, u16, u16, AaMode)) -> bool

Check if it fits inside given dimensions.

Trait Implementations

Derived Implementations

impl<F> Debug for ImageInfoCommon<F> where F: Debug

fn fmt(&self, __arg_0: &mut Formatter) -> Result<(), Error>

impl<F> Clone for ImageInfoCommon<F> where F: Clone

fn clone(&self) -> ImageInfoCommon<F>

1.0.0fn clone_from(&mut self, source: &Self)

impl<F> Copy for ImageInfoCommon<F> where F: Copy

impl<F> Hash for ImageInfoCommon<F> where F: Hash

fn hash<__H>(&self, __arg_0: &mut __H) where __H: Hasher

impl<F> PartialOrd<ImageInfoCommon<F>> for ImageInfoCommon<F> where F: PartialOrd<F>

fn partial_cmp(&self, __arg_0: &ImageInfoCommon<F>) -> Option<Ordering>

fn lt(&self, __arg_0: &ImageInfoCommon<F>) -> bool

fn le(&self, __arg_0: &ImageInfoCommon<F>) -> bool

fn gt(&self, __arg_0: &ImageInfoCommon<F>) -> bool

fn ge(&self, __arg_0: &ImageInfoCommon<F>) -> bool

impl<F> PartialEq<ImageInfoCommon<F>> for ImageInfoCommon<F> where F: PartialEq<F>

fn eq(&self, __arg_0: &ImageInfoCommon<F>) -> bool

fn ne(&self, __arg_0: &ImageInfoCommon<F>) -> bool

impl<F> Ord for ImageInfoCommon<F> where F: Ord

fn cmp(&self, __arg_0: &ImageInfoCommon<F>) -> Ordering

impl<F> Eq for ImageInfoCommon<F> where F: Eq