Convex Class Reference#include <convex.h>
Inheritance diagram for Convex:
[legend]
|
Linked list managent |
Convex * | mNext |
| Next item in linked list of Convex's.
|
Convex * | mPrev |
| Previous item in linked list of Convex's.
|
void | linkAfter (Convex *next) |
| Insert this Convex after the provided convex.
|
void | unlink () |
| Remove this Convex from the linked list.
|
Public Member Functions |
| Convex () |
| Constructor.
|
virtual | ~Convex () |
| Destructor.
|
void | registerObject (Convex *convex) |
| Registers another Convex by linking it after this one.
|
void | collectGarbage () |
| Runs through the linked list of Convex objects and removes the ones with no references.
|
void | nukeList () |
| Deletes all convex objects in the list.
|
ConvexType | getType () |
| Returns the type of this Convex.
|
SceneObject * | getObject () |
| Returns the object this Convex is built from.
|
void | render () |
| Traverses mList and renders all collision states.
|
void | addToWorkingList (Convex *ptr) |
| Adds the provided Convex to the list of objects within the bounds of this Convex.
|
CollisionWorkingList & | getWorkingList () |
| Returns the list of objects currently inside the bounds of this Convex.
|
CollisionState * | findClosestState (const MatrixF &mat, const Point3F &scale, const F32 dontCareDist=1) |
| Finds the closest.
|
CollisionStateList * | getStateList () |
| Returns the list of objects this object is testing against.
|
void | updateStateList (const MatrixF &mat, const Point3F &scale, const Point3F *displacement=NULL) |
| Updates the CollisionStateList (mList) with new collision states and removing ones no longer under consideration.
|
void | updateWorkingList (const Box3F &box, const U32 colMask) |
| Updates the working collision list of objects which are currently colliding with (inside the bounds of) this Convex.
|
virtual const MatrixF & | getTransform () const |
| Returns the transform of the object this is built around.
|
virtual const Point3F & | getScale () const |
| Returns the scale of the object this is built around.
|
virtual Box3F | getBoundingBox () const |
| Returns the bounding box for the object this is built around in world space.
|
virtual Box3F | getBoundingBox (const MatrixF &mat, const Point3F &scale) const |
| Returns the object space bounding box for the object this is built around transformed and scaled.
|
virtual Point3F | support (const VectorF &v) const |
| Returns the farthest point, along a vector, still bound by the convex.
|
virtual void | getFeatures (const MatrixF &mat, const VectorF &n, ConvexFeature *cf) |
virtual void | getPolyList (AbstractPolyList *list) |
| Builds a collision poly list out of this convex.
|
bool | getCollisionInfo (const MatrixF &mat, const Point3F &scale, CollisionList *cList, F32 tol) |
Protected Attributes |
CollisionStateList | mList |
| Objects we're testing against.
|
CollisionWorkingList | mWorking |
| Objects within our bounds.
|
CollisionWorkingList | mReference |
| Other convex testing against us.
|
SceneObject * | mObject |
| Object this Convex is built around.
|
ConvexType | mType |
| Type of Convex this is.
|
Private Attributes |
U32 | mTag |
Static Private Attributes |
static U32 | sTag |
Constructor & Destructor Documentation
virtual Convex::~Convex |
( |
|
) |
[virtual] |
Member Function Documentation
void Convex::linkAfter |
( |
Convex * |
next |
) |
[private] |
Insert this Convex after the provided convex.
- Parameters:
-
void Convex::unlink |
( |
|
) |
[private] |
Remove this Convex from the linked list.
Registers another Convex by linking it after this one.
void Convex::collectGarbage |
( |
|
) |
|
Runs through the linked list of Convex objects and removes the ones with no references.
void Convex::nukeList |
( |
|
) |
|
Deletes all convex objects in the list.
Returns the type of this Convex.
Returns the object this Convex is built from.
Traverses mList and renders all collision states.
Adds the provided Convex to the list of objects within the bounds of this Convex.
- Parameters:
-
| ptr | Convex to add to the working list of this object |
Returns the list of objects currently inside the bounds of this Convex.
Returns the list of objects this object is testing against.
Updates the CollisionStateList (mList) with new collision states and removing ones no longer under consideration.
- Parameters:
-
| mat | Used as the matrix to create a bounding box for updating the list |
| scale | Used to scale the bounding box |
| displacement | Bounding box displacement (optional) |
void Convex::updateWorkingList |
( |
const Box3F & |
box, |
|
|
const U32 |
colMask | |
|
) |
| | |
Updates the working collision list of objects which are currently colliding with (inside the bounds of) this Convex.
- Parameters:
-
| box | Used as the bounding box. |
| colMask | Mask of objects to check against. |
virtual const MatrixF& Convex::getTransform |
( |
|
) |
const [virtual] |
virtual const Point3F& Convex::getScale |
( |
|
) |
const [virtual] |
Returns the scale of the object this is built around.
virtual Box3F Convex::getBoundingBox |
( |
|
) |
const [virtual] |
virtual Box3F Convex::getBoundingBox |
( |
const MatrixF & |
mat, |
|
|
const Point3F & |
scale | |
|
) |
| | const [virtual] |
Field Documentation
Next item in linked list of Convex's.
Previous item in linked list of Convex's.
Objects we're testing against.
Objects within our bounds.
Other convex testing against us.
Object this Convex is built around.
|