pub type Vec4 = [f32; 4];
Trait Implementations§
Source§impl MulVectorMatrix<[f32; 16]> for Vec4
impl MulVectorMatrix<[f32; 16]> for Vec4
type VectorType = [f32; 4]
Source§fn mul_matrix_left(&self, lhs: &Mat4) -> Self::VectorType
fn mul_matrix_left(&self, lhs: &Mat4) -> Self::VectorType
Interprets
self
as a column vector and multiplies the given matrix
from the left-hand-side, i.e. lhs * self
Source§fn mul_matrix(&self, rhs: &Mat4) -> Self::VectorType
fn mul_matrix(&self, rhs: &Mat4) -> Self::VectorType
Interprets
self
as a row vector and multiplies the given matrix
from the right-hand-side, i.e. self * rhs
Source§impl Vector for Vec4
impl Vector for Vec4
type VectorType = [f32; 4]
Source§fn mul(&self, rhs: &[f32]) -> Vec4
fn mul(&self, rhs: &[f32]) -> Vec4
Perform element-wise multiplication with the given right-hand-side operand
Source§fn add(&self, rhs: &[f32]) -> Vec4
fn add(&self, rhs: &[f32]) -> Vec4
Perform element-wise addition with the given right-hand-side operand