Bullet Collision Detection & Physics Library
Classes | Protected Member Functions | Protected Attributes | List of all members
btGImpactCollisionAlgorithm Class Reference

Collision Algorithm for GImpact Shapes. More...

#include <btGImpactCollisionAlgorithm.h>

Inheritance diagram for btGImpactCollisionAlgorithm:
Inheritance graph
[legend]
Collaboration diagram for btGImpactCollisionAlgorithm:
Collaboration graph
[legend]

Classes

struct  CreateFunc
 

Protected Member Functions

btPersistentManifoldnewContactManifold (const btCollisionObject *body0, const btCollisionObject *body1)
 Creates a new contact point. More...
 
void destroyConvexAlgorithm ()
 
void destroyContactManifolds ()
 
void clearCache ()
 
btPersistentManifoldgetLastManifold ()
 
void checkManifold (const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap)
 
btCollisionAlgorithmnewAlgorithm (const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap)
 
void checkConvexAlgorithm (const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap)
 
void addContactPoint (const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btVector3 &point, const btVector3 &normal, btScalar distance)
 
- Protected Member Functions inherited from btActivatingCollisionAlgorithm
 btActivatingCollisionAlgorithm (const btCollisionAlgorithmConstructionInfo &ci)
 
 btActivatingCollisionAlgorithm (const btCollisionAlgorithmConstructionInfo &ci, const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap)
 

Protected Attributes

btCollisionAlgorithmm_convex_algorithm
 
btPersistentManifoldm_manifoldPtr
 
btManifoldResultm_resultOut
 
const btDispatcherInfom_dispatchInfo
 
int m_triface0
 
int m_part0
 
int m_triface1
 
int m_part1
 
- Protected Attributes inherited from btCollisionAlgorithm
btDispatcherm_dispatcher
 
void collide_gjk_triangles (const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btGImpactMeshShapePart *shape0, const btGImpactMeshShapePart *shape1, const int *pairs, int pair_count)
 Collision routines. More...
 
void collide_sat_triangles (const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btGImpactMeshShapePart *shape0, const btGImpactMeshShapePart *shape1, const int *pairs, int pair_count)
 
void shape_vs_shape_collision (const btCollisionObjectWrapper *body0, const btCollisionObjectWrapper *body1, const btCollisionShape *shape0, const btCollisionShape *shape1)
 
void convex_vs_convex_collision (const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btCollisionShape *shape0, const btCollisionShape *shape1)
 
void gimpact_vs_gimpact_find_pairs (const btTransform &trans0, const btTransform &trans1, const btGImpactShapeInterface *shape0, const btGImpactShapeInterface *shape1, btPairSet &pairset)
 
void gimpact_vs_shape_find_pairs (const btTransform &trans0, const btTransform &trans1, const btGImpactShapeInterface *shape0, const btCollisionShape *shape1, btAlignedObjectArray< int > &collided_primitives)
 
void gimpacttrimeshpart_vs_plane_collision (const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btGImpactMeshShapePart *shape0, const btStaticPlaneShape *shape1, bool swapped)
 
 btGImpactCollisionAlgorithm (const btCollisionAlgorithmConstructionInfo &ci, const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap)
 
virtual ~btGImpactCollisionAlgorithm ()
 
virtual void processCollision (const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btDispatcherInfo &dispatchInfo, btManifoldResult *resultOut)
 
btScalar calculateTimeOfImpact (btCollisionObject *body0, btCollisionObject *body1, const btDispatcherInfo &dispatchInfo, btManifoldResult *resultOut)
 
virtual void getAllContactManifolds (btManifoldArray &manifoldArray)
 
btManifoldResultinternalGetResultOut ()
 
void gimpact_vs_gimpact (const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btGImpactShapeInterface *shape0, const btGImpactShapeInterface *shape1)
 Collides two gimpact shapes. More...
 
void gimpact_vs_shape (const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btGImpactShapeInterface *shape0, const btCollisionShape *shape1, bool swapped)
 
void gimpact_vs_compoundshape (const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btGImpactShapeInterface *shape0, const btCompoundShape *shape1, bool swapped)
 
void gimpact_vs_concave (const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btGImpactShapeInterface *shape0, const btConcaveShape *shape1, bool swapped)
 
void setFace0 (int value)
 Accessor/Mutator pairs for Part and triangleID. More...
 
int getFace0 ()
 
void setFace1 (int value)
 
int getFace1 ()
 
void setPart0 (int value)
 
int getPart0 ()
 
void setPart1 (int value)
 
