PixelLightAPI
.
|
Bounding box class. More...
#include <BoundingBox.h>
Public Member Functions | |
PLMATH_API | BoundingBox () |
Constructor. | |
PLMATH_API | BoundingBox (const BoundingBox &cSource) |
Copy constructor. | |
PLMATH_API | ~BoundingBox () |
Destructor. | |
PLMATH_API BoundingBox & | operator= (const BoundingBox &cSource) |
Copy operator. | |
PLMATH_API void | GetSize (float &fX1, float &fY1, float &fZ1, float &fX2, float &fY2, float &fZ2) const |
Returns the size of the bounding box. | |
PLMATH_API void | SetSize (float fX1, float fY1, float fZ1, float fX2, float fY2, float fZ2) |
Set the size of the bounding box. | |
PLMATH_API Vector3 | GetCorner1 (bool bRotate=true) const |
Returns corner 1 (min -> world space) | |
PLMATH_API Vector3 | GetCorner2 (bool bRotate=true) const |
Returns corner 2 (max -> world space) | |
PLMATH_API float | GetBoundingSphere () const |
Returns the radius of the bounding sphere. | |
PLMATH_API const Vector3 & | GetPos () const |
Returns the current position. | |
PLMATH_API void | SetPos (float fX=0.0f, float fY=0.0f, float fZ=0.0f) |
Set the current position. | |
PLMATH_API void | SetPos (const Vector3 &vPos) |
Set the current position. | |
PLMATH_API const Vector3 & | GetScale () const |
Returns the current scale. | |
PLMATH_API void | SetScale (float fX=1.0f, float fY=1.0f, float fZ=1.0f) |
Set the current scale. | |
PLMATH_API void | SetScale (const Vector3 &vScale) |
Set the current scale. | |
PLMATH_API const Matrix3x3 & | GetFinalRot () const |
Returns the current final rotation matrix. | |
PLMATH_API const Matrix3x3 & | GetRot () const |
Returns the current rotation matrix. | |
PLMATH_API void | SetRot (const Matrix3x3 &mRot) |
Set the current rotation matrix. | |
PLMATH_API const Matrix3x3 & | GetBaseRot () const |
Returns the current base rotation matrix. | |
PLMATH_API void | SetBaseRot (const Matrix3x3 &mBaseRot) |
Set the current base rotation matrix. |
Bounding box class.
PLMATH_API PLMath::BoundingBox::BoundingBox | ( | ) |
Constructor.
PLMATH_API PLMath::BoundingBox::BoundingBox | ( | const BoundingBox & | cSource | ) |
Copy constructor.
[in] | cSource | Source to copy from |
PLMATH_API PLMath::BoundingBox::~BoundingBox | ( | ) |
Destructor.
PLMATH_API BoundingBox& PLMath::BoundingBox::operator= | ( | const BoundingBox & | cSource | ) |
Copy operator.
[in] | cSource | Source to copy from |
PLMATH_API void PLMath::BoundingBox::GetSize | ( | float & | fX1, |
float & | fY1, | ||
float & | fZ1, | ||
float & | fX2, | ||
float & | fY2, | ||
float & | fZ2 | ||
) | const |
Returns the size of the bounding box.
[out] | fX1 | Receives the x position of corner 1 |
[out] | fY1 | Receives the y position of corner 1 |
[out] | fZ1 | Receives the z position of corner 1 |
[out] | fX2 | Receives the x position of corner 2 |
[out] | fY2 | Receives the y position of corner 2 |
[out] | fZ2 | Receives the z position of corner 2 |
PLMATH_API void PLMath::BoundingBox::SetSize | ( | float | fX1, |
float | fY1, | ||
float | fZ1, | ||
float | fX2, | ||
float | fY2, | ||
float | fZ2 | ||
) |
Set the size of the bounding box.
[in] | fX1 | X position of corner 1 |
[in] | fY1 | Y position of corner 1 |
[in] | fZ1 | Z position of corner 1 |
[in] | fX2 | X position of corner 2 |
[in] | fY2 | Y position of corner 2 |
[in] | fZ2 | Z position of corner 2 |
PLMATH_API Vector3 PLMath::BoundingBox::GetCorner1 | ( | bool | bRotate = true | ) | const |
Returns corner 1 (min -> world space)
[in] | bRotate | Rotate corner corresponding to the bounding box? |
PLMATH_API Vector3 PLMath::BoundingBox::GetCorner2 | ( | bool | bRotate = true | ) | const |
Returns corner 2 (max -> world space)
[in] | bRotate | Rotate corner corresponding to the bounding box? |
PLMATH_API float PLMath::BoundingBox::GetBoundingSphere | ( | ) | const |
Returns the radius of the bounding sphere.
PLMATH_API const Vector3& PLMath::BoundingBox::GetPos | ( | ) | const |
Returns the current position.
PLMATH_API void PLMath::BoundingBox::SetPos | ( | float | fX = 0.0f , |
float | fY = 0.0f , |
||
float | fZ = 0.0f |
||
) |
Set the current position.
[in] | fX | New x position |
[in] | fY | New y position |
[in] | fZ | New z position |
PLMATH_API void PLMath::BoundingBox::SetPos | ( | const Vector3 & | vPos | ) |
Set the current position.
[in] | vPos | New position |
PLMATH_API const Vector3& PLMath::BoundingBox::GetScale | ( | ) | const |
Returns the current scale.
PLMATH_API void PLMath::BoundingBox::SetScale | ( | float | fX = 1.0f , |
float | fY = 1.0f , |
||
float | fZ = 1.0f |
||
) |
Set the current scale.
[in] | fX | New x scale |
[in] | fY | New y scale |
[in] | fZ | New z scale |
PLMATH_API void PLMath::BoundingBox::SetScale | ( | const Vector3 & | vScale | ) |
Set the current scale.
[in] | vScale | New scale |
PLMATH_API const Matrix3x3& PLMath::BoundingBox::GetFinalRot | ( | ) | const |
Returns the current final rotation matrix.
PLMATH_API const Matrix3x3& PLMath::BoundingBox::GetRot | ( | ) | const |
Returns the current rotation matrix.
PLMATH_API void PLMath::BoundingBox::SetRot | ( | const Matrix3x3 & | mRot | ) |
Set the current rotation matrix.
[in] | mRot | New rotation matrix |
PLMATH_API const Matrix3x3& PLMath::BoundingBox::GetBaseRot | ( | ) | const |
Returns the current base rotation matrix.
PLMATH_API void PLMath::BoundingBox::SetBaseRot | ( | const Matrix3x3 & | mBaseRot | ) |
Set the current base rotation matrix.
[in] | mBaseRot | New base rotation matrix |
|