LCOV - code coverage report
Current view: top level - generated/include/ad/rss/world - UnstructuredSettings.hpp (source / functions) Hit Total Coverage
Test: ad_rss Lines: 74 74 100.0 %
Date: 2024-12-17 12:06:18 Functions: 5 5 100.0 %
Branches: 33 36 91.7 %

           Branch data     Line data    Source code
       1                 :            : /*
       2                 :            :  * ----------------- BEGIN LICENSE BLOCK ---------------------------------
       3                 :            :  *
       4                 :            :  * Copyright (C) 2018-2020 Intel Corporation
       5                 :            :  *
       6                 :            :  * SPDX-License-Identifier: LGPL-2.1-only
       7                 :            :  *
       8                 :            :  * ----------------- END LICENSE BLOCK -----------------------------------
       9                 :            :  */
      10                 :            : 
      11                 :            : /**
      12                 :            :  * Generated file
      13                 :            :  * @file
      14                 :            :  *
      15                 :            :  * Generator Version : 11.0.0-1997
      16                 :            :  */
      17                 :            : 
      18                 :            : #pragma once
      19                 :            : 
      20                 :            : #include <cstdint>
      21                 :            : #include <iostream>
      22                 :            : #include <limits>
      23                 :            : #include <memory>
      24                 :            : #include <sstream>
      25                 :            : #include "ad/physics/Angle.hpp"
      26                 :            : #include "ad/physics/AngularAcceleration.hpp"
      27                 :            : #include "ad/physics/Distance.hpp"
      28                 :            : #include "ad/physics/Duration.hpp"
      29                 :            : /*!
      30                 :            :  * @brief namespace ad
      31                 :            :  */
      32                 :            : namespace ad {
      33                 :            : /*!
      34                 :            :  * @brief namespace rss
      35                 :            :  */
      36                 :            : namespace rss {
      37                 :            : /*!
      38                 :            :  * @brief namespace world
      39                 :            :  */
      40                 :            : namespace world {
      41                 :            : 
      42                 :            : /*!
      43                 :            :  * \brief DataType UnstructuredSettings
      44                 :            :  *
      45                 :            :  * Parameter settings to be used for unstructured scene handling.
      46                 :            :  */
      47                 :            : struct UnstructuredSettings
      48                 :            : {
      49                 :            :   /*!
      50                 :            :    * \brief Smart pointer on UnstructuredSettings
      51                 :            :    */
      52                 :            :   typedef std::shared_ptr<UnstructuredSettings> Ptr;
      53                 :            : 
      54                 :            :   /*!
      55                 :            :    * \brief Smart pointer on constant UnstructuredSettings
      56                 :            :    */
      57                 :            :   typedef std::shared_ptr<UnstructuredSettings const> ConstPtr;
      58                 :            : 
      59                 :            :   /*!
      60                 :            :    * \brief standard constructor
      61                 :            :    */
      62                 :      25821 :   UnstructuredSettings() = default;
      63                 :            : 
      64                 :            :   /*!
      65                 :            :    * \brief standard destructor
      66                 :            :    */
      67                 :            :   ~UnstructuredSettings() = default;
      68                 :            : 
      69                 :            :   /*!
      70                 :            :    * \brief standard copy constructor
      71                 :            :    */
      72                 :            :   UnstructuredSettings(const UnstructuredSettings &other) = default;
      73                 :            : 
      74                 :            :   /*!
      75                 :            :    * \brief standard move constructor
      76                 :            :    */
      77                 :            :   UnstructuredSettings(UnstructuredSettings &&other) = default;
      78                 :            : 
      79                 :            :   /**
      80                 :            :    * \brief standard assignment operator
      81                 :            :    *
      82                 :            :    * \param[in] other Other UnstructuredSettings
      83                 :            :    *
      84                 :            :    * \returns Reference to this UnstructuredSettings.
      85                 :            :    */
      86                 :            :   UnstructuredSettings &operator=(const UnstructuredSettings &other) = default;
      87                 :            : 
      88                 :            :   /**
      89                 :            :    * \brief standard move operator
      90                 :            :    *
      91                 :            :    * \param[in] other Other UnstructuredSettings
      92                 :            :    *
      93                 :            :    * \returns Reference to this UnstructuredSettings.
      94                 :            :    */
      95                 :            :   UnstructuredSettings &operator=(UnstructuredSettings &&other) = default;
      96                 :            : 
      97                 :            :   /**
      98                 :            :    * \brief standard comparison operator
      99                 :            :    *
     100                 :            :    * \param[in] other Other UnstructuredSettings
     101                 :            :    *
     102                 :            :    * \returns \c true if both UnstructuredSettings are equal
     103                 :            :    */
     104                 :        154 :   bool operator==(const UnstructuredSettings &other) const
     105                 :            :   {
     106         [ +  + ]:        304 :     return (pedestrianTurningRadius == other.pedestrianTurningRadius) && (driveAwayMaxAngle == other.driveAwayMaxAngle)
     107   [ +  +  +  + ]:        148 :       && (vehicleYawRateChange == other.vehicleYawRateChange) && (vehicleMinRadius == other.vehicleMinRadius)
     108         [ +  + ]:        144 :       && (vehicleTrajectoryCalculationStep == other.vehicleTrajectoryCalculationStep)
     109         [ +  + ]:        142 :       && (vehicleFrontIntermediateYawRateChangeRatioSteps == other.vehicleFrontIntermediateYawRateChangeRatioSteps)
     110         [ +  + ]:        140 :       && (vehicleBackIntermediateYawRateChangeRatioSteps == other.vehicleBackIntermediateYawRateChangeRatioSteps)
     111         [ +  + ]:        138 :       && (vehicleBrakeIntermediateAccelerationSteps == other.vehicleBrakeIntermediateAccelerationSteps)
     112                 :        136 :       && (vehicleContinueForwardIntermediateAccelerationSteps
     113         [ +  + ]:        136 :           == other.vehicleContinueForwardIntermediateAccelerationSteps)
     114                 :        134 :       && (vehicleContinueForwardIntermediateYawRateChangeRatioSteps
     115         [ +  + ]:        134 :           == other.vehicleContinueForwardIntermediateYawRateChangeRatioSteps)
     116                 :        132 :       && (pedestrianContinueForwardIntermediateHeadingChangeRatioSteps
     117         [ +  + ]:        132 :           == other.pedestrianContinueForwardIntermediateHeadingChangeRatioSteps)
     118                 :        130 :       && (pedestrianContinueForwardIntermediateAccelerationSteps
     119         [ +  + ]:        130 :           == other.pedestrianContinueForwardIntermediateAccelerationSteps)
     120         [ +  + ]:        128 :       && (pedestrianBrakeIntermediateAccelerationSteps == other.pedestrianBrakeIntermediateAccelerationSteps)
     121                 :        126 :       && (pedestrianFrontIntermediateHeadingChangeRatioSteps
     122         [ +  + ]:        126 :           == other.pedestrianFrontIntermediateHeadingChangeRatioSteps)
     123   [ +  +  +  + ]:        304 :       && (pedestrianBackIntermediateHeadingChangeRatioSteps == other.pedestrianBackIntermediateHeadingChangeRatioSteps);
     124                 :            :   }
     125                 :            : 
     126                 :            :   /**
     127                 :            :    * \brief standard comparison operator
     128                 :            :    *
     129                 :            :    * \param[in] other Other UnstructuredSettings.
     130                 :            :    *
     131                 :            :    * \returns \c true if both UnstructuredSettings are different
     132                 :            :    */
     133                 :         16 :   bool operator!=(const UnstructuredSettings &other) const
     134                 :            :   {
     135                 :         16 :     return !operator==(other);
     136                 :            :   }
     137                 :            : 
     138                 :            :   /*!
     139                 :            :    * The change of heading |h'(t)| is limited.
     140                 :            :    * That means, the maximum trajectory is defined by a circle until response time.
     141                 :            :    * This parameter specifies the radius of that circle.
     142                 :            :    */
     143                 :            :   ::ad::physics::Distance pedestrianTurningRadius;
     144                 :            : 
     145                 :            :   /*!
     146                 :            :    * In certain situations the ego vehicle might be allowed to drive away from a dangerous
     147                 :            :    * object using a given heading range.
     148                 :            :    * This parameter defines the maximum possible angle the vehicle is able to drive away.
     149                 :            :    */
     150                 :            :   ::ad::physics::Angle driveAwayMaxAngle;
     151                 :            : 
     152                 :            :   /*!
     153                 :            :    * The change of the heading h'(t) is limited while the response time.
     154                 :            :    * This specifies the maximum change of the yaw rate during response time.
     155                 :            :    */
     156                 :            :   ::ad::physics::AngularAcceleration vehicleYawRateChange;
     157                 :            : 
     158                 :            :   /*!
     159                 :            :    * Defines the minimal radius a vehicle is able to drive on.
     160                 :            :    */
     161                 :            :   ::ad::physics::Distance vehicleMinRadius;
     162                 :            : 
     163                 :            :   /*!
     164                 :            :    * The current unstructured implementation calculates the location and heading based
     165                 :            :    * on time increments.
     166                 :            :    * That might lead to an increasing error the farer the point is.
     167                 :            :    * This parameter defines the time interval for this incremental calculation.
     168                 :            :    */
     169                 :            :   ::ad::physics::Duration vehicleTrajectoryCalculationStep;
     170                 :            : 
     171                 :            :   /*!
     172                 :            :    * During calculation of the trajectory set, multiple yaw rate ratios are used. The default is max left, max right and
     173                 :            :    * no yaw rate change. By specifying a value larger than zero more intermediate steps are used. The value is
     174                 :            :    * specifying the steps on one side, therefore the resulting intermedate steps are twice this value. This value is
     175                 :            :    * used for the front of the trajectory set.
     176                 :            :    */
     177                 :            :   uint32_t vehicleFrontIntermediateYawRateChangeRatioSteps{0};
     178                 :            : 
     179                 :            :   /*!
     180                 :            :    * During calculation of the trajectory set, multiple yaw rate ratios are used. The default is max left, max right and
     181                 :            :    * no yaw rate change. By specifying a value larger than zero more intermediate steps are used. The value is
     182                 :            :    * specifying the steps on one side, therefore the resulting intermedate steps are twice this value. This value is
     183                 :            :    * used for the back of the trajectory set.
     184                 :            :    */
     185                 :            :   uint32_t vehicleBackIntermediateYawRateChangeRatioSteps{0};
     186                 :            : 
     187                 :            :   /*!
     188                 :            :    * Specifies the intermediate acceleration steps (between brakeMax and brakeMin) used while calculating the cbrake
     189                 :            :    * trajectory set.
     190                 :            :    */
     191                 :            :   uint32_t vehicleBrakeIntermediateAccelerationSteps{0};
     192                 :            : 
     193                 :            :   /*!
     194                 :            :    * Specifies the intermediate acceleration steps (between brakeMin and accelMax) used while calculating the continue
     195                 :            :    * forward trajectory set.
     196                 :            :    */
     197                 :            :   uint32_t vehicleContinueForwardIntermediateAccelerationSteps{0};
     198                 :            : 
     199                 :            :   /*!
     200                 :            :    * Specifies the intermediate yaw rate change ratio steps used while calculating the continue forward trajectory set.
     201                 :            :    */
     202                 :            :   uint32_t vehicleContinueForwardIntermediateYawRateChangeRatioSteps{0};
     203                 :            : 
     204                 :            :   /*!
     205                 :            :    * Specifies the intermediate heading change ratio steps used while calculating the continue forward trajectory set.
     206                 :            :    */
     207                 :            :   uint32_t pedestrianContinueForwardIntermediateHeadingChangeRatioSteps{0};
     208                 :            : 
     209                 :            :   /*!
     210                 :            :    * Specifies the intermediate steps used while calculating the continue forward trajectory set.
     211                 :            :    */
     212                 :            :   uint32_t pedestrianContinueForwardIntermediateAccelerationSteps{0};
     213                 :            : 
     214                 :            :   /*!
     215                 :            :    * Specifies the intermediate steps used while calculating the brake trajectory set.
     216                 :            :    */
     217                 :            :   uint32_t pedestrianBrakeIntermediateAccelerationSteps{0};
     218                 :            : 
     219                 :            :   /*!
     220                 :            :    * During calculation of the trajectory set, multiple heading change ratios are used. The default is max left, max
     221                 :            :    * right and no heading change. By specifying a value larger than zero more intermediate steps are used. The value is
     222                 :            :    * specifying the steps on one side, therefore the resulting intermedate steps are twice this value. This value is
     223                 :            :    * used for the front of the trajectory set.
     224                 :            :    */
     225                 :            :   uint32_t pedestrianFrontIntermediateHeadingChangeRatioSteps{0};
     226                 :            : 
     227                 :            :   /*!
     228                 :            :    * During calculation of the trajectory set, multiple heading change ratios are used. The default is max left, max
     229                 :            :    * right and no yaw rate change. By specifying a value larger than zero more intermediate steps are used. The value is
     230                 :            :    * specifying the steps on one side, therefore the resulting intermedate steps are twice this value. This value is
     231                 :            :    * used for the back of the trajectory set.
     232                 :            :    */
     233                 :            :   uint32_t pedestrianBackIntermediateHeadingChangeRatioSteps{0};
     234                 :            : };
     235                 :            : 
     236                 :            : } // namespace world
     237                 :            : } // namespace rss
     238                 :            : } // namespace ad
     239                 :            : 
     240                 :            : /*!
     241                 :            :  * \brief protect the definition of functions from duplicates by typedef usage within other data types
     242                 :            :  */
     243                 :            : #ifndef GEN_GUARD_AD_RSS_WORLD_UNSTRUCTUREDSETTINGS
     244                 :            : #define GEN_GUARD_AD_RSS_WORLD_UNSTRUCTUREDSETTINGS
     245                 :            : /*!
     246                 :            :  * @brief namespace ad
     247                 :            :  */
     248                 :            : namespace ad {
     249                 :            : /*!
     250                 :            :  * @brief namespace rss
     251                 :            :  */
     252                 :            : namespace rss {
     253                 :            : /*!
     254                 :            :  * @brief namespace world
     255                 :            :  */
     256                 :            : namespace world {
     257                 :            : 
     258                 :            : /**
     259                 :            :  * \brief standard ostream operator
     260                 :            :  *
     261                 :            :  * \param[in] os The output stream to write to
     262                 :            :  * \param[in] _value UnstructuredSettings value
     263                 :            :  *
     264                 :            :  * \returns The stream object.
     265                 :            :  *
     266                 :            :  */
     267                 :    4035520 : inline std::ostream &operator<<(std::ostream &os, UnstructuredSettings const &_value)
     268                 :            : {
     269                 :    4035520 :   os << "UnstructuredSettings(";
     270                 :    4035520 :   os << "pedestrianTurningRadius:";
     271                 :    4035520 :   os << _value.pedestrianTurningRadius;
     272                 :    4035520 :   os << ",";
     273                 :    4035520 :   os << "driveAwayMaxAngle:";
     274                 :    4035520 :   os << _value.driveAwayMaxAngle;
     275                 :    4035520 :   os << ",";
     276                 :    4035520 :   os << "vehicleYawRateChange:";
     277                 :    4035520 :   os << _value.vehicleYawRateChange;
     278                 :    4035520 :   os << ",";
     279                 :    4035520 :   os << "vehicleMinRadius:";
     280                 :    4035520 :   os << _value.vehicleMinRadius;
     281                 :    4035520 :   os << ",";
     282                 :    4035520 :   os << "vehicleTrajectoryCalculationStep:";
     283                 :    4035520 :   os << _value.vehicleTrajectoryCalculationStep;
     284                 :    4035520 :   os << ",";
     285                 :    4035520 :   os << "vehicleFrontIntermediateYawRateChangeRatioSteps:";
     286                 :    4035520 :   os << _value.vehicleFrontIntermediateYawRateChangeRatioSteps;
     287                 :    4035520 :   os << ",";
     288                 :    4035520 :   os << "vehicleBackIntermediateYawRateChangeRatioSteps:";
     289                 :    4035520 :   os << _value.vehicleBackIntermediateYawRateChangeRatioSteps;
     290                 :    4035520 :   os << ",";
     291                 :    4035520 :   os << "vehicleBrakeIntermediateAccelerationSteps:";
     292                 :    4035520 :   os << _value.vehicleBrakeIntermediateAccelerationSteps;
     293                 :    4035520 :   os << ",";
     294                 :    4035520 :   os << "vehicleContinueForwardIntermediateAccelerationSteps:";
     295                 :    4035520 :   os << _value.vehicleContinueForwardIntermediateAccelerationSteps;
     296                 :    4035520 :   os << ",";
     297                 :    4035520 :   os << "vehicleContinueForwardIntermediateYawRateChangeRatioSteps:";
     298                 :    4035520 :   os << _value.vehicleContinueForwardIntermediateYawRateChangeRatioSteps;
     299                 :    4035520 :   os << ",";
     300                 :    4035520 :   os << "pedestrianContinueForwardIntermediateHeadingChangeRatioSteps:";
     301                 :    4035520 :   os << _value.pedestrianContinueForwardIntermediateHeadingChangeRatioSteps;
     302                 :    4035520 :   os << ",";
     303                 :    4035520 :   os << "pedestrianContinueForwardIntermediateAccelerationSteps:";
     304                 :    4035520 :   os << _value.pedestrianContinueForwardIntermediateAccelerationSteps;
     305                 :    4035520 :   os << ",";
     306                 :    4035520 :   os << "pedestrianBrakeIntermediateAccelerationSteps:";
     307                 :    4035520 :   os << _value.pedestrianBrakeIntermediateAccelerationSteps;
     308                 :    4035520 :   os << ",";
     309                 :    4035520 :   os << "pedestrianFrontIntermediateHeadingChangeRatioSteps:";
     310                 :    4035520 :   os << _value.pedestrianFrontIntermediateHeadingChangeRatioSteps;
     311                 :    4035520 :   os << ",";
     312                 :    4035520 :   os << "pedestrianBackIntermediateHeadingChangeRatioSteps:";
     313                 :    4035520 :   os << _value.pedestrianBackIntermediateHeadingChangeRatioSteps;
     314                 :    4035520 :   os << ")";
     315                 :    4035520 :   return os;
     316                 :            : }
     317                 :            : 
     318                 :            : } // namespace world
     319                 :            : } // namespace rss
     320                 :            : } // namespace ad
     321                 :            : 
     322                 :            : namespace std {
     323                 :            : /*!
     324                 :            :  * \brief overload of the std::to_string for UnstructuredSettings
     325                 :            :  */
     326                 :          1 : inline std::string to_string(::ad::rss::world::UnstructuredSettings const &value)
     327                 :            : {
     328         [ +  - ]:          2 :   stringstream sstream;
     329         [ +  - ]:          1 :   sstream << value;
     330         [ +  - ]:          2 :   return sstream.str();
     331                 :            : }
     332                 :            : } // namespace std
     333                 :            : #endif // GEN_GUARD_AD_RSS_WORLD_UNSTRUCTUREDSETTINGS

Generated by: LCOV version 1.14