VR-Forces 4.8 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes | Static Protected Attributes | Private Member Functions | Friends
makVrv::DtIndirectFeatureGeomHandler Class Reference

class used to collect geometry coming in via feature_geom and add it to the indirect engine. More...

Public Member Functions

virtual ~DtIndirectFeatureGeomHandler ()
 DTOR. More...
 
virtual void onDataPremerge (osg::Node *data)
 called before data is added to the scenegraph More...
 
virtual void onDataUnloaded (const osg::Node *data)
 called before data is deleted from the scenegraph More...
 
virtual const osg::Node * preloadModelAndRunDynamicTerrainParser (const std::string &modelName)
 loads the model and stores a reference pointer to it in the modelName to modelNode map. More...
 
virtual void markTaskFinished ()
 helper function called by async loader to update atomic counter, and signal the wait condition More...
 

Protected Types

typedef osg::ref_ptr< const
osg::Node > 
NodeRefPtr
 

Protected Member Functions

 DtIndirectFeatureGeomHandler (DtDe &de, const osgEarth::Layer &layer, const DtIndirectFadeParameters &fadeParameters, bool dynamicTerrainInstallerActive)
 CTOR. More...
 
virtual void processSubstituteModelFilterNodes (osg::Node *data)
 process point replacement features More...
 
virtual void processExtrudeGeometryFilterNodes (osg::Node *data)
 process multiple extruded geometry nodes by calling processExtrudeGeometryFilterNode for each one in the data More...
 
virtual void processExtrudeGeometryFilterNode (osgEarth::ExtrudeGeometryFilterNode *pFeatureNode, osg::Node *data)
 process the extruded geometry and add it to the geocell from a DtCellToGeoSpecificIndirectGeoMap More...
 
virtual void processSubstituteModelFilterNode (const osgEarth::SubstituteModelFilterNode *pFeatureNode, const osg::Node *data)
 Internal methods that will actually process the nodes. More...
 
virtual void processSubstituteModelFilterNodeAsGT (const osgEarth::SubstituteModelFilterNode *pFeatureNode, const osg::Group *keyNode)
 processes the model filter and adds it to a geocell obtained from the DtCellToGeoTypicalIndirectGeoMap More...
 
virtual void processSubstituteModelFilterNodeAsGS (const osgEarth::SubstituteModelFilterNode *pFeatureNode, const osg::Group *keyNode)
 processes the model filter and adds it to a geocell obtained from the DtCellToGeoSpecificIndirectGeoMap More...
 
virtual void processCustomFeatures (osg::Node *data)
 Process the tile to see if there are any custom feature nodes and add them to the indirect system if there are any. More...
 
virtual void processCustomFeature (const osgEarth::CustomFeatureNode *pFeatureNode, const osg::Node *key)
 Internal method that will actually process a single CustomFeatureNode. Called via processCustomFeatures. More...
 

Protected Attributes

DtDemyDe
 
const osgEarth::Layer & myLayer
 
DtCellToGeoTypicalIndirectGeoMapmyCellToGTIndirectGeoMap
 GeoTypical stuff. More...
 
DtIndirectModelsContainermyGTModelsContainer
 
DtCellToGeoSpecificIndirectGeoMapmyCellToGSIndirectGeoMap
 GeoSpecific stuff. More...
 
DtCellToGeoSpecificIndirectGeoMapmyCellToProceduralGSIndirectGeoMap
 Procedural stuff. More...
 
DtModelSemanticsMappermyModelSematicsMapper
 
boost::mutex myProcessedNodeMapMutex
 
boost::condition_variable myProcessedNodeMapCondition
 
std::map< std::string, NodeRefPtrmyProcessedNodeMap
 
std::map< std::string, boolmyIsProcessingNodeMap
 
tbb::atomic< intmyActiveAsyncTasks
 tracks how many threads are active from this particular instance, when 0 the tasks are done. More...
 
boost::condition_variable myWaitCondition
 signaling mutex and condition More...
 
boost::mutex myWaitMutex
 
osg::ref_ptr
< osgEarth::StateSetCache > 
myStateSetCache
 
