Enum png::ColorType [] [src]

pub enum ColorType {
    Grayscale,
    RGB,
    Indexed,
    GrayscaleAlpha,
    RGBA,
}

Variants

Grayscale
RGB
Indexed
GrayscaleAlpha
RGBA

Methods

impl ColorType

fn samples(&self) -> usize

Returns the number of samples used per pixel of ColorType

fn from_u8(n: u8) -> Option<ColorType>

u8 -> Self. Temporary solution until Rust provides a canonical one.

Trait Implementations

impl<W: Write> Parameter<Encoder<W>> for ColorType

fn set_param(self, this: &mut Encoder<W>)

Derived Implementations

impl Eq for ColorType

impl PartialEq for ColorType

fn eq(&self, __arg_0: &ColorType) -> bool

1.0.0fn ne(&self, other: &Rhs) -> bool

impl Copy for ColorType

impl Clone for ColorType

fn clone(&self) -> ColorType

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

impl Debug for ColorType

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