rgbd
server_ros.h
Go to the documentation of this file.
1 #ifndef RGBD_SERVER_ROS_H_
2 #define RGBD_SERVER_ROS_H_
3 
4 #include "rgbd/types.h"
5 
6 #include <ros/node_handle.h>
7 #include <ros/publisher.h>
8 
9 #include <memory>
10 
11 namespace rgbd {
12 
16 class ServerROS {
17 
18 public:
19 
23  ServerROS(ros::NodeHandle nh=ros::NodeHandle());
24 
28  virtual ~ServerROS();
29 
37  void initialize(std::string ns = "", const bool publish_rgb = false, const bool publish_depth = false, const bool publish_pc = false);
38 
43  void send(const Image& image);
44 
45 protected:
46 
47  ros::NodeHandle nh_;
53 
54 };
55 
56 }
57 
58 #endif // RGBD_SERVER_ROS_H_
std::string
std::shared_ptr< ros::Publisher >
types.h
rgbd::ServerROS::pub_rgb_img_
std::shared_ptr< ros::Publisher > pub_rgb_img_
Definition: server_ros.h:48
rgbd::ServerROS::~ServerROS
virtual ~ServerROS()
Destructor.
Definition: server_ros.cpp:24
rgbd::ServerROS::ServerROS
ServerROS(ros::NodeHandle nh=ros::NodeHandle())
Constructor.
Definition: server_ros.cpp:18
rgbd::Image
Definition: image.h:43
rgbd::ServerROS::nh_
ros::NodeHandle nh_
Definition: server_ros.h:47
rgbd::ServerROS
Server which publishes ROS rgb image, depth image and pointcloud messages.
Definition: server_ros.h:16
rgbd
Definition: client.h:24
rgbd::ServerROS::pub_rgb_info_
std::shared_ptr< ros::Publisher > pub_rgb_info_
Definition: server_ros.h:49
rgbd::ServerROS::send
void send(const Image &image)
Publish a new image to the selected ROS topics.
Definition: server_ros.cpp:75
memory
rgbd::ServerROS::initialize
void initialize(std::string ns="", const bool publish_rgb=false, const bool publish_depth=false, const bool publish_pc=false)
initialize server
Definition: server_ros.cpp:31
rgbd::ServerROS::pub_depth_pc_
std::shared_ptr< ros::Publisher > pub_depth_pc_
Definition: server_ros.h:52
rgbd::ServerROS::pub_depth_img_
std::shared_ptr< ros::Publisher > pub_depth_img_
Definition: server_ros.h:50
rgbd::ServerROS::pub_depth_info_
std::shared_ptr< ros::Publisher > pub_depth_info_
Definition: server_ros.h:51