Enum oxipng::png::BitDepth [] [src]

pub enum BitDepth {
    One,
    Two,
    Four,
    Eight,
    Sixteen,
}

The number of bits to be used per channel per pixel

Variants

One

One bit per channel per pixel

Two

Two bits per channel per pixel

Four

Four bits per channel per pixel

Eight

Eight bits per channel per pixel

Sixteen

Sixteen bits per channel per pixel

Methods

impl BitDepth

fn as_u8(&self) -> u8

Retrieve the number of bits per channel per pixel as a u8

fn from_u8(depth: u8) -> BitDepth

Parse a number of bits per channel per pixel into a BitDepth

Trait Implementations

impl Display for BitDepth

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

Derived Implementations

impl Copy for BitDepth

impl Clone for BitDepth

fn clone(&self) -> BitDepth

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

impl PartialEq for BitDepth

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

fn ne(&self, __arg_0: &BitDepth) -> bool

impl Debug for BitDepth

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