gwnavruntime/world/botconfig.h Source File

botconfig.h
Go to the documentation of this file.
1 /*
2 * Copyright 2015 Autodesk, Inc. All rights reserved.
3 * Use of this software is subject to the terms of the Autodesk license agreement and any attachments or Appendices thereto provided at the time of installation or download,
4 * or which otherwise accompanies this software in either electronic or hard copy form, or which is signed by you and accepted by Autodesk.
5 */
6 
7 // primary contact: LAPA - secondary contact: NOBODY
8 #ifndef Navigation_BotConfig_H
9 #define Navigation_BotConfig_H
10 
21 
22 
23 namespace Kaim
24 {
25 
29 enum TrajectoryMode
30 {
31  TrajectoryMode_Shortcut = 0,
32  TrajectoryMode_Spline = 1
33 };
34 
42 {
43  TrajectoryFailureMode_Safe = 0,
44  TrajectoryFailureMode_Unsafe = 1
45 };
46 
49 class BotConfig: public RefCountBase<BotConfig, MemStat_Bot>
50 {
51 public:
52  BotConfig() { SetDefaults(); }
53 
54  void SetDefaults();
55 
56 public:
57  // ------------ Deprecated functions ----------
58  // Please access m_trajectoryMode directly
59 
60  KY_DEPRECATED(void SetTrajectoryMode(TrajectoryMode trajectoryMode)) { m_trajectoryMode = trajectoryMode; }
61  KY_DEPRECATED(TrajectoryMode GetTrajectoryMode() const) { return m_trajectoryMode; }
62 
63 public:
64  // ------------------- Shape Config -------------------
65 
69 
73 
74  // ------------------- Trajectory Mode -------------------
75 
79 
80  // ------------------- PathFind Config -------------------
81 
83  PathFinderConfig m_pathFinderConfig;
84 
88  ChannelComputerConfig m_channelComputerConfig;
89 
90  // ------------------- Path Progress Config -------------------
91 
93  PathProgressConfig m_pathProgressConfig;
94 
95  // ------------------- Trajectory Config -------------------
96 
102 
107 
110 
113 
114  // ------------------- Advanced Trajectory Config -------------------
115 
120 
121  // ------------------- Trajectory Avoidance Config -------------------
122 
125  bool m_enableAvoidance;
126 
129 
132 };
133 
135 KY_INLINE void BotConfig::SetDefaults()
136 {
137  m_radius = 0.0f;
138  m_height = 0.0f;
140  m_trajectoryMode = TrajectoryMode_Shortcut;
141 
142  m_pathFinderConfig.SetDefaults();
143 
144  m_pathProgressConfig.SetDefaults();
147  m_trajectoryFailureMode = TrajectoryFailureMode_Safe;
148  m_shortcutTrajectoryConfig.SetDefaults();
149  m_splineTrajectoryConfig.SetDefaults();
151 
152  m_enableAvoidance = false;
154  m_avoidanceConfig.SetDefaults();
155 }
157 } // namespace Kaim
158 
159 #endif
TrajectoryMode
Enum that defines the 2 possible trajectories modes.
Definition: botconfig.h:31
KyFloat32 m_maxDesiredLinearSpeed
The maximal linear speed for the Bot.
Definition: botconfig.h:134
TrajectoryMode m_trajectoryMode
Choose Trajectory mode between Shortcut (Straight Line) and Spline (CircleArcSpline, also activate Channel computation with Path)
Definition: botconfig.h:96
Set of parameters used to configure AvoidanceComputer.
Definition: avoidanceconfig.h:117
Class that configures how the Bot collects colliders (other bots, obstacles) around.
Definition: collidercollectorconfig.h:19
AvoidanceConfig m_avoidanceConfig
Configure the avoidance.
Definition: botconfig.h:172
TrajectoryFailureMode
Enum that defines the 2 possible behaviors in case Trajectory cannot follow the path e...
Definition: botconfig.h:43
ChannelComputerConfig m_channelComputerConfig
Configure the channel computation, relevant when in TrajectoryMode_Spline.
Definition: botconfig.h:112
PathProgressConfig m_pathProgressConfig
Configures how the Bot progress on Path.
Definition: botconfig.h:121
KyFloat32 m_trajectoryMinimalMoveDistance
The Trajectory velocity computation returns zero when the distance between the bot position and the t...
Definition: botconfig.h:156
KyFloat32 m_radius
The Bot radius in meter.
Definition: botconfig.h:82
TrajectoryFailureMode m_trajectoryFailureMode
Choose between Safe or Unsafe behavior when Trajectory cannot follow the Path.
Definition: botconfig.h:139
SplineTrajectoryConfig m_splineTrajectoryConfig
Configures the TrajectoryMode_Spline mode.
Definition: botconfig.h:145
Class that configures how the trajectory is computed from the Channel.
Definition: splinetrajectoryconfig.h:31
bool m_enableAvoidance
Enable the Bot avoidance of other Bots and Obstacles.
Definition: botconfig.h:166
KyFloat32 m_height
The Bot height in meter.
Definition: botconfig.h:86
Definition: gamekitcrowddispersion.h:20
#define KY_DEPRECATED(f)
Macro to mark a function, class or method as deprecated.
Definition: types.h:289
void SetDefaults()
Sets all members to their default value.
Definition: collidercollectorconfig.h:28
Class that aggregates all parameters that allow to configure the PathFinding and the PathFollowing of...
Definition: botconfig.h:52
PathFinderConfig m_pathFinderConfig
Configure the Bot pathfinding.
Definition: botconfig.h:105
Set of parameters used by the ShortcutTrajectory and TargetOnPathComputer classes to update Bot targe...
Definition: shortcuttrajectoryconfig.h:109
ShortcutTrajectoryConfig m_shortcutTrajectoryConfig
Configures the TrajectoryMode_Shortcut mode.
Definition: botconfig.h:142
float KyFloat32
Type used internally to represent a 32-bit floating-point number.
Definition: types.h:43
ColliderCollectorConfig m_colliderCollectorConfig
Advanced settings which tell how Bot collects potential colliders (other bots, obstacles) ...
Definition: botconfig.h:169