DtIndirectFadeParameters myFadeParameters
 
bool myDynamicTerrainInstallerActive
 

Static Protected Attributes

static tbb::atomic< inttheTotalNumActiveAsyncTasks
 tracks how many total threads are active to avoid preemption More...
 

Private Member Functions

 DtIndirectFeatureGeomHandler (const DtIndirectFeatureGeomHandler &other)
 Copy Constructor not implemented – Copy Not Allowed. More...
 
DtIndirectFeatureGeomHandleroperator= (const DtIndirectFeatureGeomHandler &other)
 Assignment Operator Not implemented – Assignment Not Allowed. More...
 

Friends

class DtIndirectFeatureGeomHandlerCreator
 creator friend class so it is the only one that can create new DtIndirectFeatureGeomHandlers More...
 

Detailed Description

class used to collect geometry coming in via feature_geom and add it to the indirect engine.

will process point features (expressed as GS or GT) and extruded geometry (procedurally generated) Handles callback from a feature_geom layer in order to add indirect geometry to the scene.

Member Typedef Documentation

Constructor & Destructor Documentation

virtual makVrv::DtIndirectFeatureGeomHandler::~DtIndirectFeatureGeomHandler ( )
virtual

DTOR.

makVrv::DtIndirectFeatureGeomHandler::DtIndirectFeatureGeomHandler ( DtDe de,
const osgEarth::Layer &  layer,
const DtIndirectFadeParameters fadeParameters,
bool  dynamicTerrainInstallerActive 
)
protected

CTOR.

makVrv::DtIndirectFeatureGeomHandler::DtIndirectFeatureGeomHandler ( const DtIndirectFeatureGeomHandler other)
private

Copy Constructor not implemented – Copy Not Allowed.

Member Function Documentation

DtIndirectFeatureGeomHandler& makVrv::DtIndirectFeatureGeomHandler::operator= ( const DtIndirectFeatureGeomHandler other)
private

Assignment Operator Not implemented – Assignment Not Allowed.

virtual void makVrv::DtIndirectFeatureGeomHandler::onDataPremerge ( osg::Node *  data)
virtual

called before data is added to the scenegraph

virtual void makVrv::DtIndirectFeatureGeomHandler::onDataUnloaded ( const osg::Node *  data)
virtual

called before data is deleted from the scenegraph

virtual const osg::Node* makVrv::DtIndirectFeatureGeomHandler::preloadModelAndRunDynamicTerrainParser ( const std::string &  modelName)
virtual

loads the model and stores a reference pointer to it in the modelName to modelNode map.

also waits for other threads to finish if they are loading the same model. Returns a raw point to the model but it is saved in the member variable map so it will not be deleted in the rest of the premerge processing.

virtual void makVrv::DtIndirectFeatureGeomHandler::markTaskFinished ( )
virtual

helper function called by async loader to update atomic counter, and signal the wait condition

virtual void makVrv::DtIndirectFeatureGeomHandler::processSubstituteModelFilterNodes ( osg::Node *  data)
protectedvirtual

process point replacement features

virtual void makVrv::DtIndirectFeatureGeomHandler::processExtrudeGeometryFilterNodes ( osg::Node *  data)
protectedvirtual

process multiple extruded geometry nodes by calling processExtrudeGeometryFilterNode for each one in the data

virtual void makVrv::DtIndirectFeatureGeomHandler::processExtrudeGeometryFilterNode ( osgEarth::ExtrudeGeometryFilterNode *  pFeatureNode,
osg::Node *  data 
)
protectedvirtual

process the extruded geometry and add it to the geocell from a DtCellToGeoSpecificIndirectGeoMap

virtual void makVrv::DtIndirectFeatureGeomHandler::processSubstituteModelFilterNode ( const osgEarth::SubstituteModelFilterNode *  pFeatureNode,
const osg::Node *  data 
)
protectedvirtual

Internal methods that will actually process the nodes.

checks the instancing to see if the layer is GT (instanced) or GS (not instanced) and then calls the appropriate additional processSubstituteModelFilerNodeAs* function

