pub struct Vec2f { /* private fields */ }
Implementations§
Source§impl Vec2f
impl Vec2f
pub fn floor(self) -> Self
pub fn ceil(self) -> Self
pub fn round(self) -> Self
pub fn trunc(self) -> Self
pub fn fract(self) -> Self
pub fn abs(self) -> Self
pub fn signum(self) -> Self
pub fn powf(self, n: f32) -> Self
pub fn sqrt(self) -> Self
pub fn exp(self) -> Self
pub fn exp2(self) -> Self
pub fn ln(self) -> Self
pub fn log(self, base: f32) -> Self
pub fn log2(self) -> Self
pub fn log10(self) -> Self
pub fn cbrt(self) -> Self
pub fn sin(self) -> Self
pub fn cos(self) -> Self
pub fn tan(self) -> Self
pub fn sin_cos(self) -> (Self, Self)
pub fn lerp(self, rhs: Self, s: f32) -> Self
pub fn lerp_vec(self, rhs: Self, s: Self) -> Self
pub fn is_nan(self) -> bool
pub fn is_infinite(self) -> bool
pub fn is_finite(self) -> bool
pub fn recip(self) -> Self
pub fn max(self, rhs: Self) -> Self
pub fn min(self, rhs: Self) -> Self
pub fn clamp(self, min: Self, max: Self) -> Self
pub fn saturate(self) -> Self
pub fn min_element(self) -> f32
pub fn max_element(self) -> f32
Source§impl Vec2f
impl Vec2f
pub fn dot(self, rhs: Self) -> f32
pub fn cross(self, rhs: Self) -> f32
pub fn length(self) -> f32
pub fn length_squared(self) -> f32
pub fn length_recip(self) -> f32
pub fn distance(self, rhs: Self) -> f32
pub fn distance_squared(self, rhs: Self) -> f32
pub fn normalize(self) -> Self
pub fn try_normalize(self) -> Option<Self>
pub fn normalize_or_zero(self) -> Self
pub fn is_normalized(self) -> bool
pub fn angle_between(self, rhs: Self) -> f32
Source§impl Vec2f
impl Vec2f
pub fn x(self) -> f32
pub fn y(self) -> f32
pub fn xx(self) -> Self
pub fn xy(self) -> Self
pub fn yx(self) -> Self
pub fn yy(self) -> Self
pub fn xxx(self) -> Vec3f
pub fn xxy(self) -> Vec3f
pub fn xyx(self) -> Vec3f
pub fn xyy(self) -> Vec3f
pub fn yxx(self) -> Vec3f
pub fn yxy(self) -> Vec3f
pub fn yyx(self) -> Vec3f
pub fn yyy(self) -> Vec3f
pub fn xxxx(self) -> Vec4f
pub fn xxxy(self) -> Vec4f
pub fn xxyx(self) -> Vec4f
pub fn xxyy(self) -> Vec4f
pub fn yxxx(self) -> Vec4f
pub fn yxxy(self) -> Vec4f
pub fn yxyx(self) -> Vec4f
pub fn yxyy(self) -> Vec4f
Trait Implementations§
Source§impl AddAssign<f32> for Vec2f
impl AddAssign<f32> for Vec2f
Source§fn add_assign(&mut self, rhs: f32)
fn add_assign(&mut self, rhs: f32)
Performs the
+=
operation. Read moreSource§impl AddAssign for Vec2f
impl AddAssign for Vec2f
Source§fn add_assign(&mut self, rhs: Vec2f)
fn add_assign(&mut self, rhs: Vec2f)
Performs the
+=
operation. Read moreSource§impl DivAssign<f32> for Vec2f
impl DivAssign<f32> for Vec2f
Source§fn div_assign(&mut self, rhs: f32)
fn div_assign(&mut self, rhs: f32)
Performs the
/=
operation. Read moreSource§impl DivAssign for Vec2f
impl DivAssign for Vec2f
Source§fn div_assign(&mut self, rhs: Vec2f)
fn div_assign(&mut self, rhs: Vec2f)
Performs the
/=
operation. Read moreSource§impl MulAssign<f32> for Vec2f
impl MulAssign<f32> for Vec2f
Source§fn mul_assign(&mut self, rhs: f32)
fn mul_assign(&mut self, rhs: f32)
Performs the
*=
operation. Read moreSource§impl MulAssign for Vec2f
impl MulAssign for Vec2f
Source§fn mul_assign(&mut self, rhs: Vec2f)
fn mul_assign(&mut self, rhs: Vec2f)
Performs the
*=
operation. Read moreSource§impl SubAssign<f32> for Vec2f
impl SubAssign<f32> for Vec2f
Source§fn sub_assign(&mut self, rhs: f32)
fn sub_assign(&mut self, rhs: f32)
Performs the
-=
operation. Read moreSource§impl SubAssign for Vec2f
impl SubAssign for Vec2f
Source§fn sub_assign(&mut self, rhs: Vec2f)
fn sub_assign(&mut self, rhs: Vec2f)
Performs the
-=
operation. Read moreimpl Copy for Vec2f
impl StructuralPartialEq for Vec2f
Auto Trait Implementations§
impl Freeze for Vec2f
impl RefUnwindSafe for Vec2f
impl Send for Vec2f
impl Sync for Vec2f
impl Unpin for Vec2f
impl UnwindSafe for Vec2f
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