[][src]Trait gf::mc::image::ImageLoader

pub trait ImageLoader {
    fn from_bytes(&self, bytes: &[u8]) -> Result<Image>;

    fn read_from_file<P: AsRef<Path>>(&self, path: P) -> Result<Image> { ... }
}

An Image loader.

Required methods

fn from_bytes(&self, bytes: &[u8]) -> Result<Image>

Load an image from bytes.

Loading content...

Provided methods

fn read_from_file<P: AsRef<Path>>(&self, path: P) -> Result<Image>

Load an image from file.

Loading content...

Implementors

Loading content...