![]() |
OpenVDB 14.0.0
|
Partial template specialization for floating point coordinate types. More...
#include <nanovdb/math/Math.h>
Public Types | |
| using | Vec3Type = Vec3T |
| using | ValueType = typename Vec3T::ValueType |
| using | BaseT = BaseBBox<Vec3T> |
Public Member Functions | |
| __hostdev__ constexpr | BBox () noexcept |
| Default construction sets BBox to an empty bbox. | |
| __hostdev__ constexpr | BBox (const Vec3T &min, const Vec3T &max) noexcept |
| Construct from explicit min / max corners. | |
| __hostdev__ constexpr | BBox (const Coord &min, const Coord &max) noexcept |
Convert an integer Coord box into this floating-point box. | |
| __hostdev__ constexpr | BBox (const BaseBBox< Coord > &bbox) noexcept |
Construct from a BaseBBox<Coord>; delegates to the (min, max) ctor. | |
| __hostdev__ constexpr bool | empty () const noexcept |
Return true if this bounding box is empty (max <= min in any axis). | |
| __hostdev__ constexpr | operator bool () const noexcept |
Convert to bool: true iff this bounding box has positive volume. | |
| __hostdev__ constexpr Vec3T | dim () const noexcept |
Return max - min when non-empty, else the zero vector. | |
| __hostdev__ constexpr bool | isInside (const Vec3T &p) const noexcept |
Return true iff p is strictly inside the box (open interval — min is exclusive, max is exclusive). | |
| __hostdev__ constexpr bool | operator== (const BaseBBox &rhs) const noexcept |
| Equality on the two corner points. | |
| __hostdev__ constexpr bool | operator!= (const BaseBBox &rhs) const noexcept |
| Inequality on the two corner points. | |
| __hostdev__ constexpr const Vec3T & | operator[] (int i) const noexcept |
| Indexed corner access: i = 0 returns min, i = 1 returns max. | |
| __hostdev__ constexpr Vec3T & | operator[] (int i) noexcept |
Mutable variant of operator[]. | |
| __hostdev__ constexpr Vec3T & | min () noexcept |
| Mutable accessor for the min corner. | |
| __hostdev__ constexpr const Vec3T & | min () const noexcept |
| Const accessor for the min corner. | |
| __hostdev__ constexpr Vec3T & | max () noexcept |
| Mutable accessor for the max corner. | |
| __hostdev__ constexpr const Vec3T & | max () const noexcept |
| Const accessor for the max corner. | |
| __hostdev__ constexpr BaseBBox & | translate (const Vec3T &xyz) noexcept |
Translate (rigid-shift) both corners by xyz; return *this. | |
| __hostdev__ constexpr BaseBBox & | expand (const Vec3T &xyz) noexcept |
Expand this bounding box to enclose point xyz. | |
| __hostdev__ constexpr BaseBBox & | expand (const BaseBBox &bbox) noexcept |
| Expand this bounding box to enclose the given bounding box. | |
| __hostdev__ constexpr BaseBBox & | intersect (const BaseBBox &bbox) noexcept |
| Intersect this bounding box with the given bounding box. | |
Static Public Member Functions | |
| static __hostdev__ constexpr BBox | createCube (const Coord &min, typename Coord::ValueType dim) noexcept |
Return a cube-shaped BBox with min corner min and edge length dim. | |
Public Attributes | |
| Vec3T | mCoord [2] |
Partial template specialization for floating point coordinate types.
| using ValueType = typename Vec3T::ValueType |
| using Vec3Type = Vec3T |
|
inlineconstexprnoexcept |
Default construction sets BBox to an empty bbox.
|
inlineconstexprnoexcept |
Construct from explicit min / max corners.
|
inlineconstexprnoexcept |
Convert an integer Coord box into this floating-point box.
max is exclusive in the floating-point convention, so the integer max corner is incremented by 1 before conversion.
|
inlineconstexprnoexcept |
Construct from a BaseBBox<Coord>; delegates to the (min, max) ctor.
|
inlinestaticnodiscardconstexprnoexcept |
Return a cube-shaped BBox with min corner min and edge length dim.
|
inlinenodiscardconstexprnoexcept |
Return max - min when non-empty, else the zero vector.
|
inlinenodiscardconstexprnoexcept |
Return true if this bounding box is empty (max <= min in any axis).
|
inlineconstexprnoexceptinherited |
Expand this bounding box to enclose the given bounding box.
|
inlineconstexprnoexceptinherited |
Expand this bounding box to enclose point xyz.
|
inlineconstexprnoexceptinherited |
Intersect this bounding box with the given bounding box.
|
inlinenodiscardconstexprnoexcept |
Return true iff p is strictly inside the box (open interval — min is exclusive, max is exclusive).
|
inlineconstexprnoexceptinherited |
Const accessor for the max corner.
|
inlineconstexprnoexceptinherited |
Mutable accessor for the max corner.
|
inlineconstexprnoexceptinherited |
Const accessor for the min corner.
|
inlineconstexprnoexceptinherited |
Mutable accessor for the min corner.
|
inlinenodiscardconstexprnoexcept |
Convert to bool: true iff this bounding box has positive volume.
|
inlinenodiscardconstexprnoexceptinherited |
Inequality on the two corner points.
|
inlinenodiscardconstexprnoexceptinherited |
Equality on the two corner points.
|
inlineconstexprnoexceptinherited |
Indexed corner access: i = 0 returns min, i = 1 returns max.
|
inlineconstexprnoexceptinherited |
Mutable variant of operator[].
|
inlineconstexprnoexceptinherited |
Translate (rigid-shift) both corners by xyz; return *this.
| Vec3T mCoord[2] |