Public Member Functions | Protected Member Functions
ContactSensor Class Reference

Contact sensor. More...

#include <ContactSensor.hh>

Inheritance diagram for ContactSensor:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 ContactSensor ()
 Constructor.
virtual ~ContactSensor ()
 Destructor.
virtual void Load (sdf::ElementPtr &_sdf)
 Load the contact sensor using parameter from an XMLConfig node.
virtual void Load ()
 Load the sensor with default parameters.
virtual void Init ()
 Initialize the sensor.
unsigned int GetCollisionCount () const
 Get the number of collisions that the sensor is observing.
std::string GetCollisionName (unsigned int _index) const
 Get a collision name.
unsigned int GetCollisionContactCount (const std::string &_collisionName) const
 Return the number of contacts for an observed collision.
physics::Contact GetCollisionContact (const std::string &_collisionName, unsigned int _index) const
 Get a contact for a collision by index.
gazebo::physics::ModelPtr GetParentModel ()
std::map< std::string,
physics::Contact
GetContacts (const std::string &_collisionName)
boost::mutex * GetUpdateMutex () const

Protected Member Functions

virtual void UpdateImpl (bool force)
 Update sensed values.
virtual void Fini ()
 Finalize the sensor.

Detailed Description

Contact sensor.

This sensor detects and reports contacts between objects


Constructor & Destructor Documentation

Constructor.

Parameters:
bodyThe underlying collision test uses an ODE collision, so ray sensors must be attached to a body.

Member Function Documentation

virtual void Load ( sdf::ElementPtr &  _sdf) [virtual]

Load the contact sensor using parameter from an XMLConfig node.

Parameters:
nodeThe XMLConfig node

Reimplemented from Sensor.


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