Skip to content

Commit

Permalink
障害物回避が上手く行かない問題の解消 (#515)
Browse files Browse the repository at this point in the history
  • Loading branch information
HansRobo authored Aug 4, 2024
1 parent 106da54 commit 7126fad
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion crane_local_planner/src/gridmap_planner.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,10 @@ std::vector<grid_map::Index> GridMapPlanner::findPathAStar(
const Point & start_point, const Point & goal_point, const std::string & layer,
const uint8_t robot_id) const
{
auto isMapInside = [&](const grid_map::Index & index) -> bool { return map.isValid(index); };
auto isMapInside = [&](const grid_map::Index & index) -> bool {
grid_map::Position p;
return map.getPosition(index, p);
};

auto isObstacle = [&](const grid_map::Index & index) -> bool {
return map.at(layer, index) >= 0.5f;
Expand Down

0 comments on commit 7126fad

Please sign in to comment.