pub struct WebpAnimEncoder;Expand description
Encoder for animated WebP files.
Implementations§
Source§impl WebpAnimEncoder
impl WebpAnimEncoder
Sourcepub fn encode(
frames: &[WebpAnimFrame],
config: &WebpAnimConfig,
) -> CodecResult<Vec<u8>>
pub fn encode( frames: &[WebpAnimFrame], config: &WebpAnimConfig, ) -> CodecResult<Vec<u8>>
Encode a sequence of frames into an animated WebP byte stream.
The canvas dimensions are derived from the maximum extent of all frames (x_offset + width, y_offset + height). All frames must have valid pixel data matching their declared width/height.
Auto Trait Implementations§
impl Freeze for WebpAnimEncoder
impl RefUnwindSafe for WebpAnimEncoder
impl Send for WebpAnimEncoder
impl Sync for WebpAnimEncoder
impl Unpin for WebpAnimEncoder
impl UnsafeUnpin for WebpAnimEncoder
impl UnwindSafe for WebpAnimEncoder
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more