HDK
|
#include <ImathBox.h>
Public Member Functions | |
IMATH_HOSTDEVICE constexpr bool | operator== (const Box< Vec3< T >> &src) const IMATH_NOEXCEPT |
Equality. More... | |
IMATH_HOSTDEVICE constexpr bool | operator!= (const Box< Vec3< T >> &src) const IMATH_NOEXCEPT |
Inequality. More... | |
IMATH_HOSTDEVICE void | makeEmpty () IMATH_NOEXCEPT |
IMATH_HOSTDEVICE void | extendBy (const Vec3< T > &point) IMATH_NOEXCEPT |
Extend the Box to include the given point. More... | |
IMATH_HOSTDEVICE void | extendBy (const Box< Vec3< T >> &box) IMATH_NOEXCEPT |
Extend the Box to include the given box. More... | |
IMATH_HOSTDEVICE void | makeInfinite () IMATH_NOEXCEPT |
Make the box include the entire range of T. More... | |
IMATH_HOSTDEVICE IMATH_CONSTEXPR14 Vec3< T > | size () const IMATH_NOEXCEPT |
IMATH_HOSTDEVICE constexpr Vec3< T > | center () const IMATH_NOEXCEPT |
IMATH_HOSTDEVICE IMATH_CONSTEXPR14 bool | intersects (const Vec3< T > &point) const IMATH_NOEXCEPT |
Return true if the given point is inside the box, false otherwise. More... | |
IMATH_HOSTDEVICE IMATH_CONSTEXPR14 bool | intersects (const Box< Vec3< T >> &box) const IMATH_NOEXCEPT |
Return true if the given box is inside the box, false otherwise. More... | |
IMATH_HOSTDEVICE IMATH_CONSTEXPR14 unsigned int | majorAxis () const IMATH_NOEXCEPT |
IMATH_HOSTDEVICE IMATH_CONSTEXPR14 bool | isEmpty () const IMATH_NOEXCEPT |
IMATH_HOSTDEVICE IMATH_CONSTEXPR14 bool | hasVolume () const IMATH_NOEXCEPT |
Return true if the box is larger than a single point, false otherwise. More... | |
IMATH_HOSTDEVICE IMATH_CONSTEXPR14 bool | isInfinite () const IMATH_NOEXCEPT |
Constructors | |
IMATH_HOSTDEVICE IMATH_CONSTEXPR14 | Box () IMATH_NOEXCEPT |
Empty by default. More... | |
IMATH_HOSTDEVICE IMATH_CONSTEXPR14 | Box (const Vec3< T > &point) IMATH_NOEXCEPT |
Construct a bounding box that contains a single point. More... | |
IMATH_HOSTDEVICE IMATH_CONSTEXPR14 | Box (const Vec3< T > &minT, const Vec3< T > &maxT) IMATH_NOEXCEPT |
Construct a bounding box with the given minimum and maximum points. More... | |
Public Attributes | |
Direct access to bounds | |
Vec3< T > | min |
The minimum value of the box. More... | |
Vec3< T > | max |
The maximum value of the box. More... | |
The Box<Vec3> template represents a 3D bounding box defined by minimum and maximum values of type Vec3.
Definition at line 628 of file ImathBox.h.
|
inline |
Empty by default.
Definition at line 713 of file ImathBox.h.
|
inline |
Construct a bounding box that contains a single point.
Definition at line 718 of file ImathBox.h.
|
inline |
Construct a bounding box with the given minimum and maximum points.
Definition at line 725 of file ImathBox.h.
Return the center of the box. The center is defined as (max+min)/2. The center of an empty box is undefined.
Definition at line 841 of file ImathBox.h.
|
inline |
Extend the Box to include the given point.
Definition at line 763 of file ImathBox.h.
|
inline |
Extend the Box to include the given box.
Definition at line 786 of file ImathBox.h.
|
inline |
Return true if the box is larger than a single point, false otherwise.
Definition at line 873 of file ImathBox.h.
|
inline |
Return true if the given point is inside the box, false otherwise.
Definition at line 809 of file ImathBox.h.
|
inline |
Return true if the given box is inside the box, false otherwise.
Definition at line 820 of file ImathBox.h.
|
inline |
Return true if the box is empty, false otherwise. An empty box's minimum is greater than its maximum.
Definition at line 848 of file ImathBox.h.
|
inline |
Return true if the box contains all points, false otherwise. An infinite box has a mimimum ofV::baseTypeMin()
and a maximum of V::baseTypeMax()
.
Definition at line 858 of file ImathBox.h.
|
inline |
Return the major axis of the box. The major axis is the dimension with the greatest difference between maximum and minimum.
Definition at line 883 of file ImathBox.h.
|
inline |
Set the Box to be empty. A Box is empty if the mimimum is greater than the maximum. makeEmpty() sets the mimimum to std::numeric_limits<T>::max() and the maximum to std::numeric_limits<T>::lowest().
Definition at line 747 of file ImathBox.h.
|
inline |
Make the box include the entire range of T.
Definition at line 755 of file ImathBox.h.
|
inline |
Inequality.
Definition at line 740 of file ImathBox.h.
|
inline |
Equality.
Definition at line 733 of file ImathBox.h.
|
inline |
Return the size of the box. The size is of type V
, defined as (max-min). An empty box has a size of V(0), i.e. 0 in each dimension.
Definition at line 831 of file ImathBox.h.
The maximum value of the box.
Definition at line 639 of file ImathBox.h.
The minimum value of the box.
Definition at line 636 of file ImathBox.h.