pub struct TextureProperties<'a> { /* private fields */ }
Expand description

Proxy type to texture properties.

Implementations§

source§

impl<'a> TextureProperties<'a>

source

pub fn alpha(&self) -> Result<Option<f64>, Error>

Returns default alpha value.

source

pub fn alpha_or_default(&self) -> Result<f64, Error>

Returns default alpha value.

Returns default if the value is not set.

source

pub fn wrap_mode_u(&self) -> Result<Option<WrapMode>, Error>

Returns wrap mode U.

source

pub fn wrap_mode_u_or_default(&self) -> Result<WrapMode, Error>

Returns wrap mode U.

Returns default if the value is not set.

source

pub fn wrap_mode_v(&self) -> Result<Option<WrapMode>, Error>

Returns wrap mode V.

source

pub fn wrap_mode_v_or_default(&self) -> Result<WrapMode, Error>

Returns wrap mode V.

Returns default if the value is not set.

source

pub fn uv_swap(&self) -> Result<Option<bool>, Error>

Returns whether the UV should be swapped or not.

Returns Some(true) if UV should be swapped.

source

pub fn uv_swap_or_default(&self) -> Result<bool, Error>

Returns whether the UV should be swapped or not.

Returns true if UV should be swapped.

Returns default if the value is not set.

source

pub fn premultiply_alpha(&self) -> Result<Option<bool>, Error>

Returns premultiply-alpha flag.

Returns Some(true) if the alpha is premultiplied.

source

pub fn premultiply_alpha_or_default(&self) -> Result<bool, Error>

Returns premultiply-alpha flag.

Returns true if the alpha is premultiplied.

Returns default if the value is not set.

source

pub fn translation(&self) -> Result<Option<Vector3<f64>>, Error>

Returns default translation vector.

source

pub fn translation_or_default(&self) -> Result<Vector3<f64>, Error>

Returns default translation vector.

Returns default if the value is not set.

source

pub fn rotation(&self) -> Result<Option<[f64; 3]>, Error>

Returns default rotation vector.

source

pub fn rotation_or_default(&self) -> Result<[f64; 3], Error>

Returns default rotation vector.

Returns default if the value is not set.

source

pub fn scaling(&self) -> Result<Option<Vector3<f64>>, Error>

Returns default scaling vector.

source

pub fn scaling_or_default(&self) -> Result<Vector3<f64>, Error>

Returns default scaling vector.

Returns default if the value is not set.

source

pub fn rotation_pivot(&self) -> Result<Option<Point3<f64>>, Error>

Returns rotation pivot vector.

source

pub fn rotation_pivot_or_default(&self) -> Result<Point3<f64>, Error>

Returns rotation pivot vector.

Returns default if the value is not set.

source

pub fn scaling_pivot(&self) -> Result<Option<Point3<f64>>, Error>

Returns rotation pivot vector.

source

pub fn scaling_pivot_or_default(&self) -> Result<Point3<f64>, Error>

Returns scaling pivot vector.

Returns default if the value is not set.

source

pub fn blend_mode(&self) -> Result<Option<BlendMode>, Error>

Returns texture blend mode.

source

pub fn blend_mode_or_default(&self) -> Result<BlendMode, Error>

Returns texture blend mode.

Returns default if the value is not set.

source

pub fn uv_set(&self) -> Result<Option<&'a str>, Error>

Returns UV set name.

source

pub fn uv_set_or_default(&self) -> Result<&'a str, Error>

Returns UV set name.

Returns default if the value is not set.

Methods from Deref<Target = ObjectProperties<'a>>§

source

pub fn get_property(&self, name: &str) -> Option<PropertyHandle<'a>>

Returns property handle if found.

Trait Implementations§

source§

impl<'a> Clone for TextureProperties<'a>

source§

fn clone(&self) -> TextureProperties<'a>

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<'a> Debug for TextureProperties<'a>

source§

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

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

impl<'a> Deref for TextureProperties<'a>

§

type Target = ObjectProperties<'a>

The resulting type after dereferencing.
source§

fn deref(&self) -> &Self::Target

Dereferences the value.
source§

impl<'a> Copy for TextureProperties<'a>

Auto Trait Implementations§

§

impl<'a> RefUnwindSafe for TextureProperties<'a>

§

impl<'a> Send for TextureProperties<'a>

§

impl<'a> Sync for TextureProperties<'a>

§

impl<'a> Unpin for TextureProperties<'a>

§

impl<'a> UnwindSafe for TextureProperties<'a>

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

const: unstable · source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

const: unstable · source§

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

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

const: unstable · source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

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

const: unstable · 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 Twhere T: Clone,

§

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 Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
const: unstable · source§

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

Performs the conversion.
source§

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

§

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

The type returned in the event of a conversion error.
const: unstable · source§

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

Performs the conversion.