Moby
|
Defines an abstract collision detection mechanism. More...
#include <CollisionDetection.h>
Public Member Functions | |
virtual void | set_simulator (boost::shared_ptr< ConstraintSimulator > sim) |
virtual void | broad_phase (double dt, const std::vector< ControlledBodyPtr > &bodies, std::vector< std::pair< CollisionGeometryPtr, CollisionGeometryPtr > > &to_check) |
Default broad phase function (checks everything) | |
virtual double | calc_CA_Euler_step (const PairwiseDistInfo &pdi)=0 |
virtual void | find_contacts (CollisionGeometryPtr cgA, CollisionGeometryPtr cgB, std::vector< UnilateralConstraint > &contacts, double TOL=NEAR_ZERO)=0 |
virtual double | calc_signed_dist (CollisionGeometryPtr cg1, CollisionGeometryPtr cg2, Point3d &p1, Point3d &p2) |
Calculates the signed distance between two geometries. | |
boost::shared_ptr < CollisionDetection > | get_this () |
Get the shared pointer for this. | |
Public Member Functions inherited from Moby::Base | |
Base (const Base *b) | |
virtual void | save_to_xml (XMLTreePtr node, std::list< boost::shared_ptr< const Base > > &shared_objects) const |
Method for saving this object to XML. More... | |
virtual void | load_from_xml (boost::shared_ptr< const XMLTree > node, std::map< std::string, BasePtr > &id_map) |
Method for loading the data for this object from XML. More... | |
Protected Member Functions | |
virtual double | calc_next_CA_Euler_step (const PairwiseDistInfo &pdi)=0 |
Static Protected Member Functions | |
static UnilateralConstraint | create_contact (CollisionGeometryPtr a, CollisionGeometryPtr b, const Point3d &point, const Ravelin::Vector3d &normal, double violation=0.0) |
Creates a contact constraint given the bare-minimum info. | |
Friends | |
class | ConstraintStabilization |
Additional Inherited Members | |
Static Public Member Functions inherited from Moby::Base | |
template<class T > | |
static boost::shared_ptr< T > | clone (boost::shared_ptr< T > x) |
Static method for cloning a shared pointer. | |
Public Attributes inherited from Moby::Base | |
boost::shared_ptr< void > | userdata |
Any relevant userdata. | |
std::string | id |
The unique ID for this object. | |
Defines an abstract collision detection mechanism.
Contact finding and collision detection are two separate, but related, procedures. Collision detection quickly determines whether two bodies are geometrically intersecting at their current configurations. Contact finding determines whether two bodies will come into contact (or are already in contact) in a given time interval; if the bodies do/will contact, contact finding computes contact points and normals.