virtual void makVrv::DtIndirectFeatureGeomHandler::processSubstituteModelFilterNodeAsGT ( const osgEarth::SubstituteModelFilterNode *  pFeatureNode,
const osg::Group *  keyNode 
)
protectedvirtual

processes the model filter and adds it to a geocell obtained from the DtCellToGeoTypicalIndirectGeoMap

virtual void makVrv::DtIndirectFeatureGeomHandler::processSubstituteModelFilterNodeAsGS ( const osgEarth::SubstituteModelFilterNode *  pFeatureNode,
const osg::Group *  keyNode 
)
protectedvirtual

processes the model filter and adds it to a geocell obtained from the DtCellToGeoSpecificIndirectGeoMap

virtual void makVrv::DtIndirectFeatureGeomHandler::processCustomFeatures ( osg::Node *  data)
protectedvirtual

Process the tile to see if there are any custom feature nodes and add them to the indirect system if there are any.

These come from feature_custom driver model layers

virtual void makVrv::DtIndirectFeatureGeomHandler::processCustomFeature ( const osgEarth::CustomFeatureNode pFeatureNode,
const osg::Node *  key 
)
protectedvirtual

Internal method that will actually process a single CustomFeatureNode. Called via processCustomFeatures.

Friends And Related Function Documentation

creator friend class so it is the only one that can create new DtIndirectFeatureGeomHandlers

Member Data Documentation

DtDe& makVrv::DtIndirectFeatureGeomHandler::myDe
protected
const osgEarth::Layer& makVrv::DtIndirectFeatureGeomHandler::myLayer
protected
DtCellToGeoTypicalIndirectGeoMap* makVrv::DtIndirectFeatureGeomHandler::myCellToGTIndirectGeoMap
protected

GeoTypical stuff.

DtIndirectModelsContainer* makVrv::DtIndirectFeatureGeomHandler::myGTModelsContainer
protected
DtCellToGeoSpecificIndirectGeoMap* makVrv::DtIndirectFeatureGeomHandler::myCellToGSIndirectGeoMap
protected

GeoSpecific stuff.

DtCellToGeoSpecificIndirectGeoMap* makVrv::DtIndirectFeatureGeomHandler::myCellToProceduralGSIndirectGeoMap
protected

Procedural stuff.

Is also geospecific in the sense that each tile will have its own registrar. Therefore, we need the gs variant

DtModelSemanticsMapper& makVrv::DtIndirectFeatureGeomHandler::myModelSematicsMapper
protected
boost::mutex makVrv::DtIndirectFeatureGeomHandler::myProcessedNodeMapMutex
protected
boost::condition_variable makVrv::DtIndirectFeatureGeomHandler::myProcessedNodeMapCondition
protected
std::map<std::string, NodeRefPtr > makVrv::DtIndirectFeatureGeomHandler::myProcessedNodeMap
protected
std::map<std::string, bool > makVrv::DtIndirectFeatureGeomHandler::myIsProcessingNodeMap
protected
tbb::atomic<int> makVrv::DtIndirectFeatureGeomHandler::theTotalNumActiveAsyncTasks
staticprotected

tracks how many total threads are active to avoid preemption

tbb::atomic<int> makVrv::DtIndirectFeatureGeomHandler::myActiveAsyncTasks
protected

tracks how many threads are active from this particular instance, when 0 the tasks are done.

boost::condition_variable makVrv::DtIndirectFeatureGeomHandler::myWaitCondition
protected

signaling mutex and condition

boost::mutex makVrv::DtIndirectFeatureGeomHandler::myWaitMutex
protected
osg::ref_ptr< osgEarth::StateSetCache > makVrv::DtIndirectFeatureGeomHandler::myStateSetCache
protected
DtIndirectFadeParameters makVrv::DtIndirectFeatureGeomHandler::myFadeParameters
protected
bool makVrv::DtIndirectFeatureGeomHandler::myDynamicTerrainInstallerActive
protected

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

Document ID: Generated on Thu Aug 27 10:56:05 EDT 2020 from SVN revision 217100
Copyright © 2005-2020 MAK Technologies. All Rights Reserved (www.mak.com)