ad_rss
TrajectoryPedestrian.hpp
Go to the documentation of this file.
1 // ----------------- BEGIN LICENSE BLOCK ---------------------------------
2 //
3 // Copyright (C) 2020-2021 Intel Corporation
4 //
5 // SPDX-License-Identifier: LGPL-2.1-only
6 //
7 // ----------------- END LICENSE BLOCK -----------------------------------
12 #pragma once
13 
14 #include <ad/geometry/GeometryOperation.hpp>
15 #include <ad/geometry/Types.hpp>
16 #include <ad/physics/RatioValue.hpp>
19 
23 namespace ad {
27 namespace rss {
31 namespace unstructured {
32 
37 {
38 public:
42  static const physics::Distance maxRadius;
43 
47  static const physics::Angle circleStepWidth;
48 
50  {
51  }
52 
63  ::ad::geometry::Polygon &brakePolygon,
64  ::ad::geometry::Polygon &continueForwardPolygon);
65 
66 private:
76  bool getResponseTimeTrajectoryPoints(core::RelativeObjectState const &vehicleState,
77  TrajectorySetStep &frontSide,
78  TrajectorySetStep &backSide) const;
79 
91  bool calculateTrajectoryPoint(TrajectoryPoint &currentPoint,
92  world::RssDynamics const &dynamics,
93  physics::Duration const &duration,
94  ad::physics::Acceleration const &acceleration,
95  ad::physics::RatioValue const &yawRateChangeRatio) const;
96 
107  void calculateTrajectoryPoint(TrajectoryPoint &currentPoint,
108  world::RssDynamics const &dynamics,
109  physics::Distance const &distance,
110  ad::physics::RatioValue const &angleChangeRatio) const;
111 
119  void calculateTrajectoryPointStraight(TrajectoryPoint const &currentPoint,
120  physics::Distance const &distance,
121  TrajectoryPoint &resultPoint) const;
122 
130  void calculateTrajectoryPointsStraight(physics::Distance const &distance,
131  TrajectorySetStep const &step,
132  TrajectorySetStep &resultStep) const;
133 
143  ::ad::geometry::Polygon calculateSidePolygon(core::RelativeObjectState const &vehicleState,
144  TrajectoryPoint const &finalPointMin,
145  TrajectoryPoint const &finalPointMax) const;
146 
157  bool calculateTrajectorySetsStandingStill(core::RelativeObjectState const &vehicleState,
158  physics::Duration const &timeToStop,
159  ::ad::geometry::Polygon &brakePolygon,
160  ::ad::geometry::Polygon &continueForwardPolygon) const;
161 
173  bool calculateTrajectorySetsMoving(core::RelativeObjectState const &vehicleState,
174  physics::Duration const &timeToStopSpeedMin,
175  ::ad::geometry::Polygon &brakePolygon,
176  physics::Duration const &timeToStopSpeedMax,
177  ::ad::geometry::Polygon &continueForwardPolygon) const;
178 };
179 
180 } // namespace unstructured
181 } // namespace rss
182 } // namespace ad
Calculates the trajectory sets of a pedestrian.
Definition: TrajectoryPedestrian.hpp:37
static const physics::Distance maxRadius
The maximum radius before assuming forward movement.
Definition: TrajectoryPedestrian.hpp:42
static const physics::Angle circleStepWidth
Step width while calculating points on circle.
Definition: TrajectoryPedestrian.hpp:47
bool calculateTrajectorySets(core::RelativeObjectState const &vehicleState, ::ad::geometry::Polygon &brakePolygon, ::ad::geometry::Polygon &continueForwardPolygon)
Calculate the trajectory sets for braking and continue forward behavior.
namespace ad
Definition: LateralRelativePosition.hpp:28
DataType RelativeObjectState.
Definition: RelativeObjectState.hpp:48
a point of a trajectory
Definition: TrajectoryCommon.hpp:49
Definition: TrajectoryCommon.hpp:125
DataType RssDynamics.
Definition: RssDynamics.hpp:51