17 #ifndef _GAZEBO_SENSORS_SENSOR_HH_    18 #define _GAZEBO_SENSORS_SENSOR_HH_    26 #include <ignition/math/Pose3.hh>    62       public: 
virtual void Load(
const std::string &_worldName,
    63                                 sdf::ElementPtr _sdf);
    67       public: 
virtual void Load(
const std::string &_worldName);
    70       public: 
virtual void Init();
    75       public: 
void SetParent(
const std::string &_name, 
const uint32_t _id);
    81       public: std::string GetParentName() 
const    87       public: std::string ParentName() 
const;
    91       public: 
void Update(
const bool _force);
   100       public: 
double UpdateRate() 
const;
   104       public: 
void SetUpdateRate(
const double _hz);
   107       public: 
virtual void Fini();
   116       public: std::string Name() 
const;
   125       public: std::string ScopedName() 
const;
   130       public: 
virtual ignition::math::Pose3d Pose() 
const;
   135       public: 
virtual void SetPose(
const ignition::math::Pose3d &_pose);
   139       public: 
virtual void SetActive(
const bool _value);
   143       public: 
virtual bool IsActive() 
const;
   152       public: std::string Type() 
const;
   182       public: 
bool Visualize() 
const;
   191       public: 
virtual std::string Topic() 
const;
   195       public: 
void FillMsg(msgs::Sensor &_msg);
   204       public: std::string WorldName() 
const;
   212                   std::function<
void()> _subscriber);
   231       public: 
void ResetLastUpdateTime();
   240       public: uint32_t Id() 
const;
   249       public: uint32_t ParentId() 
const;
   271       protected: 
virtual bool UpdateImpl(
const bool ) {
return false;}
   275       protected: 
bool NeedsUpdate();
   279       private: 
void LoadPlugin(sdf::ElementPtr _sdf);
   285       protected: sdf::ElementPtr 
sdf;
   288       protected: ignition::math::Pose3d 
pose;
   303       protected: std::vector<SensorPluginPtr> 
plugins;
   323       protected: std::map<SensorNoiseType, NoisePtr> 
noises;
   327       private: std::unique_ptr<SensorPrivate> dataPtr;
 SensorCategory
SensorCategory is used to categorize sensors. 
Definition: SensorTypes.hh:303
 
std::shared_ptr< Noise > NoisePtr
Definition: SensorTypes.hh:119
 
boost::shared_ptr< World > WorldPtr
Definition: PhysicsTypes.hh:84
 
bool active
True if sensor generation is active. 
Definition: Sensor.hh:282
 
Forward declarations for the common classes. 
Definition: Animation.hh:33
 
sdf::ElementPtr sdf
Pointer the the SDF element for the sensor. 
Definition: Sensor.hh:285
 
uint32_t parentId
The sensor's parent ID. 
Definition: Sensor.hh:300
 
Forward declarations for transport. 
 
#define GAZEBO_DEPRECATED(version)
Definition: CommonTypes.hh:48
 
std::string parentName
Name of the parent. 
Definition: Sensor.hh:297
 
std::vector< event::ConnectionPtr > connections
All event connections. 
Definition: Sensor.hh:291
 
common::Time lastMeasurementTime
Stores last time that a sensor measurement was generated; this value must be updated within each sens...
Definition: Sensor.hh:320
 
boost::shared_ptr< Node > NodePtr
Definition: TransportTypes.hh:57
 
common::Time updatePeriod
Desired time between updates, set indirectly by Sensor::SetUpdateRate. 
Definition: Sensor.hh:313
 
default namespace for gazebo 
 
common::Time lastUpdateTime
Time of the last update. 
Definition: Sensor.hh:316
 
boost::shared_ptr< Scene > ScenePtr
Definition: RenderTypes.hh:80
 
ignition::math::Pose3d pose
Pose of the sensor. 
Definition: Sensor.hh:288
 
transport::NodePtr node
Node for communication. 
Definition: Sensor.hh:294
 
gazebo::rendering::ScenePtr scene
Pointer to the Scene. 
Definition: Sensor.hh:309
 
virtual bool UpdateImpl(const bool)
This gets overwritten by derived sensor types. 
Definition: Sensor.hh:271
 
boost::shared_ptr< Connection > ConnectionPtr
Definition: CommonTypes.hh:153
 
gazebo::physics::WorldPtr world
Pointer to the world. 
Definition: Sensor.hh:306
 
GAZEBO_VISIBLE void Init(google::protobuf::Message &_message, const std::string &_id="")
Initialize a message. 
 
Forward declarations and typedefs for sensors. 
 
SensorNoiseType
Definition: SensorTypes.hh:203
 
std::map< SensorNoiseType, NoisePtr > noises
Noise added to sensor data. 
Definition: Sensor.hh:323
 
Base class for sensors. 
Definition: Sensor.hh:50
 
#define GAZEBO_VISIBLE
Use to represent "symbol visible" if supported. 
Definition: system.hh:59
 
std::vector< SensorPluginPtr > plugins
All the plugins for the sensor. 
Definition: Sensor.hh:303
 
A Time class, can be used to hold wall- or sim-time. 
Definition: Time.hh:44
 
Noise models for sensor output signals. 
Definition: Noise.hh:55