[][src]Enum grr::ImageType

pub enum ImageType {
    D1 {
        width: u32,
        layers: u32,
    },
    D2 {
        width: u32,
        height: u32,
        layers: u32,
        samples: u32,
    },
    D3 {
        width: u32,
        height: u32,
        depth: u32,
    },
}

Image dimensionality type.

Layer, as in arrays or cube maps, don't affect the dimensionality type.

Variants

D1

Fields of D1

width: u32layers: u32
D2

Fields of D2

width: u32height: u32layers: u32samples: u32
D3

Fields of D3

width: u32height: u32depth: u32

Implementations

impl ImageType[src]

pub fn num_texels(&self) -> usize[src]

Return the number of texels in the top layer of the image.

pub fn width(&self) -> u32[src]

Return the width of the image.

pub fn height(&self) -> u32[src]

Return the height of the image.

pub fn depth(&self) -> u32[src]

Return the height of the image.

pub fn full_extent(&self) -> Extent[src]

Full extent of the image dimensions for a single layer.

pub fn samples(&self) -> u32[src]

Return the number of samples in a texel of the image.

pub fn layers(&self) -> u32[src]

Return the number of layers in the texutre.

Trait Implementations

impl Clone for ImageType[src]

impl Copy for ImageType[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.