#include <hector_costmap.h>
Public Member Functions | |
void | callbackElevationMap (const hector_elevation_msgs::ElevationGridConstPtr &elevation_map_msg) |
callbackElevationMap get called if a new elevation map is available | |
void | callbackGridMap (const nav_msgs::OccupancyGridConstPtr &grid_map_msg) |
callbackGridMap get called if a new 2D grid map is available | |
void | callbackPointCloud (const sensor_msgs::PointCloud2ConstPtr &cloud_msg) |
callbackOctoMap get called if a new octo map is available | |
CostMapCalculation () | |
Default constructor. | |
void | dynRecParamCallback (hector_costmap::CostMapCalculationConfig &config, uint32_t level) |
dynRecParamCallback This function get called if new parameters has been set with the dynamic reconfigure dialog | |
void | sysMessageCallback (const std_msgs::String &string) |
sysMessageCallback This function listen to system messages | |
void | timerCallback (const ros::TimerEvent &event) |
timerCallback publishes periodically a new 2D cost map | |
void | updateMapParamsCallback (const nav_msgs::MapMetaData &map_meta_data) |
updateMapParamsCallback updates the map meta information if someone has changed it | |
~CostMapCalculation () | |
Default deconstructor. | |
Private Member Functions | |
bool | calculateCostMap (char map_level) |
This function fuses the elevation and grid map und calculates the 2d cost map. | |
bool | calculateCostMap_old (char map_level) |
This function fuses the elevation and grid map und calculates the 2d cost map. | |
bool | computeWindowIndices (ros::Time time, double update_radius) |
Computes the indices for the bounding box thats get updated. | |
Private Attributes | |
bool | allow_elevation_map_to_clear_occupied_cells |
nav_msgs::OccupancyGrid | cloud_cost_map |
nav_msgs::OccupancyGrid | cost_map |
std::string | cost_map_topic |
double | costmap_pub_freq |
dynamic_reconfigure::Server < hector_costmap::CostMapCalculationConfig > | dyn_rec_server_ |
nav_msgs::OccupancyGrid | elevation_cost_map |
cv::Mat | elevation_cost_map_ |
cv::Mat | elevation_map_ |
cv::Mat | elevation_map_filtered |
std::string | elevation_map_topic |
int | elevation_zero_level |
cv::Mat | grid_map_ |
nav_msgs::OccupancyGridConstPtr | grid_map_msg_ |
std::string | grid_map_topic |
double | grid_res_z |
double | initial_free_cells_radius |
tf::TransformListener | listener |
std::string | local_transform_frame_id |
std::string | map_frame_id |
int | max_clear_size |
double | max_delta_elevation |
Eigen::Vector2i | max_index |
Eigen::Vector2i | min_index |
ros::NodeHandle | nHandle |
ros::NodeHandle | pnHandle |
std::string | point_cloud_topic |
ros::Publisher | pub_cloud_slice |
ros::Publisher | pub_cost_map |
bool | received_elevation_map |
bool | received_grid_map |
bool | received_point_cloud |
pcl::PointCloud< pcl::PointXYZ > ::Ptr | sliced_cloud |
double | slize_max_height |
double | slize_min_height |
ros::Subscriber | sub_elevation_map |
ros::Subscriber | sub_grid_map |
ros::Subscriber | sub_map_info |
ros::Subscriber | sub_point_cloud |
ros::Subscriber | sub_sysMessage |
std::string | sys_msg_topic |
ros::Timer | timer |
double | update_radius_world |
bool | use_cloud_map |
bool | use_elevation_map |
bool | use_grid_map |
HectorMapTools::CoordinateTransformer < float > | world_map_transform |
Definition at line 27 of file hector_costmap.h.
Default constructor.
Definition at line 21 of file hector_costmap.cpp.
Default deconstructor.
Definition at line 113 of file hector_costmap.cpp.
bool CostMapCalculation::calculateCostMap | ( | char | map_level | ) | [private] |
This function fuses the elevation and grid map und calculates the 2d cost map.
[in] | map_level | set the method to calculate the 2d cost map (binary encoded) |
true | if everything went fine, otherwise false |
Definition at line 675 of file hector_costmap.cpp.
bool CostMapCalculation::calculateCostMap_old | ( | char | map_level | ) | [private] |
This function fuses the elevation and grid map und calculates the 2d cost map.
[in] | map_level | set the method to calculate the 2d cost map |
true | if everything went fine, otherwise false |
Definition at line 440 of file hector_costmap.cpp.
void CostMapCalculation::callbackElevationMap | ( | const hector_elevation_msgs::ElevationGridConstPtr & | elevation_map_msg | ) |
callbackElevationMap get called if a new elevation map is available
[in] | elevation_map_msg | stores an elevation map as a 2.5D grid |
Definition at line 225 of file hector_costmap.cpp.
void CostMapCalculation::callbackGridMap | ( | const nav_msgs::OccupancyGridConstPtr & | grid_map_msg | ) |
callbackGridMap get called if a new 2D grid map is available
[in] | grid_map_msg | stores 2D grid map data |
Definition at line 390 of file hector_costmap.cpp.
void CostMapCalculation::callbackPointCloud | ( | const sensor_msgs::PointCloud2ConstPtr & | cloud_msg | ) |
callbackOctoMap get called if a new octo map is available
[in] | octo_map_msg | stores an octo map as a 3D point cloud |
Definition at line 309 of file hector_costmap.cpp.
bool CostMapCalculation::computeWindowIndices | ( | ros::Time | time, |
double | update_radius | ||
) | [private] |
Computes the indices for the bounding box thats get updated.
[in] | time | Current time is needed |
[in] | update_radius | determines the size of the bounding box in [m] |
true | if everything went fine, otherwise false |
Definition at line 754 of file hector_costmap.cpp.
void CostMapCalculation::dynRecParamCallback | ( | hector_costmap::CostMapCalculationConfig & | config, |
uint32_t | level | ||
) |
dynRecParamCallback This function get called if new parameters has been set with the dynamic reconfigure dialog
[in] | config | contains current parameters |
[in] | level | is unused |
Definition at line 148 of file hector_costmap.cpp.
void CostMapCalculation::sysMessageCallback | ( | const std_msgs::String & | string | ) |
sysMessageCallback This function listen to system messages
[in] | string | parameter contains system messages, like "reset" |
Definition at line 119 of file hector_costmap.cpp.
void CostMapCalculation::timerCallback | ( | const ros::TimerEvent & | event | ) |
timerCallback publishes periodically a new 2D cost map
[in] | event | is unused |
Definition at line 213 of file hector_costmap.cpp.
void CostMapCalculation::updateMapParamsCallback | ( | const nav_msgs::MapMetaData & | map_meta_data | ) |
updateMapParamsCallback updates the map meta information if someone has changed it
[in] | map_meta_data | map meta information like grid resolution or origin |
Definition at line 159 of file hector_costmap.cpp.
Definition at line 104 of file hector_costmap.h.
nav_msgs::OccupancyGrid CostMapCalculation::cloud_cost_map [private] |
Definition at line 112 of file hector_costmap.h.
nav_msgs::OccupancyGrid CostMapCalculation::cost_map [private] |
Definition at line 112 of file hector_costmap.h.
std::string CostMapCalculation::cost_map_topic [private] |
Definition at line 116 of file hector_costmap.h.
double CostMapCalculation::costmap_pub_freq [private] |
Definition at line 106 of file hector_costmap.h.
dynamic_reconfigure::Server<hector_costmap::CostMapCalculationConfig> CostMapCalculation::dyn_rec_server_ [private] |
Definition at line 92 of file hector_costmap.h.
nav_msgs::OccupancyGrid CostMapCalculation::elevation_cost_map [private] |
Definition at line 112 of file hector_costmap.h.
cv::Mat CostMapCalculation::elevation_cost_map_ [private] |
Definition at line 114 of file hector_costmap.h.
cv::Mat CostMapCalculation::elevation_map_ [private] |
Definition at line 114 of file hector_costmap.h.
cv::Mat CostMapCalculation::elevation_map_filtered [private] |
Definition at line 114 of file hector_costmap.h.
std::string CostMapCalculation::elevation_map_topic [private] |
Definition at line 116 of file hector_costmap.h.
int CostMapCalculation::elevation_zero_level [private] |
Definition at line 102 of file hector_costmap.h.
cv::Mat CostMapCalculation::grid_map_ [private] |
Definition at line 114 of file hector_costmap.h.
nav_msgs::OccupancyGridConstPtr CostMapCalculation::grid_map_msg_ [private] |
Definition at line 110 of file hector_costmap.h.
std::string CostMapCalculation::grid_map_topic [private] |
Definition at line 116 of file hector_costmap.h.
double CostMapCalculation::grid_res_z [private] |
Definition at line 101 of file hector_costmap.h.
double CostMapCalculation::initial_free_cells_radius [private] |
Definition at line 100 of file hector_costmap.h.
Definition at line 94 of file hector_costmap.h.
std::string CostMapCalculation::local_transform_frame_id [private] |
Definition at line 117 of file hector_costmap.h.
std::string CostMapCalculation::map_frame_id [private] |
Definition at line 117 of file hector_costmap.h.
int CostMapCalculation::max_clear_size [private] |
Definition at line 105 of file hector_costmap.h.
double CostMapCalculation::max_delta_elevation [private] |
Definition at line 103 of file hector_costmap.h.
Eigen::Vector2i CostMapCalculation::max_index [private] |
Definition at line 119 of file hector_costmap.h.
Eigen::Vector2i CostMapCalculation::min_index [private] |
Definition at line 119 of file hector_costmap.h.
ros::NodeHandle CostMapCalculation::nHandle [private] |
Definition at line 80 of file hector_costmap.h.
ros::NodeHandle CostMapCalculation::pnHandle [private] |
Definition at line 81 of file hector_costmap.h.
std::string CostMapCalculation::point_cloud_topic [private] |
Definition at line 116 of file hector_costmap.h.
Definition at line 84 of file hector_costmap.h.
Definition at line 83 of file hector_costmap.h.
bool CostMapCalculation::received_elevation_map [private] |
Definition at line 104 of file hector_costmap.h.
bool CostMapCalculation::received_grid_map [private] |
Definition at line 104 of file hector_costmap.h.
bool CostMapCalculation::received_point_cloud [private] |
Definition at line 104 of file hector_costmap.h.
pcl::PointCloud<pcl::PointXYZ>::Ptr CostMapCalculation::sliced_cloud [private] |
Definition at line 109 of file hector_costmap.h.
double CostMapCalculation::slize_max_height [private] |
Definition at line 107 of file hector_costmap.h.
double CostMapCalculation::slize_min_height [private] |
Definition at line 107 of file hector_costmap.h.
Definition at line 86 of file hector_costmap.h.
Definition at line 87 of file hector_costmap.h.
Definition at line 90 of file hector_costmap.h.
Definition at line 88 of file hector_costmap.h.
Definition at line 89 of file hector_costmap.h.
std::string CostMapCalculation::sys_msg_topic [private] |
Definition at line 116 of file hector_costmap.h.
ros::Timer CostMapCalculation::timer [private] |
Definition at line 96 of file hector_costmap.h.
double CostMapCalculation::update_radius_world [private] |
Definition at line 100 of file hector_costmap.h.
bool CostMapCalculation::use_cloud_map [private] |
Definition at line 104 of file hector_costmap.h.
bool CostMapCalculation::use_elevation_map [private] |
Definition at line 104 of file hector_costmap.h.
bool CostMapCalculation::use_grid_map [private] |
Definition at line 104 of file hector_costmap.h.
Definition at line 98 of file hector_costmap.h.