Struct bbox::BoundingBox[][src]

pub struct BoundingBox<S: Real + Debug> {
    pub min: Point3<S>,
    pub max: Point3<S>,
}

3D Bounding Box - defined by two diagonally opposing points.

Fields

X-Y-Z-Minimum corner of the box.

X-Y-Z-Maximum corner of the box.

Methods

impl<S: Float + Real> BoundingBox<S>
[src]

Returns an infinte sized box.

Returns a negatively infinte sized box.

Create a new Bounding Box by supplying two points.

Create a CSG Union of two Bounding Boxes.

Create a CSG Intersection of two Bounding Boxes.

Transform a Bounding Box - resulting in a enclosing axis aligned Bounding Box.

Dilate a Bounding Box by some amount in all directions.

Add a Point to a Bounding Box, e.g. expand the Bounding Box to contain that point.

Return the size of the Box.

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.

Return true if the Bounding Box contains p.

Trait Implementations

impl<S: Clone + Real + Debug> Clone for BoundingBox<S>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl<S: Debug + Real + Debug> Debug for BoundingBox<S>
[src]

Formats the value using the given formatter. Read more

impl<S: PartialEq + Real + Debug> PartialEq for BoundingBox<S>
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl<T: Float + Real> AbsDiffEq for BoundingBox<T> where
    <T as AbsDiffEq>::Epsilon: Copy,
    T: AbsDiffEq
[src]

Used for specifying relative comparisons.

The default tolerance to use when testing values that are close together. Read more

A test for equality that uses the absolute difference to compute the approximate equality of two numbers. Read more

The inverse of ApproxEq::abs_diff_eq.

impl<T: Float + Real> RelativeEq for BoundingBox<T> where
    <T as AbsDiffEq>::Epsilon: Copy,
    T: RelativeEq
[src]

The default relative tolerance for testing values that are far-apart. Read more

A test for equality that uses a relative comparison if the values are far apart.

The inverse of ApproxEq::relative_eq.

Auto Trait Implementations

impl<S> Send for BoundingBox<S>

impl<S> Sync for BoundingBox<S>