pub struct Aabb3 {
pub min: Vec3,
pub max: Vec3,
}Expand description
Axis-aligned 3D box.
Fields§
§min: Vec3Minimum corner.
max: Vec3Maximum corner.
Implementations§
Source§impl Aabb3
impl Aabb3
Sourcepub fn from_center(center: Vec3, size: Vec3) -> Self
pub fn from_center(center: Vec3, size: Vec3) -> Self
Constructs a box from its center and nonnegative full dimensions. Panics for negative or nonfinite sizes/centers.
Sourcepub fn intersects(&self, other: &Self) -> bool
pub fn intersects(&self, other: &Self) -> bool
Whether boxes overlap with positive volume. Touching is not overlap.
Trait Implementations§
impl Copy for Aabb3
impl StructuralPartialEq for Aabb3
Auto Trait Implementations§
impl Freeze for Aabb3
impl RefUnwindSafe for Aabb3
impl Send for Aabb3
impl Sync for Aabb3
impl Unpin for Aabb3
impl UnsafeUnpin for Aabb3
impl UnwindSafe for Aabb3
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