int getPart1 ()
 
static void registerAlgorithm (btCollisionDispatcher *dispatcher)
 Use this function for register the algorithm externally. More...
 

Additional Inherited Members

- Public Member Functions inherited from btActivatingCollisionAlgorithm
virtual ~btActivatingCollisionAlgorithm ()
 
- Public Member Functions inherited from btCollisionAlgorithm
 btCollisionAlgorithm ()
 
 btCollisionAlgorithm (const btCollisionAlgorithmConstructionInfo &ci)
 
virtual ~btCollisionAlgorithm ()
 
virtual void processCollision (const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btDispatcherInfo &dispatchInfo, btManifoldResult *resultOut)=0
 
virtual btScalar calculateTimeOfImpact (btCollisionObject *body0, btCollisionObject *body1, const btDispatcherInfo &dispatchInfo, btManifoldResult *resultOut)=0
 
virtual void getAllContactManifolds (btManifoldArray &manifoldArray)=0
 

Detailed Description

Collision Algorithm for GImpact Shapes.

For register this algorithm in Bullet, proceed as following:

btCollisionDispatcher * dispatcher = static_cast<btCollisionDispatcher *>(m_dynamicsWorld ->getDispatcher());
btCollisionDispatcher supports algorithms that handle ConvexConvex and ConvexConcave collision pairs.
static void registerAlgorithm(btCollisionDispatcher *dispatcher)
Use this function for register the algorithm externally.

Definition at line 53 of file btGImpactCollisionAlgorithm.h.

Constructor & Destructor Documentation

◆ btGImpactCollisionAlgorithm()

btGImpactCollisionAlgorithm::btGImpactCollisionAlgorithm ( const btCollisionAlgorithmConstructionInfo ci,
const btCollisionObjectWrapper body0Wrap,
const btCollisionObjectWrapper body1Wrap 
)

Definition at line 183 of file btGImpactCollisionAlgorithm.cpp.

◆ ~btGImpactCollisionAlgorithm()

btGImpactCollisionAlgorithm::~btGImpactCollisionAlgorithm ( )
virtual

Definition at line 190 of file btGImpactCollisionAlgorithm.cpp.

Member Function Documentation

◆ addContactPoint()

void btGImpactCollisionAlgorithm::addContactPoint ( const btCollisionObjectWrapper body0Wrap,
const btCollisionObjectWrapper body1Wrap,
const btVector3 point,
const btVector3 normal,
btScalar  distance 
)
protected

Definition at line 195 of file btGImpactCollisionAlgorithm.cpp.

◆ calculateTimeOfImpact()

btScalar btGImpactCollisionAlgorithm::calculateTimeOfImpact ( btCollisionObject body0,
btCollisionObject body1,
const btDispatcherInfo dispatchInfo,
btManifoldResult resultOut 
)
virtual

Implements btCollisionAlgorithm.

Definition at line 843 of file btGImpactCollisionAlgorithm.cpp.

◆ checkConvexAlgorithm()

void btGImpactCollisionAlgorithm::checkConvexAlgorithm ( const btCollisionObjectWrapper body0Wrap,
const btCollisionObjectWrapper body1Wrap 
)
inlineprotected

Definition at line 127 of file btGImpactCollisionAlgorithm.h.

◆ checkManifold()

void btGImpactCollisionAlgorithm::checkManifold ( const btCollisionObjectWrapper body0Wrap,
const btCollisionObjectWrapper body1Wrap 
)
inlineprotected

Definition at line 106 of file btGImpactCollisionAlgorithm.h.

◆ clearCache()

void btGImpactCollisionAlgorithm::clearCache ( )
inlineprotected

Definition at line 89 of file btGImpactCollisionAlgorithm.h.

◆ collide_gjk_triangles()

void btGImpactCollisionAlgorithm::collide_gjk_triangles ( const btCollisionObjectWrapper body0Wrap,
const btCollisionObjectWrapper body1Wrap,
const btGImpactMeshShapePart shape0,
const btGImpactMeshShapePart shape1,
const int *  pairs,
int  pair_count 
)
protected

Collision routines.

Definition at line 313 of file btGImpactCollisionAlgorithm.cpp.

◆ collide_sat_triangles()

void btGImpactCollisionAlgorithm::collide_sat_triangles ( const btCollisionObjectWrapper body0Wrap,
const btCollisionObjectWrapper body1Wrap,
const btGImpactMeshShapePart shape0,
const btGImpactMeshShapePart shape1,
const int *  pairs,
int  pair_count 
)
protected

