Struct ThumbnailSourceOptions

Source
pub struct ThumbnailSourceOptions {
    pub option_string: String,
    pub height: i32,
    pub size: Size,
    pub no_rotate: bool,
    pub crop: Interesting,
    pub linear: bool,
    pub import_profile: String,
    pub export_profile: String,
    pub intent: Intent,
    pub fail_on: FailOn,
}
Expand description

Options for thumbnail_source operation

Fields§

§option_string: String

option_string: String -> Options that are passed on to the underlying loader

§height: i32

height: i32 -> Size to this height min: 1, max: 10000000, default: 1

§size: Size

size: Size -> Only upsize, only downsize, or both Both -> VIPS_SIZE_BOTH = 0 [DEFAULT] Up -> VIPS_SIZE_UP = 1 Down -> VIPS_SIZE_DOWN = 2 Force -> VIPS_SIZE_FORCE = 3 Last -> VIPS_SIZE_LAST = 4

§no_rotate: bool

no_rotate: bool -> Don’t use orientation tags to rotate image upright default: false

§crop: Interesting

crop: Interesting -> Reduce to fill target rectangle, then crop None -> VIPS_INTERESTING_NONE = 0 [DEFAULT] Centre -> VIPS_INTERESTING_CENTRE = 1 Entropy -> VIPS_INTERESTING_ENTROPY = 2 Attention -> VIPS_INTERESTING_ATTENTION = 3 Low -> VIPS_INTERESTING_LOW = 4 High -> VIPS_INTERESTING_HIGH = 5 All -> VIPS_INTERESTING_ALL = 6 Last -> VIPS_INTERESTING_LAST = 7

§linear: bool

linear: bool -> Reduce in linear light default: false

§import_profile: String

import_profile: String -> Fallback import profile

§export_profile: String

export_profile: String -> Fallback export profile

§intent: Intent

intent: Intent -> Rendering intent Perceptual -> VIPS_INTENT_PERCEPTUAL = 0 Relative -> VIPS_INTENT_RELATIVE = 1 [DEFAULT] Saturation -> VIPS_INTENT_SATURATION = 2 Absolute -> VIPS_INTENT_ABSOLUTE = 3 Last -> VIPS_INTENT_LAST = 4

§fail_on: FailOn

fail_on: FailOn -> Error level to fail on None -> VIPS_FAIL_ON_NONE = 0 [DEFAULT] Truncated -> VIPS_FAIL_ON_TRUNCATED = 1 Error -> VIPS_FAIL_ON_ERROR = 2 Warning -> VIPS_FAIL_ON_WARNING = 3 Last -> VIPS_FAIL_ON_LAST = 4

Trait Implementations§

Source§

impl Clone for ThumbnailSourceOptions

Source§

fn clone(&self) -> ThumbnailSourceOptions

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for ThumbnailSourceOptions

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for ThumbnailSourceOptions

Source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

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

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

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

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

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

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

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

Performs the conversion.