[][src]Trait dezoomify_rs::dezoomer::TileProvider

pub trait TileProvider: Debug {
    fn next_tiles(
        &mut self,
        previous: Option<TileFetchResult>
    ) -> Vec<TileReference>; fn post_process_fn(&self) -> PostProcessFn { ... }
fn name(&self) -> String { ... }
fn title(&self) -> Option<String> { ... }
fn size_hint(&self) -> Option<Vec2d> { ... }
fn http_headers(&self) -> HashMap<String, String> { ... } }

A single tiled image

Required methods

fn next_tiles(
    &mut self,
    previous: Option<TileFetchResult>
) -> Vec<TileReference>

Provide a list of image tiles. Should be called repetitively until it returns an empty list. Each new call takes the results of the previous tile fetch as a parameter.

Loading content...

Provided methods

fn post_process_fn(&self) -> PostProcessFn

A function that takes the downloaded tile bytes and decodes them

fn name(&self) -> String

The name of the format

fn title(&self) -> Option<String>

The title of the image

fn size_hint(&self) -> Option<Vec2d>

The width and height of the image. Can be unknown when dezooming starts

fn http_headers(&self) -> HashMap<String, String>

A collection of http headers to use when requesting the tiles

Loading content...

Implementors

impl<T: TilesRect> TileProvider for T[src]

Loading content...