7 #ifndef LIGHT_DEFAULT_SENSOR_H
8 #define LIGHT_DEFAULT_SENSOR_H
14 class CLightDefaultSensor;
15 class CLightSensorEquippedEntity;
18 #include <argos3/plugins/robots/generic/control_interface/ci_light_sensor.h>
19 #include <argos3/core/utility/math/range.h>
20 #include <argos3/core/utility/math/rng.h>
21 #include <argos3/core/simulator/space/space.h>
22 #include <argos3/core/simulator/sensor.h>
float Real
Collects all ARGoS code.
The namespace containing all the ARGoS related code.
ticpp::Element TConfigurationNode
The ARGoS configuration XML node.
Basic class for an entity that contains other entities.
An entity that contains a pointer to the user-defined controller.
The basic interface for a simulated sensor.
CSpace & m_cSpace
Reference to the space.
virtual void Reset()
Resets the sensor to the state it had just after Init().
CRange< Real > m_cNoiseRange
Noise range.
virtual void Update()
Updates the state of the entity associated to this sensor, if the sensor is currently enabled.
CRandom::CRNG * m_pcRNG
Random number generator.
CLightSensorEquippedEntity * m_pcLightEntity
Reference to light sensor equipped entity associated to this sensor.
bool m_bAddNoise
Whether to add noise or not.
void SetShowRays(bool b_show_rays)
Sets whether or not the rays must be shown in the GUI.
CControllableEntity * m_pcControllableEntity
Reference to controllable entity associated to this sensor.
virtual ~CLightDefaultSensor()
bool m_bShowRays
Flag to show rays in the simulator.
virtual void Init(TConfigurationNode &t_tree)
Initializes the sensor from the XML configuration tree.
virtual void SetRobot(CComposableEntity &c_entity)
Sets the entity associated to this sensor.
virtual Real CalculateReading(Real f_distance, Real f_intensity)
Calculates the light reading resulting from a light source at the given distance.
bool IsShowRays()
Returns true if the rays must be shown in the GUI.