Skip to content

Commit

Permalink
feat(lanelet2_extension): add road empty warning
Browse files Browse the repository at this point in the history
Signed-off-by: Shumpei Wakabayashi <shumpei.wakabayashi@tier4.jp>
  • Loading branch information
shmpwk committed Jul 3, 2022
1 parent 0a17fe3 commit 63190eb
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions map/lanelet2_extension/lib/visualization.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -803,6 +803,11 @@ visualization_msgs::msg::MarkerArray visualization::generateLaneletIdMarker(
const lanelet::ConstLanelets road_lanelets, const std_msgs::msg::ColorRGBA c, const double scale)
{
visualization_msgs::msg::MarkerArray markers;
if (road_lanelets.empty()) {
RCLCPP_WARN_STREAM(
rclcpp::get_logger("lanelet2_extension.query"),
"No road found in lanelet map. Thus vector map will not appear on Rviz.");
}
for (const auto & ll : road_lanelets) {
visualization_msgs::msg::Marker marker;
marker.header.frame_id = "map";
Expand Down

0 comments on commit 63190eb

Please sign in to comment.