Struct cgmath::Decomposed
source · pub struct Decomposed<V: VectorSpace, R> {
pub scale: V::Scalar,
pub rot: R,
pub disp: V,
}
Expand description
A generic transformation consisting of a rotation, displacement vector and scale amount.
Fields§
§scale: V::Scalar
§rot: R
§disp: V
Trait Implementations§
source§impl<S, R, E: BaseFloat> ApproxEq for Decomposed<S, R>where
S: ApproxEq<Epsilon = E> + VectorSpace,
S::Scalar: ApproxEq<Epsilon = E>,
R: ApproxEq<Epsilon = E>,
impl<S, R, E: BaseFloat> ApproxEq for Decomposed<S, R>where S: ApproxEq<Epsilon = E> + VectorSpace, S::Scalar: ApproxEq<Epsilon = E>, R: ApproxEq<Epsilon = E>,
source§fn default_epsilon() -> E
fn default_epsilon() -> E
The default tolerance to use when testing values that are close together. Read more
source§fn default_max_relative() -> E
fn default_max_relative() -> E
The default relative tolerance for testing values that are far-apart. Read more
source§fn default_max_ulps() -> u32
fn default_max_ulps() -> u32
The default ULPs to tolerate when testing values that are far-apart. Read more
source§fn relative_eq(&self, other: &Self, epsilon: E, max_relative: E) -> bool
fn relative_eq(&self, other: &Self, epsilon: E, max_relative: E) -> bool
A test for equality that uses a relative comparison if the values are far apart.
source§fn ulps_eq(&self, other: &Self, epsilon: E, max_ulps: u32) -> bool
fn ulps_eq(&self, other: &Self, epsilon: E, max_ulps: u32) -> bool
A test for equality that uses units in the last place (ULP) if the values are far apart.
source§impl<V: Clone + VectorSpace, R: Clone> Clone for Decomposed<V, R>where
V::Scalar: Clone,
impl<V: Clone + VectorSpace, R: Clone> Clone for Decomposed<V, R>where V::Scalar: Clone,
source§fn clone(&self) -> Decomposed<V, R>
fn clone(&self) -> Decomposed<V, R>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<V: Debug + VectorSpace, R: Debug> Debug for Decomposed<V, R>where
V::Scalar: Debug,
impl<V: Debug + VectorSpace, R: Debug> Debug for Decomposed<V, R>where V::Scalar: Debug,
source§impl<P: EuclideanSpace, R: Rotation<P>> Transform<P> for Decomposed<P::Diff, R>where
P::Scalar: BaseFloat,
P::Diff: VectorSpace,
impl<P: EuclideanSpace, R: Rotation<P>> Transform<P> for Decomposed<P::Diff, R>where P::Scalar: BaseFloat, P::Diff: VectorSpace,
source§fn one() -> Decomposed<P::Diff, R>
fn one() -> Decomposed<P::Diff, R>
Create an identity transformation. That is, a transformation which
does nothing.
source§fn look_at(eye: P, center: P, up: P::Diff) -> Decomposed<P::Diff, R>
fn look_at(eye: P, center: P, up: P::Diff) -> Decomposed<P::Diff, R>
Create a transformation that rotates a vector to look at
center
from
eye
, using up
for orientation.source§fn transform_vector(&self, vec: P::Diff) -> P::Diff
fn transform_vector(&self, vec: P::Diff) -> P::Diff
Transform a vector using this transform.
source§fn transform_point(&self, point: P) -> P
fn transform_point(&self, point: P) -> P
Transform a point using this transform.
source§fn concat(&self, other: &Decomposed<P::Diff, R>) -> Decomposed<P::Diff, R>
fn concat(&self, other: &Decomposed<P::Diff, R>) -> Decomposed<P::Diff, R>
Combine this transform with another, yielding a new transformation
which has the effects of both.
source§fn inverse_transform(&self) -> Option<Decomposed<P::Diff, R>>
fn inverse_transform(&self) -> Option<Decomposed<P::Diff, R>>
Create a transform that “un-does” this one.
source§fn concat_self(&mut self, other: &Self)
fn concat_self(&mut self, other: &Self)
Combine this transform with another, in-place.
impl<V: Copy + VectorSpace, R: Copy> Copy for Decomposed<V, R>where V::Scalar: Copy,
impl<S: BaseFloat, R: Rotation2<S>> Transform2<S> for Decomposed<Vector2<S>, R>
impl<S: BaseFloat, R: Rotation3<S>> Transform3<S> for Decomposed<Vector3<S>, R>
Auto Trait Implementations§
impl<V, R> RefUnwindSafe for Decomposed<V, R>where R: RefUnwindSafe, V: RefUnwindSafe, <V as VectorSpace>::Scalar: RefUnwindSafe,
impl<V, R> Send for Decomposed<V, R>where R: Send, V: Send, <V as VectorSpace>::Scalar: Send,
impl<V, R> Sync for Decomposed<V, R>where R: Sync, V: Sync, <V as VectorSpace>::Scalar: Sync,
impl<V, R> Unpin for Decomposed<V, R>where R: Unpin, V: Unpin, <V as VectorSpace>::Scalar: Unpin,
impl<V, R> UnwindSafe for Decomposed<V, R>where R: UnwindSafe, V: UnwindSafe, <V as VectorSpace>::Scalar: UnwindSafe,
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