19#ifndef EASYNAV_NAVMAP_PLANNER__NAVMAPPLANNER_HPP_
20#define EASYNAV_NAVMAP_PLANNER__NAVMAPPLANNER_HPP_
26#include "nav_msgs/msg/path.hpp"
28#include "easynav_core/PlannerMethodBase.hpp"
29#include "navmap_core/NavMap.hpp"
30#include "easynav_common/types/NavState.hpp"
68 void update(NavState & nav_state)
override;
81 rclcpp::Publisher<nav_msgs::msg::Path>::SharedPtr
path_pub_;
87 std::vector<std::uint8_t>
occ_;
90 std::vector<double>
g_;
125 const nav_msgs::msg::Path & in_path,
126 const ::navmap::NavMap &
navmap,
129 float corner_keep_deg = 0.0f);
146 const ::navmap::NavMap & map,
147 const geometry_msgs::msg::Pose & start,
148 const geometry_msgs::msg::Pose & goal);
std::vector< Eigen::Vector3f > centroids_
Cached centroids for each NavCel (same indexing as navmap::NavMap::navcels).
Definition AStarPlanner.hpp:84
void ensure_graph_cache(const ::navmap::NavMap &map)
Ensure internal caches (centroids and A* buffers) are sized for the given map.
Definition AStarPlanner.cpp:285
void update(NavState &nav_state) override
Executes a planning cycle using the current navigation state.
Definition AStarPlanner.cpp:77
AStarPlanner()
Default constructor.
Definition AStarPlanner.cpp:50
bool continuous_replan_
Whether to replan the path at control frequency.
Definition AStarPlanner.hpp:76
double cost_axial_
Cost multiplier for axial (horizontal/vertical) moves.
Definition AStarPlanner.hpp:73
nav_msgs::msg::Path path_smoother(const nav_msgs::msg::Path &in_path, const ::navmap::NavMap &navmap, int iterations=5, float alpha=0.4f, float corner_keep_deg=0.0f)
Smooth a Path in XY while keeping every waypoint inside its original NavCel.
Definition AStarPlanner.cpp:135
std::vector< geometry_msgs::msg::Pose > a_star_path(const ::navmap::NavMap &map, const geometry_msgs::msg::Pose &start, const geometry_msgs::msg::Pose &goal)
Internal A* path planning routine.
Definition AStarPlanner.cpp:321
std::string layer_name_
Definition AStarPlanner.hpp:75
double cost_factor_
Scaling factor applied to cell cost values.
Definition AStarPlanner.hpp:71
nav_msgs::msg::Path current_path_
Most recently computed path.
Definition AStarPlanner.hpp:77
std::vector<::navmap::NavCelId > parent_
Definition AStarPlanner.hpp:91
geometry_msgs::msg::Pose current_goal_
Current goal.
Definition AStarPlanner.hpp:78
std::vector< double > g_
Reusable buffers for A* search cost and parent links.
Definition AStarPlanner.hpp:90
double cost_diagonal_
Cost multiplier for diagonal moves.
Definition AStarPlanner.hpp:74
rclcpp::Publisher< nav_msgs::msg::Path >::SharedPtr path_pub_
Publisher for the computed navigation path (for visualization or monitoring).
Definition AStarPlanner.hpp:81
virtual void on_initialize() override
Initializes the planner.
Definition AStarPlanner.cpp:62
std::vector< std::uint8_t > occ_
Cached per-NavCel occupancy / cost values (0..255).
Definition AStarPlanner.hpp:87
double inflation_penalty_
Extra cost penalty for paths near inflated obstacles.
Definition AStarPlanner.hpp:72
Definition AMCLLocalizer.hpp:41
Provides a mapping for often used cost values.
Definition cost_values.hpp:41