Blender V2.61 - r43446
Public Member Functions | Protected Member Functions | Protected Attributes

btGImpactMeshShape Class Reference

This class manages a mesh supplied by the btStridingMeshInterface interface. More...

#include <btGImpactShape.h>

Inheritance diagram for btGImpactMeshShape:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 btGImpactMeshShape (btStridingMeshInterface *meshInterface)
virtual ~btGImpactMeshShape ()
btStridingMeshInterfacegetMeshInterface ()
const btStridingMeshInterfacegetMeshInterface () const
int getMeshPartCount () const
btGImpactMeshShapePartgetMeshPart (int index)
const btGImpactMeshShapePartgetMeshPart (int index) const
virtual void setLocalScaling (const btVector3 &scaling)
virtual void setMargin (btScalar margin)
virtual void postUpdate ()
 Tells to this object that is needed to refit all the meshes.
virtual void calculateLocalInertia (btScalar mass, btVector3 &inertia) const
virtual const
btPrimitiveManagerBase
getPrimitiveManager () const
 Obtains the primitive manager.
virtual int getNumChildShapes () const
 Gets the number of children.
virtual bool childrenHasTransform () const
 if true, then its children must get transforms.
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 lockChildShapes () const
 call when reading child shapes
virtual void unlockChildShapes () const
 Base method for determinig which kind of GIMPACT shape we get.
virtual void getChildAabb (int child_index, const btTransform &t, btVector3 &aabbMin, btVector3 &aabbMax) const
 Retrieves the bound from a child.
virtual btCollisionShapegetChildShape (int index)
 Gets the children.
virtual const btCollisionShapegetChildShape (int index) const
 Gets the child.
virtual btTransform getChildTransform (int index) const
 Gets the children transform.
virtual void setChildTransform (int index, const btTransform &transform)
 Sets the children transform.
virtual eGIMPACT_SHAPE_TYPE getGImpactShapeType () const
 Base method for determinig which kind of GIMPACT shape we get.
virtual const char * getName () const
virtual void rayTest (const btVector3 &rayFrom, const btVector3 &rayTo, btCollisionWorld::RayResultCallback &resultCallback) const
 virtual method for ray collision
virtual void processAllTriangles (btTriangleCallback *callback, const btVector3 &aabbMin, const btVector3 &aabbMax) const
 Function for retrieve triangles.
virtual int calculateSerializeBufferSize () const
virtual const char * serialize (void *dataBuffer, btSerializer *serializer) const
 fills the dataBuffer and returns the struct name (and 0 on failure)

Protected Member Functions

void buildMeshParts (btStridingMeshInterface *meshInterface)
virtual void calcLocalAABB ()
 use this function for perfofm refit in bounding boxes

Protected Attributes

btAlignedObjectArray
< btGImpactMeshShapePart * > 
m_mesh_parts

Detailed Description

This class manages a mesh supplied by the btStridingMeshInterface interface.

Set of btGImpactMeshShapePart parts

Definition at line 899 of file btGImpactShape.h.


Constructor & Destructor Documentation

btGImpactMeshShape::btGImpactMeshShape ( btStridingMeshInterface meshInterface) [inline]

Definition at line 927 of file btGImpactShape.h.

References buildMeshParts().

virtual btGImpactMeshShape::~btGImpactMeshShape ( ) [inline, virtual]

Member Function Documentation

void btGImpactMeshShape::buildMeshParts ( btStridingMeshInterface meshInterface) [inline, protected]
virtual void btGImpactMeshShape::calcLocalAABB ( ) [inline, protected, virtual]

use this function for perfofm refit in bounding boxes

Reimplemented from btGImpactShapeInterface.

Definition at line 915 of file btGImpactShape.h.

References btGImpactShapeInterface::getLocalBox(), i, btGImpactShapeInterface::m_localAABB, m_mesh_parts, and btAlignedObjectArray< T >::size().

void btGImpactMeshShape::calculateLocalInertia ( btScalar  mass,
btVector3 &  inertia 
) const [virtual]
SIMD_FORCE_INLINE int btGImpactMeshShape::calculateSerializeBufferSize ( ) const [virtual]

Reimplemented from btCollisionShape.

Definition at line 1165 of file btGImpactShape.h.

virtual bool btGImpactMeshShape::childrenHasTransform ( ) const [inline, virtual]

if true, then its children must get transforms.

Implements btGImpactShapeInterface.

Definition at line 1034 of file btGImpactShape.h.

References btAssert.

virtual void btGImpactMeshShape::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 1060 of file btGImpactShape.h.

References btAssert.

virtual void btGImpactMeshShape::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 1054 of file btGImpactShape.h.

References btAssert.

virtual void btGImpactMeshShape::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 1083 of file btGImpactShape.h.

References btAssert.

virtual btCollisionShape* btGImpactMeshShape::getChildShape ( int  index) [inline, virtual]

Gets the children.

Implements btGImpactShapeInterface.

Definition at line 1090 of file btGImpactShape.h.

References btAssert, and NULL.

