Struct oxygen_quark::vector::vector3d::Vector3D
source · Fields
data: [Fraction; 3]
The x-coordinate of the vector
Trait Implementations
sourceimpl AddAssign<Vector3D> for Vector3D
impl AddAssign<Vector3D> for Vector3D
sourcefn add_assign(&mut self, other: Vector3D)
fn add_assign(&mut self, other: Vector3D)
Performs the
+=
operation. Read moresourceimpl Ord for Vector3D
impl Ord for Vector3D
1.21.0 · sourcefn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 · sourcefn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
1.50.0 · sourcefn clamp(self, min: Self, max: Self) -> Selfwhere
Self: Sized + PartialOrd<Self>,
fn clamp(self, min: Self, max: Self) -> Selfwhere
Self: Sized + PartialOrd<Self>,
Restrict a value to a certain interval. Read more
sourceimpl PartialOrd<Vector3D> for Vector3D
impl PartialOrd<Vector3D> for Vector3D
sourcefn partial_cmp(&self, other: &Vector3D) -> Option<Ordering>
fn partial_cmp(&self, other: &Vector3D) -> Option<Ordering>
1.0.0 · sourcefn 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 moresourceimpl RemAssign<Vector3D> for Vector3D
impl RemAssign<Vector3D> for Vector3D
sourcefn rem_assign(&mut self, other: Vector3D)
fn rem_assign(&mut self, other: Vector3D)
Performs the
%=
operation. Read moresourceimpl SubAssign<Vector3D> for Vector3D
impl SubAssign<Vector3D> for Vector3D
sourcefn sub_assign(&mut self, other: Vector3D)
fn sub_assign(&mut self, other: Vector3D)
Performs the
-=
operation. Read moresourceimpl TransformVector<Vector3D> for Matrix3x3
impl TransformVector<Vector3D> for Matrix3x3
sourcefn transform_vector(&self, other: Vector3D) -> Result<Vector3D, VectorError>
fn transform_vector(&self, other: Vector3D) -> Result<Vector3D, VectorError>
Transforms a Vector3D
with the Matrix3x3
and returns the result, a Option<Vector3D>
.
sourceimpl TransformVector<Vector3D> for Matrix4x4
impl TransformVector<Vector3D> for Matrix4x4
sourcefn transform_vector(&self, other: Vector3D) -> Result<Vector3D, VectorError>
fn transform_vector(&self, other: Vector3D) -> Result<Vector3D, VectorError>
Transforms a Vector3D
with the Matrix4x4
and returns the result, an Option<Vector3D>
.
sourceimpl Vector for Vector3D
impl Vector for Vector3D
type Data = Fraction
fn from(values: &[Self::Data]) -> Self
fn component_product(self, other: Self) -> Self
fn dot_product(self, other: Self) -> Self::Data
fn cross_product(self, other: Self) -> Result<Self, VectorError>
fn scale(&self, scale: Self::Data) -> Self
fn norm(self) -> Self::Data
fn normalise(self) -> Self
impl Copy for Vector3D
impl Eq for Vector3D
Auto Trait Implementations
impl RefUnwindSafe for Vector3D
impl Send for Vector3D
impl Sync for Vector3D
impl Unpin for Vector3D
impl UnwindSafe for Vector3D
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more