ReactPhysics3D  v0.10.1
C++ Physics engine library
reactphysics3d::SphereVsSphereAlgorithm Class Reference

This class is used to compute the narrow-phase collision detection between two sphere collision shapes. More...

#include <include/reactphysics3d/collision/narrowphase/SphereVsSphereAlgorithm.h>

Inheritance diagram for reactphysics3d::SphereVsSphereAlgorithm:
reactphysics3d::NarrowPhaseAlgorithm

Public Member Functions

 SphereVsSphereAlgorithm ()=default
 Constructor.
 
virtual ~SphereVsSphereAlgorithm () override=default
 Destructor.
 
 SphereVsSphereAlgorithm (const SphereVsSphereAlgorithm &algorithm)=delete
 Deleted copy-constructor.
 
SphereVsSphereAlgorithmoperator= (const SphereVsSphereAlgorithm &algorithm)=delete
 Deleted assignment operator.
 
bool testCollision (NarrowPhaseInfoBatch &narrowPhaseInfoBatch, uint32 batchStartIndex, uint32 batchNbItems, MemoryAllocator &memoryAllocator)
 Compute a contact info if the two bounding volume collide.
 
- Public Member Functions inherited from reactphysics3d::NarrowPhaseAlgorithm
 NarrowPhaseAlgorithm ()=default
 Constructor.
 
virtual ~NarrowPhaseAlgorithm ()=default
 Destructor.
 
 NarrowPhaseAlgorithm (const NarrowPhaseAlgorithm &algorithm)=delete
 Deleted copy-constructor.
 
NarrowPhaseAlgorithmoperator= (const NarrowPhaseAlgorithm &algorithm)=delete
 Deleted assignment operator.
 

Detailed Description

This class is used to compute the narrow-phase collision detection between two sphere collision shapes.

This algorithm finds the contact point and contact normal between two spheres if they are colliding. This case is simple, we do not need to use GJK or SAT algorithm. We directly compute the contact points if any.


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