pub struct Settings {
pub width: Option<u32>,
pub height: Option<u32>,
pub quality: u8,
pub fast: bool,
pub repeat: Repeat,
}
Expand description
Encoding settings for the new()
function
Fields§
§width: Option<u32>
Resize to max this width if non-0.
height: Option<u32>
Resize to max this height if width is non-0. Note that aspect ratio is not preserved.
quality: u8
1-100, but useful range is 50-100. Recommended to set to 100.
fast: bool
Lower quality, but faster encode.
repeat: Repeat
Sets the looping method for the image sequence.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Settings
impl RefUnwindSafe for Settings
impl Send for Settings
impl Sync for Settings
impl Unpin for Settings
impl UnwindSafe for Settings
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