pub struct Mat4f { /* private fields */ }
Implementations§
Source§impl Mat4f
impl Mat4f
pub fn col(&self, index: usize) -> Vec4f
pub fn row(&self, index: usize) -> Vec4f
pub fn is_nan(&self) -> bool
pub fn is_infinite(&self) -> bool
pub fn is_finite(&self) -> bool
pub fn transpose(&self) -> Self
pub fn determinant(&self) -> f32
pub fn inverse(&self) -> Self
pub fn try_inverse(&self) -> Option<Self>
Source§impl Mat4f
impl Mat4f
pub fn from_array(m: [f32; 16]) -> Self
pub fn from_array_2d(m: [[f32; 4]; 4]) -> Self
pub fn from_diagonal(diagonal: Vec4f) -> Self
Source§impl Mat4f
impl Mat4f
pub fn translation(translate: Vec3f) -> Self
pub fn rotation_x(angle: f32) -> Self
pub fn rotation_y(angle: f32) -> Self
pub fn rotation_z(angle: f32) -> Self
pub fn rotation_axis(axis: Vec3f, angle: f32) -> Self
pub fn scale(scale: Vec3f) -> Self
pub fn look_at(eye: Vec3f, target: Vec3f, up: Vec3f) -> Self
pub fn perspective(fovy: f32, aspect: f32, z_near: f32, z_far: f32) -> Self
Trait Implementations§
Source§impl AddAssign<f32> for Mat4f
impl AddAssign<f32> for Mat4f
Source§fn add_assign(&mut self, rhs: f32)
fn add_assign(&mut self, rhs: f32)
Performs the
+=
operation. Read moreSource§impl AddAssign for Mat4f
impl AddAssign for Mat4f
Source§fn add_assign(&mut self, rhs: Mat4f)
fn add_assign(&mut self, rhs: Mat4f)
Performs the
+=
operation. Read moreSource§impl DivAssign<f32> for Mat4f
impl DivAssign<f32> for Mat4f
Source§fn div_assign(&mut self, rhs: f32)
fn div_assign(&mut self, rhs: f32)
Performs the
/=
operation. Read moreSource§impl MulAssign<f32> for Mat4f
impl MulAssign<f32> for Mat4f
Source§fn mul_assign(&mut self, rhs: f32)
fn mul_assign(&mut self, rhs: f32)
Performs the
*=
operation. Read moreSource§impl MulAssign for Mat4f
impl MulAssign for Mat4f
Source§fn mul_assign(&mut self, rhs: Mat4f)
fn mul_assign(&mut self, rhs: Mat4f)
Performs the
*=
operation. Read moreSource§impl SubAssign<f32> for Mat4f
impl SubAssign<f32> for Mat4f
Source§fn sub_assign(&mut self, rhs: f32)
fn sub_assign(&mut self, rhs: f32)
Performs the
-=
operation. Read moreSource§impl SubAssign for Mat4f
impl SubAssign for Mat4f
Source§fn sub_assign(&mut self, rhs: Mat4f)
fn sub_assign(&mut self, rhs: Mat4f)
Performs the
-=
operation. Read moreimpl Copy for Mat4f
impl StructuralPartialEq for Mat4f
Auto Trait Implementations§
impl Freeze for Mat4f
impl RefUnwindSafe for Mat4f
impl Send for Mat4f
impl Sync for Mat4f
impl Unpin for Mat4f
impl UnwindSafe for Mat4f
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