[][src]Struct gstreamer::Fraction

pub struct Fraction(pub Rational32);

Methods

impl Fraction[src]

pub fn new(num: i32, den: i32) -> Fraction[src]

pub fn approximate_f32(x: f32) -> Option<Fraction>[src]

pub fn approximate_f64(x: f64) -> Option<Fraction>[src]

Trait Implementations

impl Copy for Fraction[src]

impl From<i32> for Fraction[src]

impl From<(i32, i32)> for Fraction[src]

impl From<Ratio<i32>> for Fraction[src]

impl From<Fraction> for Rational32[src]

impl AsRef<Ratio<i32>> for Fraction[src]

impl Clone for Fraction[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl Eq for Fraction[src]

impl Ord for Fraction[src]

fn max(self, other: Self) -> Self1.21.0[src]

Compares and returns the maximum of two values. Read more

fn min(self, other: Self) -> Self1.21.0[src]

Compares and returns the minimum of two values. Read more

fn clamp(self, min: Self, max: Self) -> Self[src]

🔬 This is a nightly-only experimental API. (clamp)

Restrict a value to a certain interval. Read more

impl Into<(i32, i32)> for Fraction[src]

impl PartialEq<Fraction> for Fraction[src]

impl PartialOrd<Fraction> for Fraction[src]

impl Display for Fraction[src]

impl Add<Fraction> for Fraction[src]

type Output = Fraction

The resulting type after applying the + operator.

impl<'_> Add<Fraction> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the + operator.

impl<'_> Add<&'_ Fraction> for Fraction[src]

type Output = Fraction

The resulting type after applying the + operator.

impl<'_, '_> Add<&'_ Fraction> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the + operator.

impl Add<i32> for Fraction[src]

type Output = Fraction

The resulting type after applying the + operator.

impl<'_> Add<i32> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the + operator.

impl<'_> Add<&'_ i32> for Fraction[src]

type Output = Fraction

The resulting type after applying the + operator.

impl<'_, '_> Add<&'_ i32> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the + operator.

impl Add<Fraction> for i32[src]

type Output = Fraction

The resulting type after applying the + operator.

impl<'_> Add<&'_ Fraction> for i32[src]

type Output = Fraction

The resulting type after applying the + operator.

impl<'_> Add<Fraction> for &'_ i32[src]

type Output = Fraction

The resulting type after applying the + operator.

impl<'_, '_> Add<&'_ Fraction> for &'_ i32[src]

type Output = Fraction

The resulting type after applying the + operator.

impl DerefMut for Fraction[src]

impl Deref for Fraction[src]

type Target = Rational32

The resulting type after dereferencing.

impl Debug for Fraction[src]

impl Sub<Fraction> for Fraction[src]

type Output = Fraction

The resulting type after applying the - operator.

impl<'_> Sub<Fraction> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the - operator.

impl<'_> Sub<&'_ Fraction> for Fraction[src]

type Output = Fraction

The resulting type after applying the - operator.

impl<'_, '_> Sub<&'_ Fraction> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the - operator.

impl Sub<i32> for Fraction[src]

type Output = Fraction

The resulting type after applying the - operator.

impl<'_> Sub<i32> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the - operator.

impl<'_> Sub<&'_ i32> for Fraction[src]

type Output = Fraction

The resulting type after applying the - operator.

impl<'_, '_> Sub<&'_ i32> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the - operator.

impl Sub<Fraction> for i32[src]

type Output = Fraction

The resulting type after applying the - operator.

impl<'_> Sub<&'_ Fraction> for i32[src]

type Output = Fraction

The resulting type after applying the - operator.

impl<'_> Sub<Fraction> for &'_ i32[src]

type Output = Fraction

The resulting type after applying the - operator.

impl<'_, '_> Sub<&'_ Fraction> for &'_ i32[src]

type Output = Fraction

The resulting type after applying the - operator.

impl Mul<Fraction> for Fraction[src]

type Output = Fraction

The resulting type after applying the * operator.

impl<'_> Mul<Fraction> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the * operator.

impl<'_> Mul<&'_ Fraction> for Fraction[src]

type Output = Fraction

The resulting type after applying the * operator.

impl<'_, '_> Mul<&'_ Fraction> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the * operator.

impl Mul<i32> for Fraction[src]

type Output = Fraction

The resulting type after applying the * operator.

impl<'_> Mul<i32> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the * operator.

impl<'_> Mul<&'_ i32> for Fraction[src]

type Output = Fraction

The resulting type after applying the * operator.

impl<'_, '_> Mul<&'_ i32> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the * operator.

impl Mul<Fraction> for i32[src]

type Output = Fraction

The resulting type after applying the * operator.

impl<'_> Mul<&'_ Fraction> for i32[src]

type Output = Fraction

The resulting type after applying the * operator.

impl<'_> Mul<Fraction> for &'_ i32[src]

type Output = Fraction

The resulting type after applying the * operator.

impl<'_, '_> Mul<&'_ Fraction> for &'_ i32[src]

type Output = Fraction

The resulting type after applying the * operator.

impl Div<Fraction> for Fraction[src]

type Output = Fraction

The resulting type after applying the / operator.

impl<'_> Div<Fraction> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the / operator.

impl<'_> Div<&'_ Fraction> for Fraction[src]

type Output = Fraction

The resulting type after applying the / operator.

impl<'_, '_> Div<&'_ Fraction> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the / operator.

impl Div<i32> for Fraction[src]

type Output = Fraction

The resulting type after applying the / operator.

impl<'_> Div<i32> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the / operator.

impl<'_> Div<&'_ i32> for Fraction[src]

type Output = Fraction

The resulting type after applying the / operator.

impl<'_, '_> Div<&'_ i32> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the / operator.

impl Div<Fraction> for i32[src]

type Output = Fraction

The resulting type after applying the / operator.

impl<'_> Div<&'_ Fraction> for i32[src]

type Output = Fraction

The resulting type after applying the / operator.

impl<'_> Div<Fraction> for &'_ i32[src]

type Output = Fraction

The resulting type after applying the / operator.

impl<'_, '_> Div<&'_ Fraction> for &'_ i32[src]

type Output = Fraction

The resulting type after applying the / operator.

impl Rem<Fraction> for Fraction[src]

type Output = Fraction

The resulting type after applying the % operator.

impl<'_> Rem<Fraction> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the % operator.

impl<'_> Rem<&'_ Fraction> for Fraction[src]

type Output = Fraction

The resulting type after applying the % operator.

impl<'_, '_> Rem<&'_ Fraction> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the % operator.

impl Rem<i32> for Fraction[src]

type Output = Fraction

The resulting type after applying the % operator.

impl<'_> Rem<i32> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the % operator.

impl<'_> Rem<&'_ i32> for Fraction[src]

type Output = Fraction

The resulting type after applying the % operator.

impl<'_, '_> Rem<&'_ i32> for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the % operator.

impl Rem<Fraction> for i32[src]

type Output = Fraction

The resulting type after applying the % operator.

impl<'_> Rem<&'_ Fraction> for i32[src]

type Output = Fraction

The resulting type after applying the % operator.

impl<'_> Rem<Fraction> for &'_ i32[src]

type Output = Fraction

The resulting type after applying the % operator.

impl<'_, '_> Rem<&'_ Fraction> for &'_ i32[src]

type Output = Fraction

The resulting type after applying the % operator.

impl Neg for Fraction[src]

type Output = Fraction

The resulting type after applying the - operator.

impl<'_> Neg for &'_ Fraction[src]

type Output = Fraction

The resulting type after applying the - operator.

impl AddAssign<Fraction> for Fraction[src]

impl<'_> AddAssign<&'_ Fraction> for Fraction[src]

impl AddAssign<i32> for Fraction[src]

impl<'_> AddAssign<&'_ i32> for Fraction[src]

impl SubAssign<Fraction> for Fraction[src]

impl<'_> SubAssign<&'_ Fraction> for Fraction[src]

impl SubAssign<i32> for Fraction[src]

impl<'_> SubAssign<&'_ i32> for Fraction[src]

impl MulAssign<Fraction> for Fraction[src]

impl<'_> MulAssign<&'_ Fraction> for Fraction[src]

impl MulAssign<i32> for Fraction[src]

impl<'_> MulAssign<&'_ i32> for Fraction[src]

impl DivAssign<Fraction> for Fraction[src]

impl<'_> DivAssign<&'_ Fraction> for Fraction[src]

impl DivAssign<i32> for Fraction[src]

impl<'_> DivAssign<&'_ i32> for Fraction[src]

impl RemAssign<Fraction> for Fraction[src]

impl<'_> RemAssign<&'_ Fraction> for Fraction[src]

impl RemAssign<i32> for Fraction[src]

impl<'_> RemAssign<&'_ i32> for Fraction[src]

impl Hash for Fraction[src]

fn hash_slice<H>(data: &[Self], state: &mut H) where
    H: Hasher
1.3.0[src]

Feeds a slice of this type into the given [Hasher]. Read more

impl StaticType for Fraction[src]

impl<'a> FromValue<'a> for Fraction[src]

impl SetValue for Fraction[src]

impl<'a> FromValueOptional<'a> for Fraction[src]

impl<'a> Serialize for Fraction[src]

impl<'de> Deserialize<'de> for Fraction[src]

Auto Trait Implementations

impl Send for Fraction

impl Sync for Fraction

Blanket Implementations

impl<T> From<T> for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> ToValue for T where
    T: SetValue + ?Sized
[src]

impl<T> ToSendValue for T where
    T: ToValue + SetValue + Send + ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: Deserialize<'de>, 
[src]

impl<T, Rhs, Output> NumOps<Rhs, Output> for T where
    T: Sub<Rhs, Output = Output> + Mul<Rhs, Output = Output> + Div<Rhs, Output = Output> + Add<Rhs, Output = Output> + Rem<Rhs, Output = Output>, 
[src]

impl<T, Base> RefNum<Base> for T where
    T: NumOps<Base, Base> + NumOps<&'r Base, Base>, 
[src]

impl<T, Rhs> NumAssignOps<Rhs> for T where
    T: AddAssign<Rhs> + SubAssign<Rhs> + MulAssign<Rhs> + DivAssign<Rhs> + RemAssign<Rhs>, 
[src]