Skip to main content

RotationOps

Trait RotationOps 

Source
pub trait RotationOps<N: ScalarType>:
    Copy
    + Debug
    + Mul<N::Rotation, Output = N::Rotation>
    + Mul<N::Vector, Output = N::Vector> {
    // Required methods
    fn to_mat(self) -> N::Matrix;
    fn inverse(self) -> Self;
    fn diff_conj1_2(&self, rhs: &Self) -> N::Matrix;
    fn diff_conj1_2_tr(&self, rhs: &Self) -> N::Matrix;
    fn dot(&self, rhs: &Self) -> N;
    fn imag(&self) -> N::Vector;
    fn mul_assign_unchecked(&mut self, rhs: N);
}
Expand description

Trait implemented by quaternions.

Required Methods§

Source

fn to_mat(self) -> N::Matrix

Converts this rotation to a rotation matrix.

Source

fn inverse(self) -> Self

Returns the inverse of this rotation.

Source

fn diff_conj1_2(&self, rhs: &Self) -> N::Matrix

Compute the differential of inv(q1) * q2.

Source

fn diff_conj1_2_tr(&self, rhs: &Self) -> N::Matrix

Compute the transposed differential of inv(q1) * q2.

Source

fn dot(&self, rhs: &Self) -> N

Compute the dot product of two quaternions.

Source

fn imag(&self) -> N::Vector

The imaginary part of the quaternion.

Source

fn mul_assign_unchecked(&mut self, rhs: N)

Multiply this quaternion by a scalar without renormalizing.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl RotationOps<f32> for Rotation

Available on crate feature dim3 only.