This commit is contained in:
2026-03-26 12:05:20 +00:00
parent d51ecc0986
commit 03907b9613
2 changed files with 14 additions and 5 deletions

View File

@@ -14,7 +14,7 @@ namespace dock_planner
initialized_(false),
check_free_space_(false),
cost_threshold_(200),
calib_safety_distance_(0.05) {}
calib_safety_distance_(0.0) {}
/**
* @brief Constructor với parameters
@@ -28,7 +28,7 @@ namespace dock_planner
initialized_(false),
check_free_space_(false),
cost_threshold_(200),
calib_safety_distance_(0.05)
calib_safety_distance_(0.0)
{
initialize(name, costmap_robot);
}
@@ -90,7 +90,16 @@ namespace dock_planner
if(!initialized_) return false;
if(!plan.empty()) plan.clear();
vector<robot_geometry_msgs::Pose> planMoveToDock;
std::vector<robot_geometry_msgs::Point> footprint_robot = costmap_robot_->getRobotFootprint();
// std::vector<robot_geometry_msgs::Point> footprint_robot = costmap_robot_->getRobotFootprint();
std::vector<robot_geometry_msgs::Point> footprint_robot;
robot_geometry_msgs::Point p1; p1.x = 0.1; p1.y = -0.1;
robot_geometry_msgs::Point p2; p2.x = 0.1; p2.y = 0.1;
robot_geometry_msgs::Point p3; p3.x = -0.1; p3.y = 0.1;
robot_geometry_msgs::Point p4; p4.x = -0.1; p4.y = -0.1;
footprint_robot.push_back(p1);
footprint_robot.push_back(p2);
footprint_robot.push_back(p3);
footprint_robot.push_back(p4);
// footprint_dock_ = costmap_robot_->getRobotFootprint();
int degree = 2;