Trait exoquant::ditherer::Ditherer [] [src]

pub trait Ditherer {
    fn remap<'a>(&'a self, image: Box<Iterator<Item=Colorf> + 'a>, width: usize, map: &'a ColorMap, colorspace: &'a ColorSpace) -> Box<Iterator<Item=usize> + 'a>;
}

An interface for dithered color remapping.

End users of this library will most likely not call ditherer::remap directly, but rather use the Remapper helper.

Required Methods

fn remap<'a>(&'a self, image: Box<Iterator<Item=Colorf> + 'a>, width: usize, map: &'a ColorMap, colorspace: &'a ColorSpace) -> Box<Iterator<Item=usize> + 'a>

Remaps an iterator of input pixel (float-)colors of an Image to an Iterator of palette indices.

Implementors