pub struct Point3D {
pub x: f64,
pub y: f64,
pub z: f64,
}Expand description
A 3D point in double-precision (f64) world coordinates.
Fields§
§x: f64§y: f64§z: f64Implementations§
Source§impl Point3D
impl Point3D
pub const fn new(x: f64, y: f64, z: f64) -> Self
pub fn sub(self, other: Self) -> Self
pub fn add(self, other: Self) -> Self
pub fn scale(self, s: f64) -> Self
pub fn dot(self, other: Self) -> f64
pub fn cross(self, other: Self) -> Self
pub fn norm_sq(self) -> f64
pub fn norm(self) -> f64
pub fn normalized(self) -> Option<Self>
Trait Implementations§
impl Copy for Point3D
impl StructuralPartialEq for Point3D
Auto Trait Implementations§
impl Freeze for Point3D
impl RefUnwindSafe for Point3D
impl Send for Point3D
impl Sync for Point3D
impl Unpin for Point3D
impl UnsafeUnpin for Point3D
impl UnwindSafe for Point3D
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