Go to the documentation of this file.
23 #ifndef GAZEBO_ROS_OPENNI_KINECT_HH
24 #define GAZEBO_ROS_OPENNI_KINECT_HH
32 #include <sensor_msgs/PointCloud2.h>
33 #include <sensor_msgs/Image.h>
34 #include <sensor_msgs/CameraInfo.h>
36 #include <std_msgs/Float64.h>
40 #include <sdf/Param.hh>
41 #include <gazebo/physics/physics.hh>
42 #include <gazebo/transport/TransportTypes.hh>
43 #include <gazebo/msgs/MessageTypes.hh>
44 #include <gazebo/common/Time.hh>
45 #include <gazebo/sensors/SensorTypes.hh>
46 #include <gazebo/plugins/DepthCameraPlugin.hh>
49 #include <gazebo_plugins/GazeboRosOpenniKinectConfig.h>
50 #include <dynamic_reconfigure/server.h>
53 #include <boost/thread/mutex.hpp>
71 public:
virtual void Load(sensors::SensorPtr _parent, sdf::ElementPtr _sdf);
78 unsigned int _width,
unsigned int _height,
79 unsigned int _depth,
const std::string &_format);
83 unsigned int _width,
unsigned int _height,
84 unsigned int _depth,
const std::string &_format);
103 uint32_t rows_arg, uint32_t cols_arg,
104 uint32_t step_arg,
void* data_arg);
107 uint32_t height, uint32_t width,
108 uint32_t step,
void* data_arg);
int depth_info_connect_count_
void DepthInfoDisconnect()
std::string point_cloud_topic_name_
ROS image topic name.
double point_cloud_cutoff_max_
Maximum range of the point cloud.
ros::Publisher point_cloud_pub_
A pointer to the ROS node. A node will be instantiated if it does not exist.
void DepthImageDisconnect()
double point_cloud_cutoff_
Minimum range of the point cloud.
void PointCloudDisconnect()
common::Time last_depth_image_camera_info_update_time_
bool FillPointCloudHelper(sensor_msgs::PointCloud2 &point_cloud_msg, uint32_t rows_arg, uint32_t cols_arg, uint32_t step_arg, void *data_arg)
ros::Publisher depth_image_camera_info_pub_
virtual void Advertise()
Advertise point cloud and depth image.
sensor_msgs::Image depth_image_msg_
int point_cloud_connect_count_
Keep track of number of connctions for point clouds.
common::Time depth_sensor_update_time_
event::ConnectionPtr load_connection_
void FillPointdCloud(const float *_src)
push point cloud data into ros topic
void FillDepthImage(const float *_src)
push depth image data into ros topic
~GazeboRosOpenniKinect()
Destructor.
bool FillDepthImageHelper(sensor_msgs::Image &image_msg, uint32_t height, uint32_t width, uint32_t step, void *data_arg)
virtual void Load(sensors::SensorPtr _parent, sdf::ElementPtr _sdf)
Load the plugin.
bool use_depth_image_16UC1_format_
int depth_image_connect_count_
Keep track of number of connctions for point clouds.
std::string depth_image_camera_info_topic_name_
std::string depth_image_topic_name_
image where each pixel contains the depth data
virtual void OnNewImageFrame(const unsigned char *_image, unsigned int _width, unsigned int _height, unsigned int _depth, const std::string &_format)
Update the controller.
virtual void PublishCameraInfo()
sensor_msgs::PointCloud2 point_cloud_msg_
PointCloud2 point cloud message.
GazeboRosOpenniKinect()
Constructor.
virtual void OnNewDepthFrame(const float *_image, unsigned int _width, unsigned int _height, unsigned int _depth, const std::string &_format)
Update the controller.
ros::Publisher depth_image_pub_
gazebo_plugins
Author(s): John Hsu
autogenerated on Thu Sep 5 2024 02:49:55