Blender
V3.3
|
Collision Algorithm for GImpact Shapes. More...
#include <btGImpactCollisionAlgorithm.h>
Classes | |
struct | CreateFunc |
Additional Inherited Members | |
![]() | |
virtual | ~btActivatingCollisionAlgorithm () |
![]() | |
btCollisionAlgorithm () | |
btCollisionAlgorithm (const btCollisionAlgorithmConstructionInfo &ci) | |
virtual | ~btCollisionAlgorithm () |
Collision Algorithm for GImpact Shapes.
For register this algorithm in Bullet, proceed as following:
Definition at line 53 of file btGImpactCollisionAlgorithm.h.
btGImpactCollisionAlgorithm::btGImpactCollisionAlgorithm | ( | const btCollisionAlgorithmConstructionInfo & | ci, |
const btCollisionObjectWrapper * | body0Wrap, | ||
const btCollisionObjectWrapper * | body1Wrap | ||
) |
Definition at line 183 of file btGImpactCollisionAlgorithm.cpp.
References m_convex_algorithm, m_manifoldPtr, and NULL.
Referenced by btGImpactCollisionAlgorithm::CreateFunc::CreateCollisionAlgorithm().
|
virtual |
Definition at line 190 of file btGImpactCollisionAlgorithm.cpp.
References clearCache().
|
protected |
Definition at line 195 of file btGImpactCollisionAlgorithm.cpp.
References btManifoldResult::addContactPoint(), checkManifold(), blender::math::distance(), m_part0, m_part1, m_resultOut, m_triface0, m_triface1, normal, point, btManifoldResult::setShapeIdentifiersA(), and btManifoldResult::setShapeIdentifiersB().
Referenced by collide_sat_triangles(), and gimpacttrimeshpart_vs_plane_collision().
|
virtual |
Implements btCollisionAlgorithm.
Definition at line 843 of file btGImpactCollisionAlgorithm.cpp.
|
inlineprotected |
Definition at line 127 of file btGImpactCollisionAlgorithm.h.
References m_convex_algorithm, and newAlgorithm().
Referenced by convex_vs_convex_collision().
|
inlineprotected |
Definition at line 106 of file btGImpactCollisionAlgorithm.h.
References btCollisionObjectWrapper::getCollisionObject(), getLastManifold(), m_resultOut, newContactManifold(), and btManifoldResult::setPersistentManifold().
Referenced by addContactPoint(), and newAlgorithm().
|
inlineprotected |
Definition at line 89 of file btGImpactCollisionAlgorithm.h.
References destroyContactManifolds(), destroyConvexAlgorithm(), m_part0, m_part1, m_triface0, and m_triface1.
Referenced by processCollision(), and ~btGImpactCollisionAlgorithm().
|
protected |
Collision routines
Definition at line 313 of file btGImpactCollisionAlgorithm.cpp.
References convex_vs_convex_collision(), btGImpactMeshShapePart::getBulletTriangle(), btGImpactMeshShapePart::lockChildShapes(), m_triface0, m_triface1, btTriangleShapeEx::overlap_test_conservative(), and btGImpactMeshShapePart::unlockChildShapes().
Referenced by gimpact_vs_gimpact().
|
protected |
Definition at line 347 of file btGImpactCollisionAlgorithm.cpp.
References addContactPoint(), btPrimitiveTriangle::applyTransform(), btTransform, btPrimitiveTriangle::buildTriPlane(), btPrimitiveTriangle::find_triangle_collision_clip_method(), btGImpactShapeInterface::getPrimitiveTriangle(), btCollisionObjectWrapper::getWorldTransform(), btGImpactMeshShapePart::lockChildShapes(), GIM_TRIANGLE_CONTACT::m_penetration_depth, GIM_TRIANGLE_CONTACT::m_point_count, GIM_TRIANGLE_CONTACT::m_points, GIM_TRIANGLE_CONTACT::m_separating_normal, m_triface0, m_triface1, btPrimitiveTriangle::overlap_test_conservative(), and btGImpactMeshShapePart::unlockChildShapes().
Referenced by gimpact_vs_gimpact().
|
protected |
Definition at line 227 of file btGImpactCollisionAlgorithm.cpp.
References checkConvexAlgorithm(), btCollisionObjectWrapper::getCollisionObject(), btCollisionObjectWrapper::getWorldTransform(), m_convex_algorithm, m_dispatchInfo, m_part0, m_part1, m_resultOut, m_triface0, m_triface1, btCollisionAlgorithm::processCollision(), btManifoldResult::setShapeIdentifiersA(), and btManifoldResult::setShapeIdentifiersB().
Referenced by collide_gjk_triangles(), and gimpact_vs_gimpact().
|
inlineprotected |
Definition at line 82 of file btGImpactCollisionAlgorithm.h.
References btCollisionAlgorithm::m_dispatcher, m_manifoldPtr, NULL, and btDispatcher::releaseManifold().
Referenced by clearCache().
|
inlineprotected |
Definition at line 72 of file btGImpactCollisionAlgorithm.h.
References btDispatcher::freeCollisionAlgorithm(), m_convex_algorithm, btCollisionAlgorithm::m_dispatcher, NULL, and btCollisionAlgorithm::~btCollisionAlgorithm().
Referenced by clearCache().
|
inlinevirtual |
Implements btCollisionAlgorithm.
Definition at line 193 of file btGImpactCollisionAlgorithm.h.
References m_manifoldPtr, and btAlignedObjectArray< T >::push_back().
|
inline |
Definition at line 254 of file btGImpactCollisionAlgorithm.h.
References m_triface0.
|
inline |
Definition at line 262 of file btGImpactCollisionAlgorithm.h.
References m_triface1.
|
inlineprotected |
Definition at line 100 of file btGImpactCollisionAlgorithm.h.
References m_manifoldPtr.
Referenced by checkManifold(), newAlgorithm(), and processCollision().
|
inline |
Definition at line 270 of file btGImpactCollisionAlgorithm.h.
References m_part0.
|
inline |
Definition at line 278 of file btGImpactCollisionAlgorithm.h.
References m_part1.
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.
References btCollisionShape, btTransform, btManifoldResult::getBody0Wrap(), btManifoldResult::getBody1Wrap(), btCollisionObjectWrapper::getCollisionObject(), btCollisionObjectWrapper::getWorldTransform(), gimpact_vs_shape(), m_resultOut, btManifoldResult::setBody0Wrap(), and btManifoldResult::setBody1Wrap().
Referenced by gimpact_vs_shape().
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.
References btGImpactTriangleCallback::algorithm, btGImpactTriangleCallback::body0Wrap, btGImpactTriangleCallback::body1Wrap, btTransform, btVector3, btGImpactShapeInterface::getAabb(), btCollisionObjectWrapper::getWorldTransform(), btGImpactTriangleCallback::gimpactshape0, btGImpactTriangleCallback::margin, and btGImpactTriangleCallback::swapped.
Referenced by gimpact_vs_shape().
void btGImpactCollisionAlgorithm::gimpact_vs_gimpact | ( | const btCollisionObjectWrapper * | body0Wrap, |
const btCollisionObjectWrapper * | body1Wrap, | ||
const btGImpactShapeInterface * | shape0, | ||
const btGImpactShapeInterface * | shape1 | ||
) |
Collides two gimpact shapes.
Definition at line 410 of file btGImpactCollisionAlgorithm.cpp.
References btCollisionShape, btTransform, btGImpactShapeInterface::childrenHasTransform(), collide_gjk_triangles(), collide_sat_triangles(), CONST_GIMPACT_TRIMESH_SHAPE, CONST_GIMPACT_TRIMESH_SHAPE_PART, convex_vs_convex_collision(), GIM_ShapeRetriever::getChildShape(), btGImpactShapeInterface::getChildTransform(), btCollisionObjectWrapper::getCollisionObject(), btGImpactShapeInterface::getGImpactShapeType(), btGImpactMeshShape::getMeshPart(), btGImpactMeshShape::getMeshPartCount(), btCollisionObjectWrapper::getWorldTransform(), gimpact_vs_gimpact_find_pairs(), btGImpactShapeInterface::lockChildShapes(), GIM_PAIR::m_index1, GIM_PAIR::m_index2, m_part0, m_part1, m_triface0, m_triface1, btAlignedObjectArray< T >::size(), and btGImpactShapeInterface::unlockChildShapes().
Referenced by processCollision().
|
protected |
Definition at line 242 of file btGImpactCollisionAlgorithm.cpp.
References btAABB, btGImpactQuantizedBvh::find_collision(), btGImpactShapeInterface::getBoxSet(), btGImpactShapeInterface::getChildAabb(), btGImpactShapeInterface::getNumChildShapes(), btGImpactShapeInterface::hasBoxSet(), and btPairSet::push_pair().
Referenced by gimpact_vs_gimpact().
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.
References btCollisionShape, btCompoundShape(), btConcaveShape(), btStaticPlaneShape(), btTransform, btGImpactShapeInterface::childrenHasTransform(), CONST_GIMPACT_TRIMESH_SHAPE, CONST_GIMPACT_TRIMESH_SHAPE_PART, btManifoldResult::getBody0Wrap(), btManifoldResult::getBody1Wrap(), GIM_ShapeRetriever::getChildShape(), btGImpactShapeInterface::getChildTransform(), btCollisionObjectWrapper::getCollisionObject(), btGImpactShapeInterface::getGImpactShapeType(), btGImpactMeshShape::getMeshPart(), btGImpactMeshShape::getMeshPartCount(), btCollisionObjectWrapper::getWorldTransform(), gimpact_vs_compoundshape(), gimpact_vs_concave(), gimpact_vs_shape_find_pairs(), gimpacttrimeshpart_vs_plane_collision(), btGImpactShapeInterface::lockChildShapes(), m_part0, m_part1, m_resultOut, m_triface0, m_triface1, btManifoldResult::setBody0Wrap(), btManifoldResult::setBody1Wrap(), shape_vs_shape_collision(), btAlignedObjectArray< T >::size(), STATIC_PLANE_PROXYTYPE, and btGImpactShapeInterface::unlockChildShapes().
Referenced by gimpact_vs_compoundshape(), processCollision(), and btGImpactTriangleCallback::processTriangle().
|
protected |
Definition at line 276 of file btGImpactCollisionAlgorithm.cpp.
References btGImpactQuantizedBvh::boxQuery(), btAABB, btTransform, btGImpactShapeInterface::getBoxSet(), btGImpactShapeInterface::getChildAabb(), btGImpactShapeInterface::getNumChildShapes(), btGImpactShapeInterface::hasBoxSet(), and btAlignedObjectArray< T >::push_back().
Referenced by gimpact_vs_shape().
|
protected |
Definition at line 670 of file btGImpactCollisionAlgorithm.cpp.
References addContactPoint(), BT_CONST_COLLIDE_PLANE, btAABB, btTransform, btVector3, blender::math::distance(), btPlaneShape::get_plane_equation_transformed(), btGImpactShapeInterface::getAabb(), btGImpactMeshShapePart::getMargin(), btGImpactMeshShapePart::getVertex(), btGImpactMeshShapePart::getVertexCount(), btCollisionObjectWrapper::getWorldTransform(), btGImpactMeshShapePart::lockChildShapes(), and btGImpactMeshShapePart::unlockChildShapes().
Referenced by gimpact_vs_shape().
|
inline |
Definition at line 199 of file btGImpactCollisionAlgorithm.h.
References m_resultOut.
Referenced by btGImpactTriangleCallback::processTriangle().
|
inlineprotected |
Definition at line 117 of file btGImpactCollisionAlgorithm.h.
References BT_CONTACT_POINT_ALGORITHMS, checkManifold(), btDispatcher::findAlgorithm(), getLastManifold(), and btCollisionAlgorithm::m_dispatcher.
Referenced by checkConvexAlgorithm(), and shape_vs_shape_collision().
|
inlineprotected |
Creates a new contact point.
Definition at line 66 of file btGImpactCollisionAlgorithm.h.
References btDispatcher::getNewManifold(), btCollisionAlgorithm::m_dispatcher, and m_manifoldPtr.
Referenced by checkManifold().
|
virtual |
Implements btCollisionAlgorithm.
Definition at line 805 of file btGImpactCollisionAlgorithm.cpp.
References clearCache(), btCollisionObjectWrapper::getCollisionShape(), getLastManifold(), GIMPACT_SHAPE_PROXYTYPE, gimpact_vs_gimpact(), gimpact_vs_shape(), m_dispatchInfo, m_resultOut, and btManifoldResult::refreshContactPoints().
|
static |
Use this function for register the algorithm externally.
Definition at line 851 of file btGImpactCollisionAlgorithm.cpp.
References GIMPACT_SHAPE_PROXYTYPE, MAX_BROADPHASE_COLLISION_TYPES, and btCollisionDispatcher::registerCollisionCreateFunc().
Referenced by RB_dworld_new().
|
inline |
Accessor/Mutator pairs for Part and triangleID.
Definition at line 250 of file btGImpactCollisionAlgorithm.h.
References m_triface0.
Referenced by btGImpactTriangleCallback::processTriangle().
|
inline |
Definition at line 258 of file btGImpactCollisionAlgorithm.h.
References m_triface1.
Referenced by btGImpactTriangleCallback::processTriangle().
|
inline |
Definition at line 266 of file btGImpactCollisionAlgorithm.h.
References m_part0.
Referenced by btGImpactTriangleCallback::processTriangle().
|
inline |
Definition at line 274 of file btGImpactCollisionAlgorithm.h.
References m_part1.
Referenced by btGImpactTriangleCallback::processTriangle().
|
protected |
Definition at line 207 of file btGImpactCollisionAlgorithm.cpp.
References btDispatcher::freeCollisionAlgorithm(), btCollisionAlgorithm::m_dispatcher, m_dispatchInfo, m_part0, m_part1, m_resultOut, m_triface0, m_triface1, newAlgorithm(), btCollisionAlgorithm::processCollision(), btManifoldResult::setShapeIdentifiersA(), btManifoldResult::setShapeIdentifiersB(), and btCollisionAlgorithm::~btCollisionAlgorithm().
Referenced by gimpact_vs_shape().
|
protected |
Definition at line 56 of file btGImpactCollisionAlgorithm.h.
Referenced by btGImpactCollisionAlgorithm(), checkConvexAlgorithm(), convex_vs_convex_collision(), and destroyConvexAlgorithm().
|
protected |
Definition at line 59 of file btGImpactCollisionAlgorithm.h.
Referenced by convex_vs_convex_collision(), processCollision(), and shape_vs_shape_collision().
|
protected |
Definition at line 57 of file btGImpactCollisionAlgorithm.h.
Referenced by btGImpactCollisionAlgorithm(), destroyContactManifolds(), getAllContactManifolds(), getLastManifold(), and newContactManifold().
|
protected |
Definition at line 61 of file btGImpactCollisionAlgorithm.h.
Referenced by addContactPoint(), clearCache(), convex_vs_convex_collision(), getPart0(), gimpact_vs_gimpact(), gimpact_vs_shape(), setPart0(), and shape_vs_shape_collision().
|
protected |
Definition at line 63 of file btGImpactCollisionAlgorithm.h.
Referenced by addContactPoint(), clearCache(), convex_vs_convex_collision(), getPart1(), gimpact_vs_gimpact(), gimpact_vs_shape(), setPart1(), and shape_vs_shape_collision().
|
protected |
Definition at line 58 of file btGImpactCollisionAlgorithm.h.
Referenced by addContactPoint(), checkManifold(), convex_vs_convex_collision(), gimpact_vs_compoundshape(), gimpact_vs_shape(), internalGetResultOut(), processCollision(), and shape_vs_shape_collision().
|
protected |
Definition at line 60 of file btGImpactCollisionAlgorithm.h.
Referenced by addContactPoint(), clearCache(), collide_gjk_triangles(), collide_sat_triangles(), convex_vs_convex_collision(), getFace0(), gimpact_vs_gimpact(), gimpact_vs_shape(), setFace0(), and shape_vs_shape_collision().
|
protected |
Definition at line 62 of file btGImpactCollisionAlgorithm.h.
Referenced by addContactPoint(), clearCache(), collide_gjk_triangles(), collide_sat_triangles(), convex_vs_convex_collision(), getFace1(), gimpact_vs_gimpact(), gimpact_vs_shape(), setFace1(), and shape_vs_shape_collision().