24 #ifndef BT_GIMPACT_BVH_CONCAVE_COLLISION_ALGORITHM_H
25 #define BT_GIMPACT_BVH_CONCAVE_COLLISION_ALGORITHM_H
126 return convex_algorithm ;
152 const int * pairs,
int pair_count);
158 const int * pairs,
int pair_count);
229 #ifdef TRI_COLLISION_PROFILING
230 static float getAverageTreeCollisionTime();
234 static float getAverageTriangleCollisionTime();
235 #endif //TRI_COLLISION_PROFILING
306 #define GIMPACT_VS_PLANE_COLLISION 1
310 #endif //BT_GIMPACT_BVH_CONCAVE_COLLISION_ALGORITHM_H
virtual void releaseManifold(btPersistentManifold *manifold)=0
btPersistentManifold is a contact point cache, it stays persistent as long as objects are overlapping...
btPersistentManifold * newContactManifold(const btCollisionObject *body0, const btCollisionObject *body1)
Creates a new contact point.
void push_back(const T &_Val)
virtual btCollisionAlgorithm * findAlgorithm(const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, btPersistentManifold *sharedManifold=0)=0
void collide_gjk_triangles(const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btGImpactMeshShapePart *shape0, const btGImpactMeshShapePart *shape1, const int *pairs, int pair_count)
Collision routines.
btPersistentManifold * getLastManifold()
void setPersistentManifold(btPersistentManifold *manifoldPtr)
btPersistentManifold * m_manifoldPtr
This class is not enabled yet (work-in-progress) to more aggressively activate objects.
virtual ~btGImpactCollisionAlgorithm()
The btCollisionShape class provides an interface for collision shapes that can be shared among btColl...
void checkManifold(const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap)
#define SIMD_FORCE_INLINE
btCollisionDispatcher supports algorithms that handle ConvexConvex and ConvexConcave collision pairs...
virtual ~btCollisionAlgorithm()
btManifoldResult is a helper class to manage contact results.
void gimpact_vs_shape_find_pairs(const btTransform &trans0, const btTransform &trans1, const btGImpactShapeInterface *shape0, const btCollisionShape *shape1, btAlignedObjectArray< int > &collided_primitives)
btDispatcher * m_dispatcher
void gimpact_vs_concave(const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btGImpactShapeInterface *shape0, const btConcaveShape *shape1, bool swapped)
void gimpact_vs_gimpact(const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btGImpactShapeInterface *shape0, const btGImpactShapeInterface *shape1)
Collides two gimpact shapes.
void gimpact_vs_compoundshape(const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btGImpactShapeInterface *shape0, const btCompoundShape *shape1, bool swapped)
virtual btCollisionAlgorithm * CreateCollisionAlgorithm(btCollisionAlgorithmConstructionInfo &ci, const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap)
Base class for gimpact shapes.
This class manages a sub part of a mesh supplied by the btStridingMeshInterface interface.
virtual void * allocateCollisionAlgorithm(int size)=0
btGImpactCollisionAlgorithm(const btCollisionAlgorithmConstructionInfo &ci, const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap)
void convex_vs_convex_collision(const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btCollisionShape *shape0, const btCollisionShape *shape1)
Used by the btCollisionDispatcher to register and create instances for btCollisionAlgorithm.
btCollisionObject can be used to manage collision detection objects.
virtual void freeCollisionAlgorithm(void *ptr)=0
virtual btPersistentManifold * getNewManifold(const btCollisionObject *b0, const btCollisionObject *b1)=0
void gimpacttrimeshpart_vs_plane_collision(const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btGImpactMeshShapePart *shape0, const btStaticPlaneShape *shape1, bool swapped)
btVector3 can be used to represent 3D points and vectors.
void destroyConvexAlgorithm()
static void registerAlgorithm(btCollisionDispatcher *dispatcher)
Use this function for register the algorithm externally.
void gimpact_vs_gimpact_find_pairs(const btTransform &trans0, const btTransform &trans1, const btGImpactShapeInterface *shape0, const btGImpactShapeInterface *shape1, btPairSet &pairset)
The btConcaveShape class provides an interface for non-moving (static) concave shapes.
btScalar calculateTimeOfImpact(btCollisionObject *body0, btCollisionObject *body1, const btDispatcherInfo &dispatchInfo, btManifoldResult *resultOut)
btCollisionAlgorithm * m_convex_algorithm
void setFace0(int value)
Accessor/Mutator pairs for Part and triangleID.
btCollisionAlgorithm * newAlgorithm(const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap)
const btDispatcherInfo * m_dispatchInfo
void destroyContactManifolds()
The btCompoundShape allows to store multiple other btCollisionShapes This allows for moving concave c...
void shape_vs_shape_collision(const btCollisionObjectWrapper *body0, const btCollisionObjectWrapper *body1, const btCollisionShape *shape0, const btCollisionShape *shape1)
btDispatcher * m_dispatcher1
The btStaticPlaneShape simulates an infinite non-moving (static) collision plane. ...
virtual void getAllContactManifolds(btManifoldArray &manifoldArray)
void collide_sat_triangles(const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btGImpactMeshShapePart *shape0, const btGImpactMeshShapePart *shape1, const int *pairs, int pair_count)
The btDispatcher interface class can be used in combination with broadphase to dispatch calculations ...
btManifoldResult * internalGetResultOut()
btManifoldResult * m_resultOut
btCollisionAlgorithm is an collision interface that is compatible with the Broadphase and btDispatche...
Collision Algorithm for GImpact Shapes.
void addContactPoint(const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btVector3 &point, const btVector3 &normal, btScalar distance)
virtual void processCollision(const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btDispatcherInfo &dispatchInfo, btManifoldResult *resultOut)
float btScalar
The btScalar type abstracts floating point numbers, to easily switch between double and single floati...
void gimpact_vs_shape(const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btGImpactShapeInterface *shape0, const btCollisionShape *shape1, bool swapped)
void checkConvexAlgorithm(const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap)
const btCollisionObject * getCollisionObject() const