[−][src]Struct euclid::TypedRigidTransform3D
A rigid transformation. All lengths are preserved under such a transformation.
Internally, this is a rotation and a translation, with the rotation
applied first (i.e. Rotation * Translation
, in row-vector notation)
This can be more efficient to use over full matrices, especially if you have to deal with the decomposed quantities often.
Fields
rotation: TypedRotation3D<T, Src, Dst>
translation: TypedVector3D<T, Dst>
Methods
impl<T: Float + ApproxEq<T>, Src, Dst> TypedRigidTransform3D<T, Src, Dst>
[src]
pub fn new(
rotation: TypedRotation3D<T, Src, Dst>,
translation: TypedVector3D<T, Dst>
) -> Self
[src]
rotation: TypedRotation3D<T, Src, Dst>,
translation: TypedVector3D<T, Dst>
) -> Self
Construct a new rigid transformation, where the rotation
applies first
pub fn identity() -> Self
[src]
Construct an identity transform
pub fn new_from_reversed(
translation: TypedVector3D<T, Src>,
rotation: TypedRotation3D<T, Src, Dst>
) -> Self
[src]
translation: TypedVector3D<T, Src>,
rotation: TypedRotation3D<T, Src, Dst>
) -> Self
Construct a new rigid transformation, where the translation
applies first
pub fn from_rotation(rotation: TypedRotation3D<T, Src, Dst>) -> Self
[src]
pub fn from_translation(translation: TypedVector3D<T, Dst>) -> Self
[src]
pub fn decompose_reversed(
&self
) -> (TypedVector3D<T, Src>, TypedRotation3D<T, Src, Dst>)
[src]
&self
) -> (TypedVector3D<T, Src>, TypedRotation3D<T, Src, Dst>)
Decompose this into a translation and an rotation to be applied in the opposite order
i.e., the translation is applied first
pub fn post_mul<Dst2>(
&self,
other: &TypedRigidTransform3D<T, Dst, Dst2>
) -> TypedRigidTransform3D<T, Src, Dst2>
[src]
&self,
other: &TypedRigidTransform3D<T, Dst, Dst2>
) -> TypedRigidTransform3D<T, Src, Dst2>
Returns the multiplication of the two transforms such that other's transformation applies after self's transformation.
i.e., this produces self * other
in row-vector notation
pub fn pre_mul<Src2>(
&self,
other: &TypedRigidTransform3D<T, Src2, Src>
) -> TypedRigidTransform3D<T, Src2, Dst>
[src]
&self,
other: &TypedRigidTransform3D<T, Src2, Src>
) -> TypedRigidTransform3D<T, Src2, Dst>
Returns the multiplication of the two transforms such that self's transformation applies after other's transformation.
i.e., this produces other * self
in row-vector notation
pub fn inverse(&self) -> TypedRigidTransform3D<T, Dst, Src>
[src]
Inverts the transformation
pub fn to_transform(&self) -> TypedTransform3D<T, Src, Dst> where
T: Trig,
[src]
T: Trig,
Trait Implementations
impl<T: PartialEq, Src: PartialEq, Dst: PartialEq> PartialEq<TypedRigidTransform3D<T, Src, Dst>> for TypedRigidTransform3D<T, Src, Dst>
[src]
fn eq(&self, other: &TypedRigidTransform3D<T, Src, Dst>) -> bool
[src]
fn ne(&self, other: &TypedRigidTransform3D<T, Src, Dst>) -> bool
[src]
impl<T: Eq, Src: Eq, Dst: Eq> Eq for TypedRigidTransform3D<T, Src, Dst>
[src]
impl<T: Hash, Src: Hash, Dst: Hash> Hash for TypedRigidTransform3D<T, Src, Dst>
[src]
fn hash<__HTSrcDst: Hasher>(&self, state: &mut __HTSrcDst)
[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl<T: Debug, Src: Debug, Dst: Debug> Debug for TypedRigidTransform3D<T, Src, Dst>
[src]
impl<T: Copy, Src: Copy, Dst: Copy> Copy for TypedRigidTransform3D<T, Src, Dst>
[src]
impl<T: Float + ApproxEq<T>, Src, Dst> From<TypedRotation3D<T, Src, Dst>> for TypedRigidTransform3D<T, Src, Dst>
[src]
fn from(rot: TypedRotation3D<T, Src, Dst>) -> Self
[src]
impl<T: Float + ApproxEq<T>, Src, Dst> From<TypedVector3D<T, Dst>> for TypedRigidTransform3D<T, Src, Dst>
[src]
fn from(t: TypedVector3D<T, Dst>) -> Self
[src]
impl<T: Clone, Src: Clone, Dst: Clone> Clone for TypedRigidTransform3D<T, Src, Dst>
[src]
fn clone(&self) -> TypedRigidTransform3D<T, Src, Dst>
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
Auto Trait Implementations
impl<T, Src, Dst> Unpin for TypedRigidTransform3D<T, Src, Dst> where
Dst: Unpin,
Src: Unpin,
T: Unpin,
Dst: Unpin,
Src: Unpin,
T: Unpin,
impl<T, Src, Dst> Send for TypedRigidTransform3D<T, Src, Dst> where
Dst: Send,
Src: Send,
T: Send,
Dst: Send,
Src: Send,
T: Send,
impl<T, Src, Dst> Sync for TypedRigidTransform3D<T, Src, Dst> where
Dst: Sync,
Src: Sync,
T: Sync,
Dst: Sync,
Src: Sync,
T: Sync,
impl<T, Src, Dst> UnwindSafe for TypedRigidTransform3D<T, Src, Dst> where
Dst: UnwindSafe,
Src: UnwindSafe,
T: UnwindSafe,
Dst: UnwindSafe,
Src: UnwindSafe,
T: UnwindSafe,
impl<T, Src, Dst> RefUnwindSafe for TypedRigidTransform3D<T, Src, Dst> where
Dst: RefUnwindSafe,
Src: RefUnwindSafe,
T: RefUnwindSafe,
Dst: RefUnwindSafe,
Src: RefUnwindSafe,
T: RefUnwindSafe,
Blanket Implementations
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,