Definition at line 347 of file btGImpactCollisionAlgorithm.cpp.

◆ convex_vs_convex_collision()

void btGImpactCollisionAlgorithm::convex_vs_convex_collision ( const btCollisionObjectWrapper body0Wrap,
const btCollisionObjectWrapper body1Wrap,
const btCollisionShape shape0,
const btCollisionShape shape1 
)
protected

Definition at line 227 of file btGImpactCollisionAlgorithm.cpp.

◆ destroyContactManifolds()

void btGImpactCollisionAlgorithm::destroyContactManifolds ( )
inlineprotected

Definition at line 82 of file btGImpactCollisionAlgorithm.h.

◆ destroyConvexAlgorithm()

void btGImpactCollisionAlgorithm::destroyConvexAlgorithm ( )
inlineprotected

Definition at line 72 of file btGImpactCollisionAlgorithm.h.

◆ getAllContactManifolds()

virtual void btGImpactCollisionAlgorithm::getAllContactManifolds ( btManifoldArray manifoldArray)
inlinevirtual

Implements btCollisionAlgorithm.

Definition at line 193 of file btGImpactCollisionAlgorithm.h.

◆ getFace0()

int btGImpactCollisionAlgorithm::getFace0 ( )
inline

Definition at line 254 of file btGImpactCollisionAlgorithm.h.

◆ getFace1()

int btGImpactCollisionAlgorithm::getFace1 ( )
inline

Definition at line 262 of file btGImpactCollisionAlgorithm.h.

◆ getLastManifold()

btPersistentManifold * btGImpactCollisionAlgorithm::getLastManifold ( )
inlineprotected

Definition at line 100 of file btGImpactCollisionAlgorithm.h.

◆ getPart0()

int btGImpactCollisionAlgorithm::getPart0 ( )
inline

Definition at line 270 of file btGImpactCollisionAlgorithm.h.

◆ getPart1()

int btGImpactCollisionAlgorithm::getPart1 ( )
inline

Definition at line 278 of file btGImpactCollisionAlgorithm.h.

◆ gimpact_vs_compoundshape()

void btGImpactCollisionAlgorithm::gimpact_vs_compoundshape ( const btCollisionObjectWrapper body0Wrap,
const btCollisionObjectWrapper body1Wrap,
const btGImpactShapeInterface shape0,
const btCompoundShape shape1,
bool  swapped 
)

Definition at line 629 of file btGImpactCollisionAlgorithm.cpp.

◆ gimpact_vs_concave()

void btGImpactCollisionAlgorithm::gimpact_vs_concave ( const btCollisionObjectWrapper body0Wrap,
const btCollisionObjectWrapper body1Wrap,
const btGImpactShapeInterface shape0,
const btConcaveShape shape1,
bool  swapped 
)

Definition at line 779 of file btGImpactCollisionAlgorithm.cpp.

◆ gimpact_vs_gimpact()

void btGImpactCollisionAlgorithm::gimpact_vs_gimpact ( const btCollisionObjectWrapper body0Wrap,
const btCollisionObjectWrapper body1Wrap,
const btGImpactShapeInterface shape0,
const btGImpactShapeInterface shape1 
)

Collides two gimpact shapes.

Precondition
shape0 and shape1 couldn't be btGImpactMeshShape objects

Definition at line 410 of file btGImpactCollisionAlgorithm.cpp.

◆ gimpact_vs_gimpact_find_pairs()

void btGImpactCollisionAlgorithm::gimpact_vs_gimpact_find_pairs ( const btTransform trans0,
const btTransform trans1,
const btGImpactShapeInterface shape0,
const btGImpactShapeInterface shape1,
btPairSet pairset 
)
protected

Definition at line 242 of file btGImpactCollisionAlgorithm.cpp.

◆ gimpact_vs_shape()

void btGImpactCollisionAlgorithm::gimpact_vs_shape ( const btCollisionObjectWrapper body0Wrap,
const btCollisionObjectWrapper body1Wrap,
const btGImpactShapeInterface shape0,
const btCollisionShape shape1,
bool  swapped 
)

Definition at line 510 of file btGImpactCollisionAlgorithm.cpp.

◆ gimpact_vs_shape_find_pairs()

void btGImpactCollisionAlgorithm::gimpact_vs_shape_find_pairs ( const btTransform trans0,
const btTransform trans1,
const btGImpactShapeInterface shape0,
const btCollisionShape shape1,
btAlignedObjectArray< int > &  collided_primitives 
)
protected

Definition at line 276 of file btGImpactCollisionAlgorithm.cpp.

