PixelLightAPI  .
Public Member Functions
PLMath::BoundingBox Class Reference

Bounding box class. More...

#include <BoundingBox.h>

List of all members.

Public Member Functions

PLMATH_API BoundingBox ()
 Constructor.
PLMATH_API BoundingBox (const BoundingBox &cSource)
 Copy constructor.
PLMATH_API ~BoundingBox ()
 Destructor.
PLMATH_API BoundingBoxoperator= (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 Vector3GetPos () 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 Vector3GetScale () 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 Matrix3x3GetFinalRot () const
 Returns the current final rotation matrix.
PLMATH_API const Matrix3x3GetRot () const
 Returns the current rotation matrix.
PLMATH_API void SetRot (const Matrix3x3 &mRot)
 Set the current rotation matrix.
PLMATH_API const Matrix3x3GetBaseRot () const
 Returns the current base rotation matrix.
PLMATH_API void SetBaseRot (const Matrix3x3 &mBaseRot)
 Set the current base rotation matrix.

Detailed Description

Bounding box class.


Constructor & Destructor Documentation

Constructor.

PLMATH_API PLMath::BoundingBox::BoundingBox ( const BoundingBox cSource)

Copy constructor.

Parameters:
[in]cSourceSource to copy from

Destructor.


Member Function Documentation

PLMATH_API BoundingBox& PLMath::BoundingBox::operator= ( const BoundingBox cSource)

Copy operator.

Parameters:
[in]cSourceSource to copy from
Returns:
Reference to this instance
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.

Parameters:
[out]fX1Receives the x position of corner 1
[out]fY1Receives the y position of corner 1
[out]fZ1Receives the z position of corner 1
[out]fX2Receives the x position of corner 2
[out]fY2Receives the y position of corner 2
[out]fZ2Receives 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.

Parameters:
[in]fX1X position of corner 1
[in]fY1Y position of corner 1
[in]fZ1Z position of corner 1
[in]fX2X position of corner 2
[in]fY2Y position of corner 2
[in]fZ2Z position of corner 2
PLMATH_API Vector3 PLMath::BoundingBox::GetCorner1 ( bool  bRotate = true) const

Returns corner 1 (min -> world space)

Parameters:
[in]bRotateRotate corner corresponding to the bounding box?
Returns:
Corner 1
PLMATH_API Vector3 PLMath::BoundingBox::GetCorner2 ( bool  bRotate = true) const

Returns corner 2 (max -> world space)

Parameters:
[in]bRotateRotate corner corresponding to the bounding box?
Returns:
Corner 2
PLMATH_API float PLMath::BoundingBox::GetBoundingSphere ( ) const

Returns the radius of the bounding sphere.

Returns:
Bounding sphere radius
PLMATH_API const Vector3& PLMath::BoundingBox::GetPos ( ) const

Returns the current position.

Returns:
Current position
PLMATH_API void PLMath::BoundingBox::SetPos ( float  fX = 0.0f,
float  fY = 0.0f,
float  fZ = 0.0f 
)

Set the current position.

Parameters:
[in]fXNew x position
[in]fYNew y position
[in]fZNew z position
PLMATH_API void PLMath::BoundingBox::SetPos ( const Vector3 vPos)

Set the current position.

Parameters:
[in]vPosNew position
PLMATH_API const Vector3& PLMath::BoundingBox::GetScale ( ) const

Returns the current scale.

Returns:
Current scale
PLMATH_API void PLMath::BoundingBox::SetScale ( float  fX = 1.0f,
float  fY = 1.0f,
float  fZ = 1.0f 
)

Set the current scale.

Parameters:
[in]fXNew x scale
[in]fYNew y scale
[in]fZNew z scale
PLMATH_API void PLMath::BoundingBox::SetScale ( const Vector3 vScale)

Set the current scale.

Parameters:
[in]vScaleNew scale
PLMATH_API const Matrix3x3& PLMath::BoundingBox::GetFinalRot ( ) const

Returns the current final rotation matrix.

Returns:
Current final rotation matrix
PLMATH_API const Matrix3x3& PLMath::BoundingBox::GetRot ( ) const

Returns the current rotation matrix.

Returns:
Current rotation matrix
PLMATH_API void PLMath::BoundingBox::SetRot ( const Matrix3x3 mRot)

Set the current rotation matrix.

Parameters:
[in]mRotNew rotation matrix
PLMATH_API const Matrix3x3& PLMath::BoundingBox::GetBaseRot ( ) const

Returns the current base rotation matrix.

Returns:
Current base rotation matrix
PLMATH_API void PLMath::BoundingBox::SetBaseRot ( const Matrix3x3 mBaseRot)

Set the current base rotation matrix.

Parameters:
[in]mBaseRotNew base rotation matrix

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


PixelLight PixelLight 0.9.10-R1
Copyright (C) 2002-2011 by The PixelLight Team
Last modified Fri Dec 23 2011 15:51:19
The content of this PixelLight document is published under the
Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported