18 #ifndef cost_map_ros_CONVERTER_HPP_ 19 #define cost_map_ros_CONVERTER_HPP_ 30 #include <cost_map_msgs/CostMap.h> 31 #include <cost_map_msgs/GetCostMap.h> 35 #include <nav_msgs/OccupancyGrid.h> 82 const std::string& layer_name,
109 const std::string& layer_name,
130 const std::string& layer_name,
141 const std::string& service_name=
"get_cost_map");
143 const std::string& service_name=
"get_cost_map");
145 bool callback(cost_map_msgs::GetCostMap::Request &req,
146 cost_map_msgs::GetCostMap::Response &res);
Costmap2DROSServiceProvider(costmap_2d::Costmap2DROS *ros_costmap, const std::string &service_name="get_cost_map")
void toMessage(const cost_map::CostMap &cost_map, cost_map_msgs::CostMap &message)
bool callback(cost_map_msgs::GetCostMap::Request &req, cost_map_msgs::GetCostMap::Response &res)
Provide cost_map::fromROSCostMap2D() as a ros service.
costmap_2d::Costmap2DROS * ros_costmap
bool addLayerFromROSImage(const sensor_msgs::Image &image, const std::string &layer_name, cost_map::CostMap &cost_map)
ros::ServiceServer service
void toOccupancyGrid(const cost_map::CostMap &cost_map, const std::string &layer, nav_msgs::OccupancyGrid &msg)
bool fromCostmap2DROS(costmap_2d::Costmap2DROS &ros_costmap, const std::string &layer_name, cost_map::CostMap &cost_map)
Converts a ROS costmap to a costmap object.
bool fromCostmap2DROSAtRobotPose(costmap_2d::Costmap2DROS &ros_costmap, const cost_map::Length &geometry, const std::string &layer_name, cost_map::CostMap &cost_map)
Converts a ROS costmap around the robot to a costmap object.
void toGridMap(const cost_map::CostMap cost_map, grid_map::GridMap &grid_map)
Convert a cost map object into a grid map object.
bool fromMessage(const cost_map_msgs::CostMap &message, cost_map::CostMap &cost_map)