116 return (std::max(v.
X, 0.0f) * std::max(v.
Y, 0.0f) * std::max(v.
Z, 0.0f));
128 void Expand(
float amount);
Definition: BoundingBoxAligned.h:34
const CVector3D & operator[](int index) const
Definition: BoundingBoxAligned.h:68
void Translate(const CVector3D &v, CBoundingBoxAligned &result) const
Translates these bounds by v, and writes the result to result.
Definition: BoundingBoxAligned.h:61
CBoundingBoxAligned()
Definition: BoundingBoxAligned.h:38
CBoundingBoxAligned & operator+=(const CVector3D &pt)
Definition: BoundingBoxAligned.h:91
bool IsPointInside(const CVector3D &point) const
Definition: BoundingBoxAligned.cpp:267
void IntersectFrustumConservative(const CFrustum &frustum)
IntersectFrustumConservative: Approximate the intersection of this bounds object with the given frust...
Definition: BoundingBoxAligned.cpp:210
float GetVolume() const
Definition: BoundingBoxAligned.h:113
void SetEmpty()
Definition: BoundingBoxAligned.cpp:136
void Extend(const CVector3D &min, const CVector3D &max)
Definition: BoundingBoxAligned.h:73
CVector3D & operator[](int index)
Definition: BoundingBoxAligned.h:67
bool RayIntersect(const CVector3D &origin, const CVector3D &dir, float &tmin, float &tmax) const
Check if a given ray intersects this AABB.
Definition: BoundingBoxAligned.cpp:40
CBoundingBoxAligned(const CVector3D &min, const CVector3D &max)
Definition: BoundingBoxAligned.h:39
void Expand(float amount)
Expand the bounding box by the given amount in every direction.
Definition: BoundingBoxAligned.cpp:261
void Transform(const CMatrix3D &m, CBoundingBoxAligned &result) const
Transforms these bounds according to the specified transformation matrix m, and writes the axis-align...
Definition: BoundingBoxAligned.cpp:153
void GetCenter(CVector3D ¢er) const
Definition: BoundingBoxAligned.h:120
CFrustum ToFrustum() const
Construct a CFrustum that describes the same volume as this bounding box.
Definition: BoundingBoxAligned.cpp:227
CBoundingBoxAligned & operator+=(const CBoundingBoxAligned &b)
Definition: BoundingBoxAligned.h:84
bool IsEmpty() const
Definition: BoundingBoxAligned.cpp:144
CVector3D m_Data[2]
Definition: BoundingBoxAligned.h:154
static const CBoundingBoxAligned EMPTY
Definition: BoundingBoxAligned.h:36
Definition: BoundingBoxOriented.h:31
Definition: Matrix3D.h:34
Definition: Vector3D.h:31
float Z
Definition: Vector3D.h:33
float Y
Definition: Vector3D.h:33
float X
Definition: Vector3D.h:33