[−][src]Struct tessellation::BoundingBox
3D Bounding Box - defined by two diagonally opposing points.
Fields
min: Point<S, U3>
X-Y-Z-Minimum corner of the box.
max: Point<S, U3>
X-Y-Z-Maximum corner of the box.
Implementations
impl<S> BoundingBox<S> where
S: RealField + Float,
[src]
S: RealField + Float,
pub fn infinity() -> BoundingBox<S>
[src]
Returns an infinte sized box.
pub fn neg_infinity() -> BoundingBox<S>
[src]
Returns a negatively infinte sized box.
pub fn new(a: &Point<S, U3>, b: &Point<S, U3>) -> BoundingBox<S>
[src]
Create a new Bounding Box by supplying two points.
pub fn union(&self, other: &BoundingBox<S>) -> BoundingBox<S>
[src]
Create a CSG Union of two Bounding Boxes.
pub fn intersection(&self, other: &BoundingBox<S>) -> BoundingBox<S>
[src]
Create a CSG Intersection of two Bounding Boxes.
pub fn transform<M>(&self, mat: &M) -> BoundingBox<S> where
M: Transformation<Point<S, U3>>,
[src]
M: Transformation<Point<S, U3>>,
Transform a Bounding Box - resulting in a enclosing axis aligned Bounding Box.
pub fn dilate(&mut self, d: S) -> &mut BoundingBox<S>
[src]
Dilate a Bounding Box by some amount in all directions.
pub fn insert(&mut self, o: &Point<S, U3>) -> &mut BoundingBox<S>
[src]
Add a Point to a Bounding Box, e.g. expand the Bounding Box to contain that point.
pub fn dim(
&self
) -> Matrix<S, U3, U1, <DefaultAllocator as Allocator<S, U3, U1>>::Buffer>
[src]
&self
) -> Matrix<S, U3, U1, <DefaultAllocator as Allocator<S, U3, U1>>::Buffer>
Return the size of the Box.
pub fn distance(&self, p: &Point<S, U3>) -> S
[src]
Returns the approximate distance of p to the box. The result is guarateed to be not less than the euclidean distance of p to the box.
pub fn contains(&self, p: &Point<S, U3>) -> bool
[src]
Return true if the Bounding Box contains p.
Trait Implementations
impl<T> AbsDiffEq<BoundingBox<T>> for BoundingBox<T> where
T: RealField + Float + AbsDiffEq<T>,
<T as AbsDiffEq<T>>::Epsilon: Copy,
[src]
T: RealField + Float + AbsDiffEq<T>,
<T as AbsDiffEq<T>>::Epsilon: Copy,
type Epsilon = <T as AbsDiffEq<T>>::Epsilon
Used for specifying relative comparisons.
fn default_epsilon() -> <BoundingBox<T> as AbsDiffEq<BoundingBox<T>>>::Epsilon
[src]
fn abs_diff_eq(
&self,
other: &BoundingBox<T>,
epsilon: <BoundingBox<T> as AbsDiffEq<BoundingBox<T>>>::Epsilon
) -> bool
[src]
&self,
other: &BoundingBox<T>,
epsilon: <BoundingBox<T> as AbsDiffEq<BoundingBox<T>>>::Epsilon
) -> bool
fn abs_diff_ne(&self, other: &Rhs, epsilon: Self::Epsilon) -> bool
[src]
impl<S> Clone for BoundingBox<S> where
S: Clone + Debug + RealField,
[src]
S: Clone + Debug + RealField,
fn clone(&self) -> BoundingBox<S>
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl<S> Debug for BoundingBox<S> where
S: Debug + RealField,
[src]
S: Debug + RealField,
impl<S> PartialEq<BoundingBox<S>> for BoundingBox<S> where
S: PartialEq<S> + Debug + RealField,
[src]
S: PartialEq<S> + Debug + RealField,
fn eq(&self, other: &BoundingBox<S>) -> bool
[src]
fn ne(&self, other: &BoundingBox<S>) -> bool
[src]
impl<T> RelativeEq<BoundingBox<T>> for BoundingBox<T> where
T: RealField + Float + RelativeEq<T>,
<T as AbsDiffEq<T>>::Epsilon: Copy,
[src]
T: RealField + Float + RelativeEq<T>,
<T as AbsDiffEq<T>>::Epsilon: Copy,
fn default_max_relative() -> <T as AbsDiffEq<T>>::Epsilon
[src]
fn relative_eq(
&self,
other: &BoundingBox<T>,
epsilon: <T as AbsDiffEq<T>>::Epsilon,
max_relative: <T as AbsDiffEq<T>>::Epsilon
) -> bool
[src]
&self,
other: &BoundingBox<T>,
epsilon: <T as AbsDiffEq<T>>::Epsilon,
max_relative: <T as AbsDiffEq<T>>::Epsilon
) -> bool
fn relative_ne(
&self,
other: &Rhs,
epsilon: Self::Epsilon,
max_relative: Self::Epsilon
) -> bool
[src]
&self,
other: &Rhs,
epsilon: Self::Epsilon,
max_relative: Self::Epsilon
) -> bool
impl<S> StructuralPartialEq for BoundingBox<S> where
S: Debug + RealField,
[src]
S: Debug + RealField,
Auto Trait Implementations
impl<S> RefUnwindSafe for BoundingBox<S> where
S: RefUnwindSafe + Scalar,
S: RefUnwindSafe + Scalar,
impl<S> Send for BoundingBox<S> where
S: Scalar,
S: Scalar,
impl<S> Sync for BoundingBox<S> where
S: Scalar,
S: Scalar,
impl<S> Unpin for BoundingBox<S> where
S: Scalar + Unpin,
S: Scalar + Unpin,
impl<S> UnwindSafe for BoundingBox<S> where
S: Scalar + UnwindSafe,
S: Scalar + UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
[src]
SS: SubsetOf<SP>,
fn to_subset(&self) -> Option<SS>
[src]
fn is_in_subset(&self) -> bool
[src]
unsafe fn to_subset_unchecked(&self) -> SS
[src]
fn from_subset(element: &SS) -> SP
[src]
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,