14 #include "matrix/vlVector.h"
36 NavigationMethodShortcut = 0,
37 NavigationMethodSpline = 1
43 : myNavigationMethod(NavigationMethodShortcut)
44 , myUseAbstractGraph(true)
45 , myMinAbstractGraphReplanDistance(100.)
46 , myPropagationBoxExtent(200.)
48 , myEnablePathPlanTiming(false)
73 : myEnableAvoidance(true)
75 , myEnableSlowDown(true)
76 , myEnablePushThrough(false)
77 , myEnableNavigation(true)
78 , myCollisionLookaheadTime(15.)
79 , myCollisionDetectionRadius(15.)
80 , myAngleEvalSpan(120)
81 , myNumAngleSamples(30)
82 , mySafetyDistance((float)0.1)
83 , myCollisionAvoidanceInfluence((float)0.8)
102 static void setNavBotCreatorFcn(DtNavBotCreatorFcn fcn);
107 NavigationConfiguration navConfig = NavigationConfiguration(),
108 CollisionAvoidanceConfiguration collAvoidConfig = CollisionAvoidanceConfiguration()) = 0;
110 virtual void setPosition(
const DtVector& localPos) = 0;
111 virtual void setPositionInvalid() = 0;
113 virtual void botUpdate(
const DtVector& localPos,
double dT) = 0;
115 virtual void setDestination(
const DtVector& localPos,
bool forceOutsideArea =
false) = 0;
116 virtual void setDesiredSpeed(
double speed) = 0;
117 virtual void clearFollowedPath() = 0;
118 virtual void clearDestination() = 0;
119 virtual DtVector currentDestination()
const = 0;
121 virtual void resetDestination() = 0;
123 virtual int getTriangleIndex()
const = 0;
125 virtual DtVector getPointOnTriangle(
const DtVector& localLocation)
const = 0;
127 virtual DtVector getOutputVelocity() = 0;
129 typedef bool (*DtNavBotPathLocationEvalFcn)(
const DtNavTag& navTag,
float slope,
float elevationChange,
float* costMultiplier,
void* userData);
131 virtual void setPathEvalFcn(DtNavBotPathLocationEvalFcn fcn,
void* user) = 0;
146 virtual PathStatus pathStatus(
double atDistance) = 0;
148 virtual DtString pathStatusString() = 0;
150 virtual bool hasArrived(
double arrivalDistance) = 0;
152 virtual bool currentPath(std::vector<DtVector>& path) = 0;
153 virtual bool abstractPath(std::vector<DtVector>& path) = 0;
162 virtual unsigned currentAbstractPathIndex() = 0;
168 virtual DtNavTag upcomingNavTagOnPath()
const = 0;
175 virtual void setCollisionAvoidanceEnabled(
bool enable) = 0;
177 virtual void setNavigationMethod(NavigationMethod navMethod) = 0;
178 virtual NavigationMethod navigationMethod()
const = 0;
182 virtual DtVector performMovement(
double dt) = 0;
float myCollisionAvoidanceInfluence
Definition: navBot.h:96
Has a valid path to move along.
Definition: navBot.h:138
bool myEnablePushThrough
Definition: navBot.h:89
static DtNavBotCreatorFcn theNavBotCreatorFcn
Definition: navBot.h:189
float mySafetyDistance
Definition: navBot.h:95
bool myEnableAvoidance
Definition: navBot.h:86
Has arrived at destination.
Definition: navBot.h:139
Not actively trying to move.
Definition: navBot.h:136
double myMinAbstractGraphReplanDistance
Only relevant if using abstract graphs. Entity will replan when the distance to the current abstract ...
Definition: navBot.h:57
VR-Forces wrapper for Gameware NavTag. Note: This class keeps only a pointer to the data...
Definition: navDataTag.h:87
bool myEnableSlowDown
Definition: navBot.h:88
bool myEnablePathPlanTiming
For debugging and performance testing. Prints the time it takes to perform path planning.
Definition: navBot.h:66
This is a rw class to save out a block of generic binary data.
Definition: rwBinaryData.h:18
NavigationConfiguration()
Definition: navBot.h:42
std::vector< DtNavTagAndLocation > DtNavTagAndLocationList
Definition: navBot.h:28
float myCollisionLookaheadTime
Definition: navBot.h:91
bool myEnableNavigation
Definition: navBot.h:90
double myRadiusFactor
Factor multiplied by the bounding volume radius to generate the nav bot's radius. Increasing this wil...
Definition: navBot.h:64
Failed to calculate a path.
Definition: navBot.h:140
float myAngleEvalSpan
Definition: navBot.h:93
DT_DLL_VRVCORE double distance(const makVrv::DtCoordinateSystem &, const DtVector &from, const DtVector &to)
Returns the distance from the two points. Coordinates are in local database coordinates The coordinat...
int myNumAngleSamples
Definition: navBot.h:94
This class contains all the data and logic for navigation within a specific area. Nav Data may be loa...
Definition: navArea.h:206
DtVector location
Definition: navBot.h:23
Currently computing a path.
Definition: navBot.h:137
Failed to calculate a path, destination is outside nav.
Definition: navBot.h:143
float myCollisionDetectionRadius
Definition: navBot.h:92
DtNavTag navTag
Definition: navBot.h:22
unsigned int DtNavigationPriorityType
Definition: navBot.h:29
CollisionAvoidanceConfiguration()
Sets defaults.
Definition: navBot.h:72
DT_DLL_DEBUGDRAWRENDERER void init(makVrv::DtDe &de)
Work function for the plugin initialization.
double myPropagationBoxExtent
Determines the size of the box used for path planning. Path planning is limited to the 2d box created...
Definition: navBot.h:61
#define DT_DLL_vrfNavigation
This file is used to determine how to build.
Definition: vrfNavigationDefines.h:26
virtual ~DtNavBot()
Definition: navBot.h:104
PathStatus
Definition: navBot.h:133
bool myEnableStop
Definition: navBot.h:87
Calculating a transition point.
Definition: navBot.h:142
DtNavTagAndLocation()
Definition: navBot.h:26
DtNavTagAndLocation(const DtNavTag &t, const DtVector &l)
Definition: navBot.h:25
NavigationMethod myNavigationMethod
Definition: navBot.h:51
bool myUseAbstractGraph
Indicates whether the abstract graph should be used for planning. Abstract graph allows for longer pa...
Definition: navBot.h:54
NavigationMethod
Definition: navBot.h:34
Arrived at edge of area.
Definition: navBot.h:141