virtual const btCollisionShape* btGImpactMeshShape::getChildShape ( int  index) const [inline, virtual]

Gets the child.

Implements btGImpactShapeInterface.

Definition at line 1099 of file btGImpactShape.h.

References btAssert, and NULL.

virtual btTransform btGImpactMeshShape::getChildTransform ( int  index) const [inline, virtual]

Gets the children transform.

Implements btGImpactShapeInterface.

Definition at line 1107 of file btGImpactShape.h.

References btAssert.

virtual eGIMPACT_SHAPE_TYPE btGImpactMeshShape::getGImpactShapeType ( ) const [inline, virtual]

Base method for determinig which kind of GIMPACT shape we get.

Subshape member functions

Implements btGImpactShapeInterface.

Definition at line 1125 of file btGImpactShape.h.

References CONST_GIMPACT_TRIMESH_SHAPE.

Referenced by serialize().

const btStridingMeshInterface* btGImpactMeshShape::getMeshInterface ( ) const [inline]

Definition at line 950 of file btGImpactShape.h.

btStridingMeshInterface* btGImpactMeshShape::getMeshInterface ( ) [inline]

Definition at line 945 of file btGImpactShape.h.

btGImpactMeshShapePart* btGImpactMeshShape::getMeshPart ( int  index) [inline]
const btGImpactMeshShapePart* btGImpactMeshShape::getMeshPart ( int  index) const [inline]

Definition at line 967 of file btGImpactShape.h.

References m_mesh_parts.

int btGImpactMeshShape::getMeshPartCount ( ) const [inline]
virtual const char* btGImpactMeshShape::getName ( void  ) const [inline, virtual]

Implements btCollisionShape.

Definition at line 1131 of file btGImpactShape.h.

virtual int btGImpactMeshShape::getNumChildShapes ( ) const [inline, virtual]

Gets the number of children.

Implements btGImpactShapeInterface.

Definition at line 1026 of file btGImpactShape.h.

References btAssert.

virtual const btPrimitiveManagerBase* btGImpactMeshShape::getPrimitiveManager ( ) const [inline, virtual]

Obtains the primitive manager.

Implements btGImpactShapeInterface.

Definition at line 1018 of file btGImpactShape.h.

References btAssert, and NULL.

virtual void btGImpactMeshShape::lockChildShapes ( ) const [inline, virtual]

call when reading child shapes

Reimplemented from btGImpactShapeInterface.

Definition at line 1067 of file btGImpactShape.h.

References btAssert.

virtual bool btGImpactMeshShape::needsRetrieveTetrahedrons ( ) const [inline, virtual]

Determines if this shape has tetrahedrons.

Implements btGImpactShapeInterface.

Definition at line 1048 of file btGImpactShape.h.

References btAssert.

virtual bool btGImpactMeshShape::needsRetrieveTriangles ( ) const [inline, virtual]

Determines if this shape has triangles.

Implements btGImpactShapeInterface.

Definition at line 1041 of file btGImpactShape.h.

References btAssert.

virtual void btGImpactMeshShape::postUpdate ( ) [inline, virtual]

Tells to this object that is needed to refit all the meshes.

Reimplemented from btGImpactShapeInterface.

Definition at line 1002 of file btGImpactShape.h.

References i, m_mesh_parts, btGImpactShapeInterface::m_needs_update, btGImpactShapeInterface::postUpdate(), and btAlignedObjectArray< T >::size().

void btGImpactMeshShape::processAllTriangles ( btTriangleCallback callback,
const btVector3 &  aabbMin,
const btVector3 &  aabbMax 
) const [virtual]

Function for retrieve triangles.

It gives the triangles in local space

Reimplemented from btGImpactShapeInterface.

Definition at line 176 of file btGImpactShape.cpp.

References i, m_mesh_parts, and btAlignedObjectArray< T >::size().

void btGImpactMeshShape::rayTest ( const btVector3 &  rayFrom,
const btVector3 &  rayTo,
btCollisionWorld::RayResultCallback resultCallback 
) const [virtual]

virtual method for ray collision

Reimplemented from btGImpactShapeInterface.

Definition at line 143 of file btGImpactShape.cpp.

const char * btGImpactMeshShape::serialize ( void *  dataBuffer,
btSerializer serializer 
) const [virtual]
virtual void btGImpactMeshShape::setChildTransform ( int  index,
const btTransform transform 
) [inline, virtual]

Sets the children transform.

Postcondition:
You must call updateBound() for update the box set.

Implements btGImpactShapeInterface.

Definition at line 1118 of file btGImpactShape.h.

References btAssert.

virtual void btGImpactMeshShape::setLocalScaling ( const btVector3 &  scaling) [inline, virtual]
virtual void btGImpactMeshShape::setMargin ( btScalar  margin) [inline, virtual]
virtual void btGImpactMeshShape::unlockChildShapes ( ) const [inline, virtual]

Base method for determinig which kind of GIMPACT shape we get.

Subshape member functions

Reimplemented from btGImpactShapeInterface.

Definition at line 1072 of file btGImpactShape.h.

References btAssert.


Member Data Documentation


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