#[repr(C)]pub struct Quat {
pub x: f32,
pub y: f32,
pub z: f32,
pub w: f32,
}
Fields§
§x: f32
§y: f32
§z: f32
§w: f32
Implementations§
Source§impl Quat
impl Quat
pub fn multiply(a: &Quat, b: &Quat) -> Quat
pub fn invert(&self) -> Quat
pub fn rotate_vec3(&self, v: &Vec3) -> Vec3
pub fn dot(&self, other: Quat) -> f32
pub fn neg(&self) -> Quat
pub fn get_angle_with(&self, other: Quat) -> f32
pub fn from_slerp(n: Quat, m: Quat, t: f32) -> Quat
pub fn length(self) -> f32
pub fn normalized(&mut self) -> Quat
pub fn look_rotation(forward: Vec3, up: Vec3) -> Quat
Trait Implementations§
impl Copy for Quat
impl StructuralPartialEq for Quat
Auto Trait Implementations§
impl Freeze for Quat
impl RefUnwindSafe for Quat
impl Send for Quat
impl Sync for Quat
impl Unpin for Quat
impl UnwindSafe for Quat
Blanket Implementations§
Source§impl<T> ActionTrait for T
impl<T> ActionTrait for T
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