Struct WebPDecoder

struct WebPDecoder<R> { ... }

WebP Image format decoder.

Supports both lossless and lossy WebP images.

Implementations

impl<R: BufRead + Seek> WebPDecoder<R>

fn new(r: R) -> ImageResult<Self>

Create a new WebPDecoder from the Reader r.

fn has_animation(self: &Self) -> bool

Returns true if the image as described by the bitstream is animated.

fn set_background_color(self: &mut Self, color: Rgba<u8>) -> ImageResult<()>

Sets the background color if the image is an extended and animated webp.

impl<'a, R: 'a + BufRead + Seek> AnimationDecoder for WebPDecoder<R>

fn into_frames(self: Self) -> Frames<'a>

impl<R> Freeze for WebPDecoder<R>

impl<R> RefUnwindSafe for WebPDecoder<R>

impl<R> Send for WebPDecoder<R>

impl<R> Sync for WebPDecoder<R>

impl<R> Unpin for WebPDecoder<R>

impl<R> UnsafeUnpin for WebPDecoder<R>

impl<R> UnwindSafe for WebPDecoder<R>

impl<R: BufRead + Seek> ImageDecoder for WebPDecoder<R>

fn dimensions(self: &Self) -> (u32, u32)
fn color_type(self: &Self) -> ColorType
fn read_image(self: Self, buf: &mut [u8]) -> ImageResult<()>
fn read_image_boxed(self: Box<Self>, buf: &mut [u8]) -> ImageResult<()>
fn icc_profile(self: &mut Self) -> ImageResult<Option<Vec<u8>>>
fn exif_metadata(self: &mut Self) -> ImageResult<Option<Vec<u8>>>
fn orientation(self: &mut Self) -> ImageResult<Orientation>

impl<T> Any for WebPDecoder<R>

fn type_id(self: &Self) -> TypeId

impl<T> Borrow for WebPDecoder<R>

fn borrow(self: &Self) -> &T

impl<T> BorrowMut for WebPDecoder<R>

fn borrow_mut(self: &mut Self) -> &mut T

impl<T> From for WebPDecoder<R>

fn from(t: T) -> T

Returns the argument unchanged.

impl<T> Pointable for WebPDecoder<R>

unsafe fn init(init: <T as Pointable>::Init) -> usize
unsafe fn deref<'a>(ptr: usize) -> &'a T
unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T
unsafe fn drop(ptr: usize)

impl<T, U> Into for WebPDecoder<R>

fn into(self: Self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

impl<T, U> TryFrom for WebPDecoder<R>

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

impl<T, U> TryInto for WebPDecoder<R>

fn try_into(self: Self) -> Result<U, <U as TryFrom<T>>::Error>