pub struct Sphere3 {
pub center: Vec3,
pub radius: f64,
}Expand description
3-D sphere.
Fields§
§center: Vec3Centre.
radius: f64Radius (non-negative).
Implementations§
Source§impl Sphere3
impl Sphere3
Sourcepub fn intersects_aabb(&self, aabb: &Aabb3) -> bool
pub fn intersects_aabb(&self, aabb: &Aabb3) -> bool
Does this sphere overlap the AABB?
Sourcepub fn intersects_triangle(&self, tri: &Triangle3) -> bool
pub fn intersects_triangle(&self, tri: &Triangle3) -> bool
Does this sphere overlap the triangle?
Sourcepub fn intersects(&self, other: &Sphere3) -> bool
pub fn intersects(&self, other: &Sphere3) -> bool
Does this sphere overlap other?
Trait Implementations§
impl Copy for Sphere3
impl StructuralPartialEq for Sphere3
Auto Trait Implementations§
impl Freeze for Sphere3
impl RefUnwindSafe for Sphere3
impl Send for Sphere3
impl Sync for Sphere3
impl Unpin for Sphere3
impl UnsafeUnpin for Sphere3
impl UnwindSafe for Sphere3
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