Skip to content

Commit c468cc5

Browse files
kosuke55HansRobo
authored andcommitted
feat(motion_utils): use setLongitudinalVelocity in insertStopPoint for PathPointWithLaneId (autowarefoundation#2206)
Signed-off-by: kosuke55 <[email protected]> Signed-off-by: kosuke55 <[email protected]> Signed-off-by: Kotaro Yoshimoto <[email protected]>
1 parent bd76aee commit c468cc5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

common/motion_utils/include/motion_utils/trajectory/trajectory.hpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -1066,7 +1066,7 @@ inline boost::optional<size_t> insertStopPoint(
10661066
}
10671067

10681068
for (size_t i = *stop_idx; i < points_with_twist.size(); ++i) {
1069-
points_with_twist.at(i).longitudinal_velocity_mps = 0.0;
1069+
tier4_autoware_utils::setLongitudinalVelocity(0.0, points_with_twist.at(i));
10701070
}
10711071

10721072
return stop_idx;
@@ -1099,7 +1099,7 @@ inline boost::optional<size_t> insertStopPoint(
10991099
}
11001100

11011101
for (size_t i = *stop_idx; i < points_with_twist.size(); ++i) {
1102-
points_with_twist.at(i).longitudinal_velocity_mps = 0.0;
1102+
tier4_autoware_utils::setLongitudinalVelocity(0.0, points_with_twist.at(i));
11031103
}
11041104

11051105
return stop_idx;

0 commit comments

Comments
 (0)