|
Public Member Functions |
| | RaySensorBank () |
| virtual | ~RaySensorBank () |
| virtual void | init (const OdeHandle &odeHandle, const OsgHandle &osgHandle) |
| | initialises sensor bank with handles for ode and osg
|
| virtual unsigned int | registerSensor (RaySensor *raysensor, Primitive *body, const osg::Matrix &pose, double range, RaySensor::rayDrawMode drawMode) |
| | registers a new sensor at the sensor bank.
|
| virtual void | reset () |
| | resets all sensors (used for reseting the sensor value to a value of maximal distance)
|
| virtual bool | sense (dGeomID object) |
| | performs sense action of all sensors by checking collision with the given object
|
| virtual double | get (unsigned int index) |
| | returns the sensor value of the given sensor (usually in the range [-1,1] )
|
| virtual int | get (double *sensorarray, unsigned int array_size) |
| | writes sensorvalues in given sensorarray
|
| virtual void | setRange (unsigned int index, double range) |
| | set the range of the specified sensor (index)
|
| virtual void | setRange (double range) |
| | set the range of all sensors
|
| virtual dSpaceID | getSpaceID () |
| | returns the spaceID of the sensor space
|
| virtual void | update () |
| | updates the sensor's graphical representation
|
| virtual void | clear () |
Protected Attributes |
| std::vector< RaySensor * > | bank |
| bool | initialized |
| OdeHandle | odeHandle |
| OsgHandle | osgHandle |
Ray sensors can be registered at the bank. Methods for resetting, sensing and reading the sensor values of all sensors are provided.