ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Using a modified camera is definitely a good idea. You should look at the specification of your light sensor, and determine how it behaves in the real world (sensitivity, range, field-of-view, etc).

I would then right a simple shader to attach to the camera (look at the StereoCamera for an example). The shader should fill a texture with light intensity. Right now the StereoCamera has a shader that fills a texture with depth data. You can use this as a starting point, and google should tell you how to compute light intensity in GLSL.

If the above seems overkill, or too much work. Then you can write a sensor that just iterates over all the lights in the world, and computes distance to the sensor. This will have some drawbacks: occlusions and reflections are problematic.