Struct image::hdr::HDRAdapter
source · pub struct HDRAdapter<R: BufRead> { /* private fields */ }
Expand description
Adapter to conform to ImageDecoder
trait
Implementations
sourceimpl<R: BufRead> HDRAdapter<R>
impl<R: BufRead> HDRAdapter<R>
sourcepub fn new(r: R) -> ImageResult<HDRAdapter<R>>
pub fn new(r: R) -> ImageResult<HDRAdapter<R>>
Creates adapter
sourcepub fn new_nonstrict(r: R) -> ImageResult<HDRAdapter<R>>
pub fn new_nonstrict(r: R) -> ImageResult<HDRAdapter<R>>
Allows reading old Radiance HDR images
Trait Implementations
sourceimpl<R: Debug + BufRead> Debug for HDRAdapter<R>
impl<R: Debug + BufRead> Debug for HDRAdapter<R>
sourceimpl<R: BufRead> ImageDecoder for HDRAdapter<R>
impl<R: BufRead> ImageDecoder for HDRAdapter<R>
sourcefn dimensions(&mut self) -> ImageResult<(u32, u32)>
fn dimensions(&mut self) -> ImageResult<(u32, u32)>
Returns a tuple containing the width and height of the image
sourcefn colortype(&mut self) -> ImageResult<ColorType>
fn colortype(&mut self) -> ImageResult<ColorType>
Returns the color type of the image e.g. RGB(8) (8bit RGB)
sourcefn row_len(&mut self) -> ImageResult<usize>
fn row_len(&mut self) -> ImageResult<usize>
Returns the length in bytes of one decoded row of the image
sourcefn read_scanline(&mut self, _: &mut [u8]) -> ImageResult<u32>
fn read_scanline(&mut self, _: &mut [u8]) -> ImageResult<u32>
Reads one row from the image into
buf
and returns the row indexsourcefn read_image(&mut self) -> ImageResult<DecodingResult>
fn read_image(&mut self) -> ImageResult<DecodingResult>
Decodes the entire image and return it as a Vector
sourcefn is_animated(&mut self) -> ImageResult<bool>
fn is_animated(&mut self) -> ImageResult<bool>
Returns true if the image is animated
sourcefn into_frames(self) -> ImageResult<Frames>
fn into_frames(self) -> ImageResult<Frames>
Returns the frames of the image Read more
Auto Trait Implementations
impl<R> RefUnwindSafe for HDRAdapter<R>where
R: RefUnwindSafe,
impl<R> Send for HDRAdapter<R>where
R: Send,
impl<R> Sync for HDRAdapter<R>where
R: Sync,
impl<R> Unpin for HDRAdapter<R>where
R: Unpin,
impl<R> UnwindSafe for HDRAdapter<R>where
R: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more