Struct geometric::Matrix3
[−]
[src]
pub struct Matrix3<T: Copy> { pub components: [[T; 3]; 3], }
Fields
components: [[T; 3]; 3]
Methods
impl<T: Copy> Matrix3<T>
[src]
fn new(components: [[T; 3]; 3]) -> Self
fn id() -> Self where
T: Zero + One,
T: Zero + One,
Create an identity matrix.
fn new_scale(scale: Vector3<T>) -> Self where
T: Zero + One,
T: Zero + One,
Create a matrix representing a scaling transform.
fn new_translation(translation: Vector2<T>) -> Self where
T: Zero + One,
T: Zero + One,
Create a matrix representing a translation.
fn scale(self, scale: Vector3<T>) -> Self where
T: Zero + One,
Self: Mul<Output = Self>,
T: Zero + One,
Self: Mul<Output = Self>,
Prepend a scale to this transform.
fn translate(self, translation: Vector2<T>) -> Self where
T: Zero + One,
Self: Mul<Output = Self>,
T: Zero + One,
Self: Mul<Output = Self>,
Prepend a translation to this transform.
fn inv(self) -> Self where
T: One + Add<Output = T> + Sub<Output = T> + Mul<Output = T> + Div<Output = T>,
T: One + Add<Output = T> + Sub<Output = T> + Mul<Output = T> + Div<Output = T>,
Return the inverse of this matrix.
fn det(self) -> T where
T: Add<Output = T> + Sub<Output = T> + Mul<Output = T>,
T: Add<Output = T> + Sub<Output = T> + Mul<Output = T>,
Return the determinant of this matrix.
fn transpose(self) -> Self
Return the transpose of this matrix.
Trait Implementations
impl<T: Clone + Copy> Clone for Matrix3<T>
[src]
fn clone(&self) -> Matrix3<T>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl<T: Copy + Copy> Copy for Matrix3<T>
[src]
impl<T: Default + Copy> Default for Matrix3<T>
[src]
impl<T: Debug + Copy> Debug for Matrix3<T>
[src]
impl<T: PartialEq + Copy> PartialEq for Matrix3<T>
[src]
fn eq(&self, __arg_0: &Matrix3<T>) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Matrix3<T>) -> bool
This method tests for !=
.
impl<T: Eq + Copy> Eq for Matrix3<T>
[src]
impl<T: Copy> From<[[T; 3]; 3]> for Matrix3<T>
[src]
impl<T: Copy> Mul for Matrix3<T> where
T: Mul<Output = T> + Add<Output = T>,
[src]
T: Mul<Output = T> + Add<Output = T>,
type Output = Self
The resulting type after applying the *
operator
fn mul(self, other: Self) -> Self::Output
The method for the *
operator
impl<T: Copy> Mul<Vector3<T>> for Matrix3<T> where
T: Mul<Output = T> + Add<Output = T>,
[src]
T: Mul<Output = T> + Add<Output = T>,
type Output = Vector3<T>
The resulting type after applying the *
operator
fn mul(self, vector: Vector3<T>) -> Self::Output
The method for the *
operator
impl<T: Copy> MulAssign for Matrix3<T> where
T: Mul<Output = T> + Add<Output = T>,
[src]
T: Mul<Output = T> + Add<Output = T>,
fn mul_assign(&mut self, other: Self)
The method for the *=
operator