#include <ContactData.h>
Inheritance diagram for Physsim::ContactData:

Public Member Functions | |
| ContactData () | |
| Constructs a ContactData object with no object pointers. | |
| ContactData (BasePtr o1, BasePtr o2) | |
| Constructs a ContactData object with the given object IDs. | |
| virtual void | load_from_xml (XMLTreeConstPtr node, std::map< std::string, BasePtr > &id_map) |
| Implements Base::load_from_xml(). | |
| virtual void | save_to_xml (XMLTreePtr node, std::list< BaseConstPtr > &shared_objects) const |
| virtual bool | is_struct_identical (BaseConstPtr object) const |
| Verifies that the structure of two objects is identical. | |
| virtual void | clone (BasePtr &cloned, bimap< BasePtr, BasePtr > *obj_map=NULL) const |
| Clones this object. | |
| virtual void | load_state (BaseConstPtr object, bimap< BasePtr, BasePtr > *correspondence=NULL) |
| Loads the state of this object. | |
| virtual void | save_state (BasePtr object, bimap< BasePtr, BasePtr > *correspondence=NULL) const |
| Saves the state of this object. | |
| void | set_penalty_gains (Real kp, Real kv, Real ki) |
| Sets the gains for penalty methods. | |
| void | set_static_friction_gains (Real kp_static, Real kv_static) |
| Sets the gains for maintaining static friction with penalty methods. | |
| void | set_restitution (Real restitution) |
| Sets the restitution scalar [0,1]. | |
| void | set_mu_coulomb (Real mu) |
| Sets the coefficient of friction for Coulomb friction (mu = 0..infinity). | |
| void | set_mu_viscous (Real mu) |
| Sets the coefficient of friction for viscous friction (mu = 0..infinity). | |
| void | set_num_samples (unsigned num_samples) |
| Sets the number of samples to use (i.e., contact points) to approximate a contact volume, surface, or line. | |
| void | set_static_friction_velocity_thresh (Real thresh) |
| Sets the threshold velocity for differentiating between static and dynamic friction. | |
| void | set_resting_contact_method (boost::shared_ptr< RestingContactMethod > rcm) |
| Sets the resting contact method used for this pair of objects. | |
| void | set_collision_method (boost::shared_ptr< CollisionMethod > cm) |
| Sets the collision method used for this pair of objects. | |
| Real | get_kp () const |
| Gets the position gain for penalty methods (default 0.0). | |
| Real | get_kv () const |
| Gets the velocity gain for penalty methods (default 0.0). | |
| Real | get_ki () const |
| Gets the integrative gain for penalty methods (default 0.0). | |
| Real | get_kp_static () const |
| Gets the positional gain for maintaining static friction with penalty methods (default 0.0). | |
| Real | get_kv_static () const |
| Gets the velocity gain for maintaining static friction with penalty methods (default 0.0). | |
| Real | get_static_friction_velocity_thresh () const |
| Gets the threshold velocity for differentiating between static and dynamic friction. | |
| Real | get_restitution () const |
| Gets the restitution scalar [0,1]. | |
| Real | get_mu_coulomb () const |
| Gets the coefficient of Coulomb friction. | |
| Real | get_mu_viscous () const |
| Gets the coefficient of viscous friction. | |
| unsigned | get_num_samples () const |
| Gets the number of samples to use (i.e., contact points) to approximate a contact volume, surface, or line. | |
| boost::shared_ptr< RestingContactMethod > | get_resting_contact_method () const |
| Gets the resting contact method used for this pair of objects. | |
| boost::shared_ptr< CollisionMethod > | get_collision_method () const |
| Gets the collision method used for this pair of objects. | |
| bool | operator== (const ContactData &cd) const |
| Equality operation for use with maps, sets, etc. | |
| bool | operator< (const ContactData &cd) const |
| Comparison operation for use with maps, sets, etc. | |
Public Attributes | |
| sorted_pair< BasePtr > | objects |
| The two objects represented by the contact data. | |
This data applies to pairs of geometries / bodies in contact. Not all of the data contained within this class will necessarily be used by every contact method.
| ContactData::ContactData | ( | ) |
Constructs a ContactData object with no object pointers.
All gains and coefficients are set to zero.
| ContactData::ContactData | ( | BasePtr | o1, | |
| BasePtr | o2 | |||
| ) |
Constructs a ContactData object with the given object IDs.
All gains and coefficients are set to zero.
| void ContactData::load_from_xml | ( | XMLTreeConstPtr | node, | |
| std::map< std::string, BasePtr > & | id_map | |||
| ) | [virtual] |
Implements Base::load_from_xml().
This method does not read the Base information (i.e., name()), because a name for this object is unnecessary.
Reimplemented from Physsim::Base.
| void ContactData::save_to_xml | ( | XMLTreePtr | node, | |
| std::list< BaseConstPtr > & | shared_objects | |||
| ) | const [virtual] |
This method does not write the Base information, because neither a name nor a unique ID are useful.
Reimplemented from Physsim::Base.
| void ContactData::save_state | ( | BasePtr | object, | |
| bimap< BasePtr, BasePtr > * | correspondence = NULL | |||
| ) | const [virtual] |
Saves the state of this object.
The underlying penalty resting contact method must have identical structure.
Reimplemented from Physsim::Base.
| void Physsim::ContactData::set_num_samples | ( | unsigned | num_samples | ) | [inline] |
Sets the number of samples to use (i.e., contact points) to approximate a contact volume, surface, or line.
| void Physsim::ContactData::set_static_friction_velocity_thresh | ( | Real | thresh | ) | [inline] |
Sets the threshold velocity for differentiating between static and dynamic friction.
| Real Physsim::ContactData::get_static_friction_velocity_thresh | ( | ) | const [inline] |
Gets the threshold velocity for differentiating between static and dynamic friction.
| unsigned Physsim::ContactData::get_num_samples | ( | ) | const [inline] |
Gets the number of samples to use (i.e., contact points) to approximate a contact volume, surface, or line.
| bool Physsim::ContactData::operator== | ( | const ContactData & | cd | ) | const [inline] |
Equality operation for use with maps, sets, etc.
Comparison utilizes the object sorted_pair only, so two ContactData objects will found to be equal if the objects are equal.
| bool Physsim::ContactData::operator< | ( | const ContactData & | cd | ) | const [inline] |
Comparison operation for use with maps, sets, etc.
Comparison utilizes the object sorted_pair only.
1.5.1