◆ gimpacttrimeshpart_vs_plane_collision()

void btGImpactCollisionAlgorithm::gimpacttrimeshpart_vs_plane_collision ( const btCollisionObjectWrapper body0Wrap,
const btCollisionObjectWrapper body1Wrap,
const btGImpactMeshShapePart shape0,
const btStaticPlaneShape shape1,
bool  swapped 
)
protected

Definition at line 670 of file btGImpactCollisionAlgorithm.cpp.

◆ internalGetResultOut()

btManifoldResult * btGImpactCollisionAlgorithm::internalGetResultOut ( )
inline

Definition at line 199 of file btGImpactCollisionAlgorithm.h.

◆ newAlgorithm()

btCollisionAlgorithm * btGImpactCollisionAlgorithm::newAlgorithm ( const btCollisionObjectWrapper body0Wrap,
const btCollisionObjectWrapper body1Wrap 
)
inlineprotected

Definition at line 117 of file btGImpactCollisionAlgorithm.h.

◆ newContactManifold()

btPersistentManifold * btGImpactCollisionAlgorithm::newContactManifold ( const btCollisionObject body0,
const btCollisionObject body1 
)
inlineprotected

Creates a new contact point.

Definition at line 66 of file btGImpactCollisionAlgorithm.h.

◆ processCollision()

void btGImpactCollisionAlgorithm::processCollision ( const btCollisionObjectWrapper body0Wrap,
const btCollisionObjectWrapper body1Wrap,
const btDispatcherInfo dispatchInfo,
btManifoldResult resultOut 
)
virtual

Implements btCollisionAlgorithm.

Definition at line 805 of file btGImpactCollisionAlgorithm.cpp.

◆ registerAlgorithm()

void btGImpactCollisionAlgorithm::registerAlgorithm ( btCollisionDispatcher dispatcher)
static

Use this function for register the algorithm externally.

Definition at line 851 of file btGImpactCollisionAlgorithm.cpp.

◆ setFace0()

void btGImpactCollisionAlgorithm::setFace0 ( int  value)
inline

Accessor/Mutator pairs for Part and triangleID.

Definition at line 250 of file btGImpactCollisionAlgorithm.h.

◆ setFace1()

void btGImpactCollisionAlgorithm::setFace1 ( int  value)
inline

Definition at line 258 of file btGImpactCollisionAlgorithm.h.

◆ setPart0()

void btGImpactCollisionAlgorithm::setPart0 ( int  value)
inline

Definition at line 266 of file btGImpactCollisionAlgorithm.h.

◆ setPart1()

void btGImpactCollisionAlgorithm::setPart1 ( int  value)
inline

Definition at line 274 of file btGImpactCollisionAlgorithm.h.

◆ shape_vs_shape_collision()

void btGImpactCollisionAlgorithm::shape_vs_shape_collision ( const btCollisionObjectWrapper body0,
const btCollisionObjectWrapper body1,
const btCollisionShape shape0,
const btCollisionShape shape1 
)
protected

Definition at line 207 of file btGImpactCollisionAlgorithm.cpp.

Member Data Documentation

◆ m_convex_algorithm

btCollisionAlgorithm* btGImpactCollisionAlgorithm::m_convex_algorithm
protected

Definition at line 56 of file btGImpactCollisionAlgorithm.h.

◆ m_dispatchInfo

const btDispatcherInfo* btGImpactCollisionAlgorithm::m_dispatchInfo
protected

Definition at line 59 of file btGImpactCollisionAlgorithm.h.

◆ m_manifoldPtr

btPersistentManifold* btGImpactCollisionAlgorithm::m_manifoldPtr
protected

Definition at line 57 of file btGImpactCollisionAlgorithm.h.

◆ m_part0

int btGImpactCollisionAlgorithm::m_part0
protected

Definition at line 61 of file btGImpactCollisionAlgorithm.h.

◆ m_part1

int btGImpactCollisionAlgorithm::m_part1
protected

Definition at line 63 of file btGImpactCollisionAlgorithm.h.

◆ m_resultOut

btManifoldResult* btGImpactCollisionAlgorithm::m_resultOut
protected

Definition at line 58 of file btGImpactCollisionAlgorithm.h.

◆ m_triface0

int btGImpactCollisionAlgorithm::m_triface0
protected

Definition at line 60 of file btGImpactCollisionAlgorithm.h.

◆ m_triface1

int btGImpactCollisionAlgorithm::m_triface1
protected

Definition at line 62 of file btGImpactCollisionAlgorithm.h.


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