Public Member Functions | Private Member Functions | Private Attributes | List of all members
SurgSim::Collision::DefaultContactCalculation Class Reference

A default calculation, it does nothing and can be used as a placeholder. More...

#include <SurgSim/Collision/DefaultContactCalculation.h>

Inheritance diagram for SurgSim::Collision::DefaultContactCalculation:
SurgSim::Collision::ContactCalculation

Public Member Functions

 DefaultContactCalculation (bool doAssert=false)
 Constructor. More...
 
virtual ~DefaultContactCalculation ()
 Destructor. More...
 
virtual std::pair< int, int > getShapeTypes () override
 Function that returns the shapes between which this class performs collision detection. More...
 
- Public Member Functions inherited from SurgSim::Collision::ContactCalculation
 ContactCalculation ()
 Constructor. More...
 
virtual ~ContactCalculation ()
 Destructor. More...
 
void calculateContact (std::shared_ptr< CollisionPair > pair)
 Function that handles asymmetric pair and calls the actual contact calculation routine of the sub class. More...
 

Private Member Functions

virtual void doCalculateContact (std::shared_ptr< CollisionPair > pair) override
 Calculate the actual contact between two shapes of the given CollisionPair. More...
 

Private Attributes

bool m_doAssert
 

Detailed Description

A default calculation, it does nothing and can be used as a placeholder.

Constructor & Destructor Documentation

SurgSim::Collision::DefaultContactCalculation::DefaultContactCalculation ( bool  doAssert = false)
explicit

Constructor.

Parameters
doAssertIf set the calculation will throw an exception if it is executed, this can be used to detect cases where a contact calculation is being called on a pair that should be implemented
SurgSim::Collision::DefaultContactCalculation::~DefaultContactCalculation ( )
virtual

Destructor.

Member Function Documentation

void SurgSim::Collision::DefaultContactCalculation::doCalculateContact ( std::shared_ptr< CollisionPair pair)
overrideprivatevirtual

Calculate the actual contact between two shapes of the given CollisionPair.

Parameters
pairThe symmetric pair that is under consideration.

Implements SurgSim::Collision::ContactCalculation.

std::pair< int, int > SurgSim::Collision::DefaultContactCalculation::getShapeTypes ( )
overridevirtual

Function that returns the shapes between which this class performs collision detection.

Returns
int std::pair containing the shape types.

Implements SurgSim::Collision::ContactCalculation.

Member Data Documentation

bool SurgSim::Collision::DefaultContactCalculation::m_doAssert
private

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