Skip to content

Commit

Permalink
Merge branch 'beta/v0.11.1' into visualize-curbstone-v0.11.1
Browse files Browse the repository at this point in the history
  • Loading branch information
saka1-s authored Dec 19, 2023
2 parents 8de8ef2 + c5b6dc8 commit e9474e4
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions planning/behavior_path_planner/src/utils/utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1586,6 +1586,8 @@ std::vector<lanelet::ConstPoint3d> getBoundWithHatchedRoadMarkings(
} else {
if (!polygon) {
will_close_polygon = true;
} else if (polygon.value().id() != current_polygon.value().id()) {
will_close_polygon = true;
} else {
current_polygon_border_indices.push_back(
get_corresponding_polygon_index(*current_polygon, bound_point.id()));
Expand Down Expand Up @@ -1620,6 +1622,17 @@ std::vector<lanelet::ConstPoint3d> getBoundWithHatchedRoadMarkings(
(*current_polygon)[mod(target_poly_idx, current_polygon_points_num)]);
}
}

if (polygon.has_value() && current_polygon.has_value()) {
if (polygon.value().id() != current_polygon.value().id()) {
current_polygon = polygon;
current_polygon_border_indices.clear();
current_polygon_border_indices.push_back(
get_corresponding_polygon_index(current_polygon.value(), bound_point.id()));
continue;
}
}

current_polygon = std::nullopt;
current_polygon_border_indices.clear();
}
Expand Down

0 comments on commit e9474e4

Please sign in to comment.