17 #ifndef _GAZEBO_SENSORS_MULTICAMERASENSOR_HH_
18 #define _GAZEBO_SENSORS_MULTICAMERASENSOR_HH_
24 #include "gazebo/msgs/MessageTypes.hh"
35 class MultiCameraSensorPrivate;
53 public:
virtual void Load(
const std::string &_worldName)
override;
56 public:
virtual void Init()
override;
70 public:
virtual std::string
Topic()
const override;
91 public:
unsigned int ImageWidth(
const unsigned int _index)
const;
97 public:
unsigned int ImageHeight(
const unsigned int _index)
const;
103 public:
const unsigned char *
ImageData(
const unsigned int _index);
109 public:
bool SaveFrame(
const std::vector<std::string> &_filenames);
115 protected:
virtual bool UpdateImpl(
const bool _force)
override;
118 protected:
virtual void Fini()
override;
121 private:
void Render();
124 private:
void PrerenderEnded();
128 private: std::unique_ptr<MultiCameraSensorPrivate> dataPtr;
sensors
Definition: SensorManager.hh:37
Forward declarations for transport.
Multiple camera sensor.
Definition: MultiCameraSensor.hh:45
virtual bool UpdateImpl(const bool _force) override
This gets overwritten by derived sensor types.
virtual std::string Topic() const override
Returns the topic name as set in SDF.
double NextRequiredTimestamp() const override
Return the next timestamp going to be used by the sensor.
MultiCameraSensor()
Constructor.
void ResetLastUpdateTime() override
reset timing related members
void SetActive(bool _value) override
Set whether the sensor is active or not.
unsigned int CameraCount() const
Get the number of cameras.
bool SaveFrame(const std::vector< std::string > &_filenames)
Saves the camera image(s) to the disk.
virtual bool IsActive() const override
Returns true if sensor generation is active.
unsigned int ImageWidth(const unsigned int _index) const
Gets the width of the image in pixels.
bool NeedsUpdate() override
Return true if the sensor needs to be updated.
virtual void Fini() override
Finalize the sensor.
virtual ~MultiCameraSensor()
Destructor.
virtual void Load(const std::string &_worldName) override
Load the sensor with default parameters.
const unsigned char * ImageData(const unsigned int _index)
Gets the raw image data from the sensor.
unsigned int ImageHeight(const unsigned int _index) const
Gets the height of the image in pixels.
virtual void Init() override
Initialize the sensor.
rendering::CameraPtr Camera(const unsigned int _index) const
Returns a pointer to a rendering::Camera.
Base class for sensors.
Definition: Sensor.hh:53
boost::shared_ptr< Camera > CameraPtr
Definition: RenderTypes.hh:90
Forward declarations for the common classes.
Definition: Animation.hh:27