pub trait ChannelsReader {
    type Channels;

    // Required methods
    fn filter_block(&self, tile: TileCoordinates) -> bool;
    fn read_block(
        &mut self,
        header: &Header,
        block: UncompressedBlock
    ) -> UnitResult;
    fn into_channels(self) -> Self::Channels;
}
Expand description

Processes pixel blocks from a file and accumulates them into multiple channels per layer.

Required Associated Types§

source

type Channels

The type of the resulting channel collection

Required Methods§

source

fn filter_block(&self, tile: TileCoordinates) -> bool

Specify whether a single block of pixels should be loaded from the file

source

fn read_block( &mut self, header: &Header, block: UncompressedBlock ) -> UnitResult

Load a single pixel block, which has not been filtered, into the reader, accumulating the channel data

source

fn into_channels(self) -> Self::Channels

Deliver the final accumulated channel collection for the image

Implementors§

source§

impl<PixelStorage, SetPixel, PxReader, Pixel> ChannelsReader for SpecificChannelsReader<PixelStorage, SetPixel, PxReader, Pixel>where PxReader: RecursivePixelReader, PxReader::RecursivePixel: IntoTuple<Pixel>, PxReader::RecursiveChannelDescriptions: IntoNonRecursive, SetPixel: Fn(&mut PixelStorage, Vec2<usize>, Pixel),

source§

impl<S: SamplesReader> ChannelsReader for AnyChannelsReader<S>