VR-Forces Development_Version Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members | Public Member Functions | Static Protected Member Functions | Protected Attributes
DtPreloadCommandManager Class Reference

Each tick, the preload command manager takes any new preload geometry that has been added to its queue and calls pageInData on the active page tracker. More...

Public Member Functions

 DtPreloadCommandManager (DtActivePageTracker *pageTracker, const int defaultPriority)
 ~DtPreloadCommandManager ()
virtual void tick ()
 While myGeometryQueue is not empty, call pageInData on the active page tracker.
virtual void addPreloadGeometry (const DtTerrainPagingGeometryList &geometryList, DtTerrainIntersectIDType intersectId)
 Add goemetry to be paged in.
virtual void startPreloadCommandThread ()
 Starts the execution of a separate thread that will handle terrain paging.
void stopPreloadCommandThread ()
 Stop the external thread.
bool threadShouldExit () const
 Called by the thread.
void shutdown ()
 Start shutdown but don't block.

Static Protected Member Functions

static void threadMain (DtPreloadCommandManager *commandManager)

Protected Attributes

DtActivePageTrackermyPageTracker
 page tracker to call pageInData on.
DtPreloadGeometryQueue myGeometryQueue
 Geometry is put on this queue and processed each tick.
int myDefaultPreloadPriority
 The default priority to call with pageInData if not supplied with the preload geometry.
std::auto_ptr< tbb::tbb_thread > myPreloadCommandThread
tbb::mutex myShutdownMutex
bool myThreadShutdown

Detailed Description

Each tick, the preload command manager takes any new preload geometry that has been added to its queue and calls pageInData on the active page tracker.

Constructor & Destructor Documentation

DtPreloadCommandManager::DtPreloadCommandManager ( DtActivePageTracker pageTracker,
const int  defaultPriority 
)
DtPreloadCommandManager::~DtPreloadCommandManager ( )

Member Function Documentation

virtual void DtPreloadCommandManager::tick ( )
virtual

While myGeometryQueue is not empty, call pageInData on the active page tracker.

virtual void DtPreloadCommandManager::addPreloadGeometry ( const DtTerrainPagingGeometryList geometryList,
DtTerrainIntersectIDType  intersectId 
)
virtual

Add goemetry to be paged in.

Parameters
geometryListThe geometry to add
intersectIdThe intersectId to use for the paged in geometry.
virtual void DtPreloadCommandManager::startPreloadCommandThread ( )
virtual

Starts the execution of a separate thread that will handle terrain paging.

void DtPreloadCommandManager::stopPreloadCommandThread ( )

Stop the external thread.

Blocks until the thread has been shut down. Non-virtual becuase it is called by the destructor.

bool DtPreloadCommandManager::threadShouldExit ( ) const

Called by the thread.

Returns true if the thread should exit, as indicated myThreadShutdown

void DtPreloadCommandManager::shutdown ( )

Start shutdown but don't block.

static void DtPreloadCommandManager::threadMain ( DtPreloadCommandManager commandManager)
staticprotected

Member Data Documentation

DtActivePageTracker* DtPreloadCommandManager::myPageTracker
protected

page tracker to call pageInData on.

DtPreloadGeometryQueue DtPreloadCommandManager::myGeometryQueue
protected

Geometry is put on this queue and processed each tick.

int DtPreloadCommandManager::myDefaultPreloadPriority
protected

The default priority to call with pageInData if not supplied with the preload geometry.

std::auto_ptr<tbb::tbb_thread> DtPreloadCommandManager::myPreloadCommandThread
protected
tbb::mutex DtPreloadCommandManager::myShutdownMutex
mutableprotected
bool DtPreloadCommandManager::myThreadShutdown
protected

The documentation for this class was generated from the following file:

Document ID: Generated on Mon Jul 4 01:00:18 EDT 2016 from SVN revision 166489
Copyright © 2005-2015 VT MÄK. All Rights Reserved (www.mak.com)