#[repr(C)]pub struct M44 { /* private fields */ }
Implementations§
Source§impl M44
impl M44
pub const fn new_identity() -> Self
pub fn concat(a: &Self, b: &Self) -> Self
pub const fn nan() -> Self
pub const fn new( m0: scalar, m4: scalar, m8: scalar, m12: scalar, m1: scalar, m5: scalar, m9: scalar, m13: scalar, m2: scalar, m6: scalar, m10: scalar, m14: scalar, m3: scalar, m7: scalar, m11: scalar, m15: scalar, ) -> Self
pub fn rows(r0: &V4, r1: &V4, r2: &V4, r3: &V4) -> Self
pub fn cols(c0: &V4, c1: &V4, c2: &V4, c3: &V4) -> Self
pub fn row_major(r: &[scalar; 16]) -> Self
pub fn col_major(c: &[scalar; 16]) -> Self
pub fn translate(x: scalar, y: scalar, z: scalar) -> Self
pub fn scale(x: scalar, y: scalar, z: scalar) -> Self
pub fn rotate(axis: V3, radians: scalar) -> Self
pub fn rect_to_rect(src: impl AsRef<Rect>, dst: impl AsRef<Rect>) -> Self
pub fn look_at(eye: &V3, center: &V3, up: &V3) -> Self
pub fn perspective(near: f32, far: f32, angle: f32) -> Self
pub fn get_col_major(&self, v: &mut [scalar; 16])
pub fn get_row_major(&self, v: &mut [scalar; 16])
pub fn set_col_major(&mut self, v: &[scalar; 16]) -> &mut Self
👎Deprecated since 0.30.0: use M44::col_major() instead
pub fn set_row_major(&mut self, v: &[scalar; 16]) -> &mut Self
👎Deprecated since 0.30.0: use M44::row_major() instead
pub fn set_44( &mut self, m0: scalar, m1: scalar, m2: scalar, m3: scalar, m4: scalar, m5: scalar, m6: scalar, m7: scalar, m8: scalar, m9: scalar, m10: scalar, m11: scalar, m12: scalar, m13: scalar, m14: scalar, m15: scalar, ) -> &mut Self
👎Deprecated since 0.30.0: use Self::new() instead
pub fn rc(&self, r: usize, c: usize) -> scalar
pub fn set_rc(&mut self, r: usize, c: usize, value: scalar)
pub fn row(&self, i: usize) -> V4
pub fn col(&self, i: usize) -> V4
pub fn set_row(&mut self, i: usize, v: &V4)
pub fn set_col(&mut self, i: usize, v: &V4)
pub fn set_identity(&mut self) -> &mut Self
pub fn set_translate(&mut self, x: scalar, y: scalar, z: scalar) -> &mut Self
pub fn set_scale(&mut self, x: scalar, y: scalar, z: scalar) -> &mut Self
pub fn set_rotate_unit_sin_cos( &mut self, axis: V3, sin_angle: scalar, cos_angle: scalar, ) -> &mut Self
pub fn set_rotate_unit(&mut self, axis: V3, radians: scalar) -> &mut Self
pub fn set_rotate(&mut self, axis: V3, radians: scalar) -> &mut Self
pub fn set_concat_16(&mut self, a: &M44, col_major: &[scalar; 16]) -> &mut Self
👎Deprecated since 0.30.0: use M44::col_major() and M44::set_concat()
pub fn set_concat(&mut self, a: &M44, b: &M44) -> &mut Self
pub fn pre_concat_16(&mut self, col_major: &[scalar; 16]) -> &mut Self
👎Deprecated since 0.30.0: use M44::col_major() and M44::pre_concat()
pub fn pre_concat(&mut self, m: &M44) -> &mut Self
pub fn post_concat(&mut self, m: &M44) -> &mut Self
pub fn normalize_perspective(&mut self)
pub fn is_finite(&self) -> bool
pub fn invert(&self) -> Option<M44>
pub fn transpose(&self) -> Self
pub fn dump(&self)
pub fn map(&self, x: f32, y: f32, z: f32, w: f32) -> V4
pub fn to_m33(&self) -> Matrix
pub fn pre_translate( &mut self, x: scalar, y: scalar, z: impl Into<Option<scalar>>, ) -> &mut Self
pub fn post_translate( &mut self, x: scalar, y: scalar, z: impl Into<Option<scalar>>, ) -> &mut Self
pub fn pre_scale(&mut self, x: scalar, y: scalar) -> &mut Self
pub fn pre_scale_xyz(&mut self, x: scalar, y: scalar, z: scalar) -> &mut Self
Trait Implementations§
Auto Trait Implementations§
impl Freeze for M44
impl RefUnwindSafe for M44
impl Send for M44
impl Sync for M44
impl Unpin for M44
impl UnwindSafe for M44
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