voronoi_graph_node.h
Go to the documentation of this file.
1 #ifndef VORONOI_GRAPH_NODE_H
2 #define VORONOI_GRAPH_NODE_H
3 
4 #include <memory>
5 
6 // ROS
7 #include <ros/ros.h>
8 #include <nav_msgs/OccupancyGrid.h>
9 
12 
14 
15 namespace tuw_graph
16 {
17 
18 
20  {
21 
22  public:
24 
27  std::unique_ptr<ros::Rate> rate_;
28  void publishMap();
29  void publishSegments();
30 
31  private:
32  void globalMapCallback(const nav_msgs::OccupancyGrid::ConstPtr& _map);
33  void createGraph(const nav_msgs::OccupancyGrid::ConstPtr& _map, size_t _map_hash);
34  bool loadGraph(size_t _hash);
35  bool loadCustomGraph(std::string _path);
36 
37 
41 
42 
43  std::string topicGlobalMap_;
44  std::string topicVoronoiMap_;
45  std::string topicSegments_;
46  std::string graphCachePath_;
47  std::string customGraphPath_;
48 
49  std::string frameGlobalMap_;
50  std::string frameVoronoiMap_;
51 
52 
54  Eigen::Vector2d origin_;
55  float resolution_;
56  cv::Mat map_;
57  cv::Mat distField_;
58  cv::Mat voronoiMap_;
59  float path_length_;
60  std::unique_ptr<float[]> potential;
61  std::vector<Segment> segments_;
65  };
66 
67 }
68 
69 #endif // TUW_NAV_COSTMAP_NODE_H
70 
void createGraph(const nav_msgs::OccupancyGrid::ConstPtr &_map, size_t _map_hash)
void globalMapCallback(const nav_msgs::OccupancyGrid::ConstPtr &_map)
std::unique_ptr< float[]> potential
std::unique_ptr< ros::Rate > rate_
std::vector< Segment > segments_
VoronoiGeneratorNode(ros::NodeHandle &n)
bool loadCustomGraph(std::string _path)


tuw_voronoi_graph
Author(s): Benjamin Binder
autogenerated on Mon Jun 10 2019 15:42:44