Struct oxygengine_ha_renderer::math::mint::Quaternion
#[repr(C)]pub struct Quaternion<T> {
pub v: Vector3<T>,
pub s: T,
}
Expand description
Standard quaternion represented by the scalar and vector parts. Useful for representing rotation in 3D space. Corresponds to a right-handed rotation matrix.
Fields§
§v: Vector3<T>
Vector part of a quaternion.
s: T
Scalar part of a quaternion.
Trait Implementations§
§impl<T> AsMut<[T; 4]> for Quaternion<T>
impl<T> AsMut<[T; 4]> for Quaternion<T>
§impl<T> AsRef<[T; 4]> for Quaternion<T>
impl<T> AsRef<[T; 4]> for Quaternion<T>
§impl<T> Clone for Quaternion<T>where
T: Clone,
impl<T> Clone for Quaternion<T>where T: Clone,
§fn clone(&self) -> Quaternion<T>
fn clone(&self) -> Quaternion<T>
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 more§impl<T> Debug for Quaternion<T>where
T: Debug,
impl<T> Debug for Quaternion<T>where T: Debug,
§impl<T> From<[T; 4]> for Quaternion<T>
impl<T> From<[T; 4]> for Quaternion<T>
§fn from(_: [T; 4]) -> Quaternion<T>
fn from(_: [T; 4]) -> Quaternion<T>
Converts to this type from the input type.
§impl<T> From<Quaternion<T>> for [T; 4]
impl<T> From<Quaternion<T>> for [T; 4]
§fn from(quaternion: Quaternion<T>) -> [T; 4]
fn from(quaternion: Quaternion<T>) -> [T; 4]
Converts to this type from the input type.
source§impl<T> From<Quaternion<T>> for Quaternion<T>
impl<T> From<Quaternion<T>> for Quaternion<T>
source§fn from(q: Quaternion<T>) -> Quaternion<T>
fn from(q: Quaternion<T>) -> Quaternion<T>
Converts to this type from the input type.
source§impl<T> From<Quaternion<T>> for Quaternion<T>
impl<T> From<Quaternion<T>> for Quaternion<T>
source§fn from(q: Quaternion<T>) -> Quaternion<T>
fn from(q: Quaternion<T>) -> Quaternion<T>
Converts to this type from the input type.
§impl<T> Hash for Quaternion<T>where
T: Hash,
impl<T> Hash for Quaternion<T>where T: Hash,
source§impl<T> Into<Quaternion<T>> for Quaternion<T>
impl<T> Into<Quaternion<T>> for Quaternion<T>
source§fn into(self) -> Quaternion<T>
fn into(self) -> Quaternion<T>
Converts this type into the (usually inferred) input type.
source§impl<T> Into<Quaternion<T>> for Quaternion<T>
impl<T> Into<Quaternion<T>> for Quaternion<T>
source§fn into(self) -> Quaternion<T>
fn into(self) -> Quaternion<T>
Converts this type into the (usually inferred) input type.
§impl<T> IntoMint for Quaternion<T>
impl<T> IntoMint for Quaternion<T>
§type MintType = Quaternion<T>
type MintType = Quaternion<T>
The mint type that this type is associated with.
§impl<T> Ord for Quaternion<T>where
T: Ord,
impl<T> Ord for Quaternion<T>where T: Ord,
§impl<T> PartialEq<Quaternion<T>> for Quaternion<T>where
T: PartialEq<T>,
impl<T> PartialEq<Quaternion<T>> for Quaternion<T>where T: PartialEq<T>,
§fn eq(&self, other: &Quaternion<T>) -> bool
fn eq(&self, other: &Quaternion<T>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.§impl<T> PartialOrd<Quaternion<T>> for Quaternion<T>where
T: PartialOrd<T>,
impl<T> PartialOrd<Quaternion<T>> for Quaternion<T>where T: PartialOrd<T>,
§fn partial_cmp(&self, other: &Quaternion<T>) -> Option<Ordering>
fn partial_cmp(&self, other: &Quaternion<T>) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl<T> Copy for Quaternion<T>where T: Copy,
impl<T> Eq for Quaternion<T>where T: Eq,
impl<T> StructuralEq for Quaternion<T>
impl<T> StructuralPartialEq for Quaternion<T>
Auto Trait Implementations§
impl<T> RefUnwindSafe for Quaternion<T>where T: RefUnwindSafe,
impl<T> Send for Quaternion<T>where T: Send,
impl<T> Sync for Quaternion<T>where T: Sync,
impl<T> Unpin for Quaternion<T>where T: Unpin,
impl<T> UnwindSafe for Quaternion<T>where T: 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
§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more