Blender V2.61 - r43446
|
btGImpactCompoundShape allows to handle multiple btCollisionShape objects at once More...
#include <btGImpactShape.h>
Classes | |
class | CompoundPrimitiveManager |
compound primitive manager More... | |
Public Member Functions | |
btGImpactCompoundShape (bool children_has_transform=true) | |
virtual | ~btGImpactCompoundShape () |
virtual bool | childrenHasTransform () const |
if true, then its children must get transforms. | |
virtual const btPrimitiveManagerBase * | getPrimitiveManager () const |
Obtains the primitive manager. | |
SIMD_FORCE_INLINE CompoundPrimitiveManager * | getCompoundPrimitiveManager () |
Obtains the compopund primitive manager. | |
virtual int | getNumChildShapes () const |
Gets the number of children. | |
void | addChildShape (const btTransform &localTransform, btCollisionShape *shape) |
Use this method for adding children. Only Convex shapes are allowed. | |
void | addChildShape (btCollisionShape *shape) |
Use this method for adding children. Only Convex shapes are allowed. | |
virtual btCollisionShape * | getChildShape (int index) |
Gets the children. | |
virtual const btCollisionShape * | getChildShape (int index) const |
Gets the children. | |
virtual void | getChildAabb (int child_index, const btTransform &t, btVector3 &aabbMin, btVector3 &aabbMax) const |
Retrieves the bound from a child. | |
virtual btTransform | getChildTransform (int index) const |
Gets the children transform. | |
virtual void | setChildTransform (int index, const btTransform &transform) |
Sets the children transform. | |
virtual bool | needsRetrieveTriangles () const |
Determines if this shape has triangles. | |
virtual bool | needsRetrieveTetrahedrons () const |
Determines if this shape has tetrahedrons. | |
virtual void | getBulletTriangle (int prim_index, btTriangleShapeEx &triangle) const |
Base method for determinig which kind of GIMPACT shape we get. | |
virtual void | getBulletTetrahedron (int prim_index, btTetrahedronShapeEx &tetrahedron) const |
Base method for determinig which kind of GIMPACT shape we get. | |
virtual void | calculateLocalInertia (btScalar mass, btVector3 &inertia) const |
Calculates the exact inertia tensor for this shape. | |
virtual const char * | getName () const |
virtual eGIMPACT_SHAPE_TYPE | getGImpactShapeType () const |
Base method for determinig which kind of GIMPACT shape we get. | |
Protected Attributes | |
CompoundPrimitiveManager | m_primitive_manager |
btAlignedObjectArray< btTransform > | m_childTransforms |
btAlignedObjectArray < btCollisionShape * > | m_childShapes |
btGImpactCompoundShape allows to handle multiple btCollisionShape objects at once
This class only can manage Convex subshapes
Definition at line 300 of file btGImpactShape.h.
btGImpactCompoundShape::btGImpactCompoundShape | ( | bool | children_has_transform = true | ) | [inline] |
Definition at line 370 of file btGImpactShape.h.
References btGImpactShapeInterface::m_box_set, btGImpactCompoundShape::CompoundPrimitiveManager::m_compoundShape, m_primitive_manager, and btGImpactQuantizedBvh::setPrimitiveManager().
virtual btGImpactCompoundShape::~btGImpactCompoundShape | ( | ) | [inline, virtual] |
Definition at line 377 of file btGImpactShape.h.
void btGImpactCompoundShape::addChildShape | ( | const btTransform & | localTransform, |
btCollisionShape * | shape | ||
) | [inline] |
Use this method for adding children. Only Convex shapes are allowed.
Definition at line 410 of file btGImpactShape.h.
References btAssert, btCollisionShape::isConvex(), m_childShapes, m_childTransforms, and btAlignedObjectArray< T >::push_back().
void btGImpactCompoundShape::addChildShape | ( | btCollisionShape * | shape | ) | [inline] |
Use this method for adding children. Only Convex shapes are allowed.
Definition at line 418 of file btGImpactShape.h.
References btAssert, btCollisionShape::isConvex(), m_childShapes, and btAlignedObjectArray< T >::push_back().
void btGImpactCompoundShape::calculateLocalInertia | ( | btScalar | mass, |
btVector3 & | inertia | ||
) | const [virtual] |
Calculates the exact inertia tensor for this shape.
Implements btCollisionShape.
Definition at line 28 of file btGImpactShape.cpp.
References childrenHasTransform(), btTransform::getIdentity(), getNumChildShapes(), gim_inertia_add_transformed(), i, btGImpactShapeInterface::lockChildShapes(), m_childShapes, m_childTransforms, btGImpactShapeInterface::m_localAABB, and btGImpactShapeInterface::unlockChildShapes().
virtual bool btGImpactCompoundShape::childrenHasTransform | ( | ) | const [inline, virtual] |
if true, then its children must get transforms.
Implements btGImpactShapeInterface.
Definition at line 383 of file btGImpactShape.h.
References m_childTransforms, and btAlignedObjectArray< T >::size().
Referenced by calculateLocalInertia(), btGImpactCompoundShape::CompoundPrimitiveManager::get_primitive_box(), and getChildAabb().
virtual void btGImpactCompoundShape::getBulletTetrahedron | ( | int | prim_index, |
btTetrahedronShapeEx & | tetrahedron | ||
) | const [inline, virtual] |
Base method for determinig which kind of GIMPACT shape we get.
Subshape member functions
Implements btGImpactShapeInterface.
Definition at line 490 of file btGImpactShape.h.
References btAssert.
virtual void btGImpactCompoundShape::getBulletTriangle | ( | int | prim_index, |
btTriangleShapeEx & | triangle | ||
) | const [inline, virtual] |
Base method for determinig which kind of GIMPACT shape we get.
Subshape member functions
Implements btGImpactShapeInterface.
Definition at line 484 of file btGImpactShape.h.
References btAssert.
virtual void btGImpactCompoundShape::getChildAabb | ( | int | child_index, |
const btTransform & | t, | ||
btVector3 & | aabbMin, | ||
btVector3 & | aabbMax | ||
) | const [inline, virtual] |
Retrieves the bound from a child.
Reimplemented from btGImpactShapeInterface.
Definition at line 439 of file btGImpactShape.h.
References childrenHasTransform(), m_childShapes, and m_childTransforms.
virtual const btCollisionShape* btGImpactCompoundShape::getChildShape | ( | int | index | ) | const [inline, virtual] |
Gets the children.
Implements btGImpactShapeInterface.
Definition at line 431 of file btGImpactShape.h.
References m_childShapes.
virtual btCollisionShape* btGImpactCompoundShape::getChildShape | ( | int | index | ) | [inline, virtual] |
Gets the children.
Implements btGImpactShapeInterface.
Definition at line 425 of file btGImpactShape.h.
References m_childShapes.
Referenced by btGImpactCompoundShape::CompoundPrimitiveManager::get_primitive_box().
virtual btTransform btGImpactCompoundShape::getChildTransform | ( | int | index | ) | const [inline, virtual] |
Gets the children transform.
Implements btGImpactShapeInterface.
Definition at line 454 of file btGImpactShape.h.
References btAssert, m_childShapes, m_childTransforms, and btAlignedObjectArray< T >::size().
Referenced by btGImpactCompoundShape::CompoundPrimitiveManager::get_primitive_box().
SIMD_FORCE_INLINE CompoundPrimitiveManager* btGImpactCompoundShape::getCompoundPrimitiveManager | ( | ) | [inline] |
Obtains the compopund primitive manager.
Definition at line 397 of file btGImpactShape.h.
References m_primitive_manager.
virtual eGIMPACT_SHAPE_TYPE btGImpactCompoundShape::getGImpactShapeType | ( | ) | const [inline, virtual] |
Base method for determinig which kind of GIMPACT shape we get.
Subshape member functions
Implements btGImpactShapeInterface.
Definition at line 505 of file btGImpactShape.h.
References CONST_GIMPACT_COMPOUND_SHAPE.
virtual const char* btGImpactCompoundShape::getName | ( | void | ) | const [inline, virtual] |
Implements btCollisionShape.
Definition at line 500 of file btGImpactShape.h.
virtual int btGImpactCompoundShape::getNumChildShapes | ( | ) | const [inline, virtual] |
Gets the number of children.
Implements btGImpactShapeInterface.
Definition at line 403 of file btGImpactShape.h.
References m_childShapes, and btAlignedObjectArray< T >::size().
Referenced by calculateLocalInertia(), and btGImpactCompoundShape::CompoundPrimitiveManager::get_primitive_count().
virtual const btPrimitiveManagerBase* btGImpactCompoundShape::getPrimitiveManager | ( | ) | const [inline, virtual] |
Obtains the primitive manager.
Implements btGImpactShapeInterface.
Definition at line 391 of file btGImpactShape.h.
References m_primitive_manager.
virtual bool btGImpactCompoundShape::needsRetrieveTetrahedrons | ( | ) | const [inline, virtual] |
Determines if this shape has tetrahedrons.
Implements btGImpactShapeInterface.
Definition at line 478 of file btGImpactShape.h.
virtual bool btGImpactCompoundShape::needsRetrieveTriangles | ( | ) | const [inline, virtual] |
Determines if this shape has triangles.
Implements btGImpactShapeInterface.
Definition at line 472 of file btGImpactShape.h.
virtual void btGImpactCompoundShape::setChildTransform | ( | int | index, |
const btTransform & | transform | ||
) | [inline, virtual] |
Sets the children transform.
Implements btGImpactShapeInterface.
Definition at line 464 of file btGImpactShape.h.
References btAssert, m_childShapes, m_childTransforms, btGImpactShapeInterface::postUpdate(), btAlignedObjectArray< T >::size(), and transform().
Definition at line 365 of file btGImpactShape.h.
Referenced by addChildShape(), calculateLocalInertia(), getChildAabb(), getChildShape(), getChildTransform(), getNumChildShapes(), and setChildTransform().
Definition at line 364 of file btGImpactShape.h.
Referenced by addChildShape(), calculateLocalInertia(), childrenHasTransform(), getChildAabb(), getChildTransform(), and setChildTransform().
Definition at line 363 of file btGImpactShape.h.
Referenced by btGImpactCompoundShape(), getCompoundPrimitiveManager(), and getPrimitiveManager().