Public Member Functions | Public Attributes | Private Attributes
AABB Class Reference

#include <IceAABB.h>

List of all members.

Public Member Functions

inline_ AABB ()
 Constructor.
void Extend (const Point &p)
inline_ void GetCenter (Point &center) const
 Get box center.
inline_ float GetCenter (udword axis) const
 Get component of the box's center along a given axis.
inline_ float GetDepth () const
inline_ void GetDiagonal (Point &diagonal) const
 Get box diagonal.
inline_ void GetExtents (Point &extents) const
 Get box extents.
inline_ float GetExtents (udword axis) const
 Get component of the box's extents along a given axis.
inline_ float GetHeight () const
inline_ void GetMax (Point &max) const
 Get max point of the box.
inline_ float GetMax (udword axis) const
 Get component of the box's max point along a given axis.
inline_ void GetMin (Point &min) const
 Get min point of the box.
inline_ float GetMin (udword axis) const
 Get component of the box's min point along a given axis.
float GetSize () const
inline_ float GetVolume () const
 Volume.
inline_ float GetWidth () const
inline_ bool GomezIntersect (const AABB &a)
inline_ BOOL Intersect (const AABB &a) const
inline_ BOOL Intersect (const AABB &a, udword axis) const
inline_ BOOL IsValid () const
inline_ AABBoperator*= (float s)
 Operator for AABB *= float. Scales the extents, keeps same center.
inline_ AABBoperator+= (const Point &trans)
 Operator for AABB += Point. Translates the box.
inline_ AABBoperator/= (float s)
 Operator for AABB /= float. Scales the extents, keeps same center.
inline_ void Rotate (const Matrix4x4 &mtx, AABB &aabb) const
void SetCenterExtents (const Point &c, const Point &e)
void SetEmpty ()
void SetMinMax (const Point &min, const Point &max)
void SetPoint (const Point &pt)
inline_ ~AABB ()
 Destructor.

Public Attributes

 AABB_COMMON_METHODS
 Type-independent methods.

Private Attributes

Point mCenter
 AABB Center.
Point mExtents
 x, y and z extents

Detailed Description

AABB class.

Author:
Pierre Terdiman
Version:
1.0

Definition at line 267 of file IceAABB.h.


Constructor & Destructor Documentation

inline_ AABB::AABB ( ) [inline]

Constructor.

Definition at line 271 of file IceAABB.h.

inline_ AABB::~AABB ( ) [inline]

Destructor.

Definition at line 273 of file IceAABB.h.


Member Function Documentation

void AABB::Extend ( const Point p) [inline]

Extends the AABB.

Parameters:
p[in] the next point

Definition at line 324 of file IceAABB.h.

inline_ void AABB::GetCenter ( Point center) const [inline]

Get box center.

Definition at line 353 of file IceAABB.h.

inline_ float AABB::GetCenter ( udword  axis) const [inline]

Get component of the box's center along a given axis.

Definition at line 358 of file IceAABB.h.

inline_ float AABB::GetDepth ( ) const [inline]

Definition at line 366 of file IceAABB.h.

inline_ void AABB::GetDiagonal ( Point diagonal) const [inline]

Get box diagonal.

Definition at line 363 of file IceAABB.h.

inline_ void AABB::GetExtents ( Point extents) const [inline]

Get box extents.

Definition at line 355 of file IceAABB.h.

inline_ float AABB::GetExtents ( udword  axis) const [inline]

Get component of the box's extents along a given axis.

Definition at line 360 of file IceAABB.h.

inline_ float AABB::GetHeight ( ) const [inline]

Definition at line 365 of file IceAABB.h.

inline_ void AABB::GetMax ( Point max) const [inline]

Get max point of the box.

Definition at line 345 of file IceAABB.h.

inline_ float AABB::GetMax ( udword  axis) const [inline]

Get component of the box's max point along a given axis.

Definition at line 350 of file IceAABB.h.

inline_ void AABB::GetMin ( Point min) const [inline]

Get min point of the box.

Definition at line 343 of file IceAABB.h.

inline_ float AABB::GetMin ( udword  axis) const [inline]

Get component of the box's min point along a given axis.

Definition at line 348 of file IceAABB.h.

float AABB::GetSize ( ) const [inline]

Gets the size of the AABB. The size is defined as the longest extent.

Returns:
the size of the AABB

Definition at line 316 of file IceAABB.h.

inline_ float AABB::GetVolume ( ) const [inline]

Volume.

Definition at line 369 of file IceAABB.h.

inline_ float AABB::GetWidth ( ) const [inline]

Definition at line 364 of file IceAABB.h.

inline_ bool AABB::GomezIntersect ( const AABB a) [inline]

The standard intersection method from Gamasutra. Just here to check its speed against the one above.

Parameters:
a[in] the other AABB
Returns:
true on intersection

Definition at line 393 of file IceAABB.h.

inline_ BOOL AABB::Intersect ( const AABB a) const [inline]

Computes the intersection between two AABBs.

Parameters:
a[in] the other AABB
Returns:
true on intersection

Definition at line 378 of file IceAABB.h.

inline_ BOOL AABB::Intersect ( const AABB a,
udword  axis 
) const [inline]

Computes the 1D-intersection between two AABBs, on a given axis.

Parameters:
a[in] the other AABB
axis[in] the axis (0, 1, 2)
Returns:
true on intersection

Definition at line 409 of file IceAABB.h.

inline_ BOOL AABB::IsValid ( ) const [inline]

Checks the AABB is valid.

Returns:
true if the box is valid

Definition at line 450 of file IceAABB.h.

inline_ AABB& AABB::operator*= ( float  s) [inline]

Operator for AABB *= float. Scales the extents, keeps same center.

Definition at line 460 of file IceAABB.h.

inline_ AABB& AABB::operator+= ( const Point trans) [inline]

Operator for AABB += Point. Translates the box.

Definition at line 466 of file IceAABB.h.

inline_ AABB& AABB::operator/= ( float  s) [inline]

Operator for AABB /= float. Scales the extents, keeps same center.

Definition at line 463 of file IceAABB.h.

inline_ void AABB::Rotate ( const Matrix4x4 mtx,
AABB aabb 
) const [inline]

Recomputes the AABB after an arbitrary transform by a 4x4 matrix.

Parameters:
mtx[in] the transform matrix
aabb[out] the transformed AABB [can be *this]

Definition at line 424 of file IceAABB.h.

void AABB::SetCenterExtents ( const Point c,
const Point e 
) [inline]

Setups an AABB from center & extents vectors.

Parameters:
c[in] the center point
e[in] the extents vector

Definition at line 294 of file IceAABB.h.

void AABB::SetEmpty ( ) [inline]

Setups an empty AABB.

Definition at line 301 of file IceAABB.h.

void AABB::SetMinMax ( const Point min,
const Point max 
) [inline]

Setups an AABB from min & max vectors.

Parameters:
min[in] the min point
max[in] the max point

Definition at line 285 of file IceAABB.h.

void AABB::SetPoint ( const Point pt) [inline]

Setups a point AABB.

Definition at line 308 of file IceAABB.h.


Member Data Documentation

Type-independent methods.

Definition at line 276 of file IceAABB.h.

Point AABB::mCenter [private]

AABB Center.

Definition at line 472 of file IceAABB.h.

Point AABB::mExtents [private]

x, y and z extents

Definition at line 473 of file IceAABB.h.


The documentation for this class was generated from the following file:


openhrp3
Author(s): AIST, General Robotix Inc., Nakamura Lab of Dept. of Mechano Informatics at University of Tokyo
autogenerated on Thu Apr 11 2019 03:30:20