Bullet Collision Detection & Physics Library: btSphereSphereCollisionAlgorithm Class Reference

Bullet Collision Detection & Physics Library

- Main Page
- Namespaces
- Classes
- Files

- Class List
- Class Hierarchy
- Class Members

Classes | Public Member Functions | Private Attributes | List of all members
btSphereSphereCollisionAlgorithm Class Reference

btSphereSphereCollisionAlgorithm provides sphere-sphere collision detection. More...

`#include <btSphereSphereCollisionAlgorithm.h>`

Inheritance diagram for btSphereSphereCollisionAlgorithm:
[legend]
Collaboration diagram for btSphereSphereCollisionAlgorithm:
[legend]

## Classes
struct | CreateFunc

## Public Member Functions
| btSphereSphereCollisionAlgorithm (btPersistentManifold *mf, const btCollisionAlgorithmConstructionInfo &ci, const btCollisionObjectWrapper *col0Wrap, const btCollisionObjectWrapper *col1Wrap)
| btSphereSphereCollisionAlgorithm (const btCollisionAlgorithmConstructionInfo &ci)
virtual void | processCollision (const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap, const btDispatcherInfo &dispatchInfo, btManifoldResult *resultOut)
virtual btScalar | calculateTimeOfImpact (btCollisionObject *body0, btCollisionObject *body1, const btDispatcherInfo &dispatchInfo, btManifoldResult *resultOut)
virtual void | getAllContactManifolds (btManifoldArray &manifoldArray)
virtual | ~btSphereSphereCollisionAlgorithm ()
Public Member Functions inherited from btActivatingCollisionAlgorithm
virtual | ~btActivatingCollisionAlgorithm ()
Public Member Functions inherited from btCollisionAlgorithm
| btCollisionAlgorithm ()
| btCollisionAlgorithm (const btCollisionAlgorithmConstructionInfo &ci)
virtual | ~btCollisionAlgorithm ()

## Private Attributes
bool | m_ownManifold
btPersistentManifold * | m_manifoldPtr

## Additional Inherited Members
Protected Member Functions inherited from btActivatingCollisionAlgorithm
| btActivatingCollisionAlgorithm (const btCollisionAlgorithmConstructionInfo &ci)
| btActivatingCollisionAlgorithm (const btCollisionAlgorithmConstructionInfo &ci, const btCollisionObjectWrapper *body0Wrap, const btCollisionObjectWrapper *body1Wrap)
Protected Attributes inherited from btCollisionAlgorithm
btDispatcher * | m_dispatcher

## Detailed Description

btSphereSphereCollisionAlgorithm provides sphere-sphere collision detection.

Other features are frame-coherency (persistent data) and collision response. Also provides the most basic sample for custom/user btCollisionAlgorithm

Definition at line 29 of file btSphereSphereCollisionAlgorithm.h.

## Constructor & Destructor Documentation

## ◆ btSphereSphereCollisionAlgorithm() [1/2]

btSphereSphereCollisionAlgorithm::btSphereSphereCollisionAlgorithm | ( | btPersistentManifold * | mf,
|  | const btCollisionAlgorithmConstructionInfo & | ci,
|  | const btCollisionObjectWrapper * | col0Wrap,
|  | const btCollisionObjectWrapper * | col1Wrap )

Definition at line 23 of file btSphereSphereCollisionAlgorithm.cpp.

## ◆ btSphereSphereCollisionAlgorithm() [2/2]

btSphereSphereCollisionAlgorithm::btSphereSphereCollisionAlgorithm | ( | const btCollisionAlgorithmConstructionInfo & | ci | ) |
| inline

Definition at line 37 of file btSphereSphereCollisionAlgorithm.h.

## ◆ ~btSphereSphereCollisionAlgorithm()

btSphereSphereCollisionAlgorithm::~btSphereSphereCollisionAlgorithm | ( |  | ) |
| virtual

Definition at line 35 of file btSphereSphereCollisionAlgorithm.cpp.

## Member Function Documentation

## ◆ calculateTimeOfImpact()

btScalar btSphereSphereCollisionAlgorithm::calculateTimeOfImpact | ( | btCollisionObject * | body0,
|  | btCollisionObject * | body1,
|  | const btDispatcherInfo & | dispatchInfo,
|  | btManifoldResult * | resultOut )
| virtual

Implements btCollisionAlgorithm.

Definition at line 96 of file btSphereSphereCollisionAlgorithm.cpp.

## ◆ getAllContactManifolds()

virtual void btSphereSphereCollisionAlgorithm::getAllContactManifolds | ( | btManifoldArray & | manifoldArray | ) |
| inlinevirtual

Implements btCollisionAlgorithm.

Definition at line 44 of file btSphereSphereCollisionAlgorithm.h.

## ◆ processCollision()

void btSphereSphereCollisionAlgorithm::processCollision | ( | const btCollisionObjectWrapper * | body0Wrap,
|  | const btCollisionObjectWrapper * | body1Wrap,
|  | const btDispatcherInfo & | dispatchInfo,
|  | btManifoldResult * | resultOut )
| virtual

iff distance positive, don't generate a new contact

distance (negative means penetration)

point on A (worldspace) btVector3 pos0 = col0->getWorldTransform().getOrigin() - radius0 * normalOnSurfaceB; point on B (worldspace)

report a contact. internally this will be kept persistent, and contact reduction is done

Implements btCollisionAlgorithm.

Definition at line 44 of file btSphereSphereCollisionAlgorithm.cpp.

## Member Data Documentation

## ◆ m_manifoldPtr

btPersistentManifold* btSphereSphereCollisionAlgorithm::m_manifoldPtr
| private

Definition at line 32 of file btSphereSphereCollisionAlgorithm.h.

## ◆ m_ownManifold

bool btSphereSphereCollisionAlgorithm::m_ownManifold
| private

Definition at line 31 of file btSphereSphereCollisionAlgorithm.h.

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

- btSphereSphereCollisionAlgorithm.h
- btSphereSphereCollisionAlgorithm.cpp