Trait exr::image::read::specific_channels::RecursivePixelReader

source ·
pub trait RecursivePixelReader {
    type RecursiveChannelDescriptions;
    type RecursivePixel: Copy + Default + 'static;

    // Required methods
    fn get_descriptions(&self) -> Self::RecursiveChannelDescriptions;
    fn read_pixels<'s, FullPixel>(
        &self,
        bytes: &'s [u8],
        pixels: &mut [FullPixel],
        get_pixel: impl Fn(&mut FullPixel) -> &mut Self::RecursivePixel,
    );
}
Expand description

A reader containing sub-readers for reading the pixel content of an image.

Required Associated Types§

source

type RecursiveChannelDescriptions

The channel descriptions from the image. Will be converted to a tuple before being stored in SpecificChannels<_, ChannelDescriptions>.

source

type RecursivePixel: Copy + Default + 'static

The pixel type. Will be converted to a tuple at the end of the process.

Required Methods§

source

fn get_descriptions(&self) -> Self::RecursiveChannelDescriptions

Returns the channel descriptions based on the channels in the file.

source

fn read_pixels<'s, FullPixel>( &self, bytes: &'s [u8], pixels: &mut [FullPixel], get_pixel: impl Fn(&mut FullPixel) -> &mut Self::RecursivePixel, )

Read the line of pixels.

Object Safety§

This trait is not object safe.

Implementors§