Struct siege_math::quat::NQuat
[−]
[src]
pub struct NQuat<F> { /* fields omitted */ }
Normalized unit quaternion
Methods
impl<F: FullFloat> NQuat<F>
[src]
pub fn new_isnormal(v: Vec3<F>, w: F) -> NQuat<F>
[src]
impl<F: FullFloat> NQuat<F>
[src]
impl<F: FullFloat> NQuat<F>
[src]
pub fn from_axis_angle(axis: &Direction3<F>, angle: &Angle<F>) -> NQuat<F>
[src]
Create an NQuat from an axis and angle
impl<F: FullFloat> NQuat<F>
[src]
pub fn as_axis_angle(&self) -> (Direction3<F>, Angle<F>)
[src]
Determine the axis/angle representation of an NQuat
impl<F: FullFloat> NQuat<F>
[src]
pub fn from_directions(
start: Direction3<F>,
end: Direction3<F>
) -> Option<NQuat<F>>
[src]
start: Direction3<F>,
end: Direction3<F>
) -> Option<NQuat<F>>
impl<F: FullFloat> NQuat<F>
[src]
impl<F: FullFloat> NQuat<F>
[src]
impl<F: FullFloat> NQuat<F>
[src]
pub fn rotate(&self, v: Vec3<F>) -> Vec3<F>
[src]
This applies the NQuat as an operator to the vector v, yielding the rotated vector.
Trait Implementations
impl<F: Debug> Debug for NQuat<F>
[src]
fn fmt(&self, __arg_0: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more
impl<F: Clone> Clone for NQuat<F>
[src]
fn clone(&self) -> NQuat<F>
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl<F: Copy> Copy for NQuat<F>
[src]
impl<F: PartialEq> PartialEq for NQuat<F>
[src]
fn eq(&self, __arg_0: &NQuat<F>) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &NQuat<F>) -> bool
[src]
This method tests for !=
.
impl<F: Eq> Eq for NQuat<F>
[src]
impl<F: Hash> Hash for NQuat<F>
[src]
fn hash<__HF: Hasher>(&self, __arg_0: &mut __HF)
[src]
Feeds this value into the given [Hasher
]. Read more
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<F: FullFloat> Default for NQuat<F>
[src]
impl From<NQuat<f32>> for NQuat<f64>
[src]
impl From<NQuat<f64>> for NQuat<f32>
[src]
impl<F: FullFloat> From<Quat<F>> for NQuat<F>
[src]
impl<F: FullFloat> From<NQuat<F>> for Quat<F>
[src]
impl<F: FullFloat> Mul for NQuat<F>
[src]
type Output = NQuat<F>
The resulting type after applying the *
operator.
fn mul(self, rhs: NQuat<F>) -> NQuat<F>
[src]
Performs the *
operation.
impl<F: FullFloat> Mul<Vec3<F>> for NQuat<F>
[src]
type Output = Vec3<F>
The resulting type after applying the *
operator.
fn mul(self, rhs: Vec3<F>) -> Vec3<F>
[src]
Performs the *
operation.
impl<F: FullFloat> From<NQuat<F>> for Mat3<F>
[src]
impl<F: FullFloat> From<Mat3<F>> for NQuat<F>
[src]
impl<F: FullFloat> ApproxEq for NQuat<F>
[src]
type Flt = F
fn approx_eq(
&self,
other: &Self,
epsilon: <F as ApproxEq>::Flt,
ulps: <<F as ApproxEq>::Flt as Ulps>::U
) -> bool
[src]
&self,
other: &Self,
epsilon: <F as ApproxEq>::Flt,
ulps: <<F as ApproxEq>::Flt as Ulps>::U
) -> bool
This method tests for self
and other
values to be approximately equal using two methods: epsilon and ulps. If the values differ by less than the given epsilon, they will be considered equal. If the values differ by more than epsilon, but by less than the given ulps, they will also be considered equal. Otherwise they are unequal. Read more
fn approx_ne(
&self,
other: &Self,
epsilon: Self::Flt,
ulps: <Self::Flt as Ulps>::U
) -> bool
[src]
&self,
other: &Self,
epsilon: Self::Flt,
ulps: <Self::Flt as Ulps>::U
) -> bool
This method tests for self
and other
values to be not approximately equal using two methods: epsilon and ulps. If the values differ by less than the given epsilon, they will be considered equal. If the values differ by more than epsilon, but by less than the given ulps, they will also be considered equal. Otherwise they are unequal. Read more