19 #include <matrix/vlVector.h>
20 #include <matrix/coordTransform.h>
30 #include <tbb/spin_mutex.h>
31 #include <tbb/task_arena.h>
32 #include <tbb/task_group.h>
53 class DtTerrainAttachedTo;
57 class DtGenericTerrainRecord;
74 static void tickCallback(
void* args);
87 return myTerrainInterface;
94 static void genericRecordLoadedCallback(
96 virtual void processGenericRecordLoaded(
104 void removeObjectNavData(
const DtSimObject* simObject);
109 virtual void unloadAllNavData();
112 virtual void revertNavData();
115 virtual void pauseNavDataRegeneration();
118 virtual void resumeNavDataRegeneration();
138 virtual void loadAllNavData(
bool* dataAvailable = 0);
152 virtual DtNavArea* findNavAreaForLocation(
const DtVector& localPosition,
const DtString& profile,
154 virtual std::vector<DtNavArea*> findNavAreasForLocation(
const DtVector& localPosition,
157 bool loadNavAreas =
true);
158 virtual std::vector<DtNavArea*> findNavAreasForArea(
const DtLocalVertexList* boundingArea,
164 virtual std::vector<DtNavArea*> findNavAreasForLocation(
const DtVector& localPosition)
const;
168 virtual void addNavAreaAboutToBeRemovedCallback(
173 virtual void removeNavAreaAboutToBeRemovedCallback(
178 virtual void setBlockingNavDataLoad(
bool b);
182 static void requestNavAreaStatusCallback(
DtSimMessage*,
void* usr);
183 virtual void processRequestNavAreaStatus();
188 static void requestSimObjectDebugPortsCallback(
DtSimMessage* msg,
void* usr);
189 virtual void processRequestSimObjectDebugPortsCallback(
DtUUID uuid);
193 virtual void sendNavDataStatus();
196 virtual void processNavQueues();
200 static void setGamewareWorkingMemorySize(
int sizeInMb);
201 static void setRegenerateNavigationDataAtRuntime(
bool regen);
202 static void setMaxRegenerationThreads(
int threads);
203 static void setNumberOfNavQueueProcessingThreads(
int threads);
204 static void setRegenerationDelay(
double delay);
205 static void setQueryTimeBudget(
double ms);
206 static void setRegenerationFileDirectory(
const DtFilename& dir);
218 virtual void processSimObjectDeleted(
const DtSimObject* simObject);
221 virtual void invokeAreaAboutToBeDeletedCallbacks(
DtNavArea*);
225 static void navigationRegenUpdateCallback(
void* usr);
226 virtual void processNavigationRegenUpdate();
229 void processUnloadTerrain();
231 virtual void updateSimOperationStatus();
233 void setBlockOnAsynchronousOperations(
bool block);
235 bool hasAsynchronousOperationsPending()
const;
250 virtual void processNavAreasTerrainChangesQueues();
261 std::shared_ptr<DtCoordTransform>
Matrix;
328 bool myNavRegenerating =
false;
329 bool myNavOperations =
false;
UUID is a unique ID wrapper class.
Definition: uuid.h:59
This class is just used to count the nav generation threads to ensure we do not start too many thread...
Definition: navArea.h:160
static int theGamewareWorkingMemorySize
Definition: vrfNavAreaManager.h:209
static int theMaxRegenerationThreads
Definition: vrfNavAreaManager.h:211
Coordinate_System * myObjectCoordSys
Coord system used for nav datas on embarked objects.
Definition: vrfNavAreaManager.h:303
bool myRegenInTempDirectory
Definition: vrfNavAreaManager.h:327
This class is used to interface with the terrain a particular entity is "attached" to...
Definition: attachedTerrain.h:57
DtTerrainInterface * myTerrainInterface
Definition: vrfNavAreaManager.h:253
std::map< DtNavArea::NavAreaId, DtNavAreaTerrainChangesQueue * > DtNavAreasTerrainChangesQueues
Definition: vrfNavAreaManager.h:284
static int theNumberOfNavQueueProcessingThreads
Definition: vrfNavAreaManager.h:212
std::map< DtNavArea::NavAreaId, navAreaExtentData > myNavAreaExtents
Definition: vrfNavAreaManager.h:272
DtDcm LocalCorrectionMatrix
Definition: vrfNavAreaManager.h:262
DtGenericTerrainRecords allow the VR-Forces terrainInterface library to instantiate and configure the...
Definition: DtGenericTerrainRecord.h:34
std::shared_ptr< DtCoordTransform > Matrix
Definition: vrfNavAreaManager.h:261
std::atomic< bool > myProcessingStopped
Definition: vrfNavAreaManager.h:321
bool myNavigationInitialized
Definition: vrfNavAreaManager.h:300
Definition: vrfNavAreaManager.h:256
DtPoint ReferencePoint
Definition: vrfNavAreaManager.h:260
std::atomic< bool > myContinueProcessing
Definition: vrfNavAreaManager.h:320
DtSimulationServices * mySimulationServices
Definition: vrfNavAreaManager.h:301
Simple asynchronous callback queue.
Definition: vrfCallbackQueue.h:29
DtNavArea::NavAreaId myNextNavAreaId
Definition: vrfNavAreaManager.h:307
The DtExtent represents an axis-aligned 3d bounding box.
Definition: extent.h:43
tbb::spin_rw_mutex myObjectNavAreaMutex
Definition: vrfNavAreaManager.h:317
bool myRegisteredForTerrainChanges
Indicates if the DtVrfNavAreaManager has a terrain notifications callback registered with the DtVanta...
Definition: vrfNavAreaManager.h:298
tbb::spin_rw_mutex myNavAreaMutex
Definition: vrfNavAreaManager.h:316
tbb::spin_mutex myNavAreaExtentsMutex
Definition: vrfNavAreaManager.h:315
DtCallbackList< DtNavArea * > NavAreaAboutToBeRemovedList
Definition: vrfNavAreaManager.h:313
std::vector< DtNavArea * > DtNavAreas
Definition: vrfNavAreaManager.h:277
std::set< DtString > Profiles
Definition: vrfNavAreaManager.h:265
DtDcm InvLocalCorrectionMatrix
Definition: vrfNavAreaManager.h:263
DtNavAreasTerrainChangesQueues myNavAreasTerrainChangesQueues
Map of queues with terrain changes - created for each nav area. The terrain changes are added to the ...
Definition: vrfNavAreaManager.h:289
bool myBlockingNavLoad
Definition: vrfNavAreaManager.h:305
tbb::task_group myNavAreaTaskGroup
Definition: vrfNavAreaManager.h:324
bool IsLoading
Definition: vrfNavAreaManager.h:266
Definition: coordSystem.h:54
#define DT_DLL_vrfobjcore
This file is used to determine how to build.
Definition: vrfobjcoreDefines.h:24
The DtVrfNavAreaManager manages all of the nav areas currently created in the sim.
Definition: vrfNavAreaManager.h:65
This class contains all the data and logic for navigation within a specific area. Nav Data may be loa...
Definition: navArea.h:205
File: simMsg.h.
Definition: simMessage.h:35
std::vector< DtFilename > SearchPaths
Definition: readerWriter.h:92
boost::signals2::connection DynamicTerrainConnection
Definition: vrfNavAreaManager.h:269
DtTerrainInterface allows access to common terrain calls without having to know the terrain implement...
Definition: terrainInterface.h:93
DtFilename filename
Definition: vrfNavAreaManager.h:258
DtVrfCallbackQueue * myNavQueryProcessingParallelQueue
Definition: vrfNavAreaManager.h:319
virtual DtTerrainInterface * terrainInterface()
The terrain interface used by this nav area manager.
Definition: vrfNavAreaManager.h:85
DtNavAreas myNavAreas
Definition: vrfNavAreaManager.h:278
Central access point of all non-object-specific the services and managers that are available for use ...
Definition: simulationServices.h:96
static double theQueryTimeBudget
Definition: vrfNavAreaManager.h:214
DtDynamicTerrainQueryHandle DynamicTerrainQuery
Definition: vrfNavAreaManager.h:268
Represents a single simulation object in the exercise. Object may be VRF simulation, or non-VRF simulated, and may be simulated by the local sim engine, or by a remote sim engine. Only public (external) state of the object is available. All data is read-only. All access to data of the object is thread safe within the simulation frame.
Definition: simObject.h:80
Contains the declaration of the DtExtent class.
unsigned int DtTerrainCategoryMask
This bitmask is made using DtTerrainCategory values.
Definition: rwTerrainCategoryMask.h:27
DT_DLL_DEBUGDRAWRENDERER void init(makVrv::DtDe &de)
Work function for the plugin initialization.
DtNavAreasLocalExtents myNavAreasLocalExtents
Map of the the nav areas extents - converted to local coordinates. It is used within the terain chage...
Definition: vrfNavAreaManager.h:293
DtCoordTransform InvMatrix
Definition: vrfNavAreaManager.h:264
The simulation engine is controlled by a single,top-level class called the Simulation Manager...
Definition: simManager.h:137
Resource handle for a query which has been added to the system. Returned from DtTerrainImplementation...
Definition: terrainImplementation.h:180
DtExtent * Extent
Definition: vrfNavAreaManager.h:267
DtNavGenerationThreadCounter * myNavGenThreadCounter
Definition: vrfNavAreaManager.h:310
NavAreaAboutToBeRemovedList myNavAreaAboutToRemRemovedList
Definition: vrfNavAreaManager.h:314
static bool theRegenerateNavDataAtRuntime
Definition: vrfNavAreaManager.h:210
std::map< DtUUID, DtNavArea * > DtObjectNavAreaMap
Definition: vrfNavAreaManager.h:280
static double theRegenerationDelay
Definition: vrfNavAreaManager.h:213
static DtFilename theRegenerationFileDirectory
Definition: vrfNavAreaManager.h:215
class DtLocalVertexList:
Definition: localVertexList.h:20
std::queue< DtTerrainChangeNotificationInfo > DtNavAreaTerrainChangesQueue
Definition: vrfNavAreaManager.h:283
std::map< DtNavArea::NavAreaId, DtExtent > DtNavAreasLocalExtents
Definition: vrfNavAreaManager.h:285
Provides information about the terrain changes: mySpatExtent defines the terrain change type - e...
Definition: terrainImplementation.h:50
boost::signals2::connection myUnloadTerrainConnection
Definition: vrfNavAreaManager.h:325
DtObjectNavAreaMap myObjectNavAreas
Definition: vrfNavAreaManager.h:281
A locally simulated VRF object.
Definition: localObject.h:98
tbb::task_arena myNavAreaArena
Definition: vrfNavAreaManager.h:323
void(* DtNavAreaRemovalCallbackFcn)(DtNavArea *area, void *usr)
Callback function definition for nav area removals.
Definition: vrfNavAreaManager.h:61