RaySensorBank Class Reference
Class for a bank (collection) of ray sensors.
More...
#include <raysensorbank.h>
List of all members.
Detailed Description
Class for a bank (collection) of ray sensors.
Ray sensors can be registered at the bank. Methods for resetting, sensing and reading the sensor values of all sensors are provided.
Constructor & Destructor Documentation
Member Function Documentation
int get |
( |
double * |
sensorarray, |
|
|
unsigned int |
array_size | |
|
) |
| | [virtual] |
writes sensorvalues in given sensorarray
- Parameters:
-
| sensorarray | pointer to the sensorarray in which the values should be stored |
| array_size | maximal number of all elements in the sensorarray |
- Returns:
- number of written sensorvalues
double get |
( |
unsigned int |
index |
) |
[virtual] |
returns the sensor value of the given sensor (usually in the range [-1,1] )
int getSensorNumber |
( |
|
) |
[virtual] |
returns the number of sensors in the bank
dSpaceID getSpaceID |
( |
|
) |
[virtual] |
returns the spaceID of the sensor space
initialises sensor bank with handles for ode and osg
virtual bool isInitialized |
( |
|
) |
[inline, virtual] |
registers a new sensor at the sensor bank.
The body and the pose have to be provided.
- Parameters:
-
| raysensor | RaySensor to add |
| body | body to which the sensor should be connected |
| pose | relative position/orientation |
| range | maximum sense range of the sensor |
- Returns:
- index of the sensor
resets all sensors (used for reseting the sensor value to a value of maximal distance)
void setRange |
( |
float |
range |
) |
[virtual] |
set the range of all sensors
- Parameters:
-
| range | new length of the sensors |
void setRange |
( |
unsigned int |
index, |
|
|
float |
range | |
|
) |
| | [virtual] |
set the range of the specified sensor (index)
- Parameters:
-
| index | index of sensor to modify |
| range | new length of the sensor |
virtual int size |
( |
|
) |
[inline, virtual] |
returns the number of sensors
void update |
( |
|
) |
[virtual] |
updates the sensor's graphical representation
Member Data Documentation
The documentation for this class was generated from the following files: