VR-Forces 4.6.1 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 | Private Member Functions
makVrv::DtIndirectGeometryLayerManager Class Reference

Handles a layer specified in the .earth file, and using the feature_custom plugin and point features. More...

Public Member Functions

 DtIndirectGeometryLayerManager (DtDe &de)
 CTOR.
virtual ~DtIndirectGeometryLayerManager ()
 DTOR.
virtual void onDataPremerge (osg::Node *newData)
 Called when feature tile pages in.
virtual void onDataLoaded (const osg::Node *newData)
 Called when feature tile pages in.
virtual void onDataUnloaded (const osg::Node *oldData)
 Called when feature tile pages out (is about to be deleted).

Protected Types

typedef boost::unordered_map
< std::string, osg::ref_ptr
< osg::Node > > 
MapMarkerNameToModelNode
typedef
tbb::concurrent_unordered_map
< std::string, DtModelInfo
ModelsToModelInfo
 PPP: This needs to change.

Protected Member Functions

virtual void processNewFeature (const osgEarth::Features::CustomFeatureNode *pFeatureNode, const osg::Node *data)
 Internal method that will actually process the CustomFeatureNodes. Called via onDataLoaded.
virtual bool getModelNode (const std::string &modelName, osg::Node *&modelNode, int &modelId)
 Get the model node after reading the file, and the id for a model name(file) and cache it if does not exist.
virtual void registerModelWithRegistrar (const osg::Node *modelNode, const std::string &modelName, const DtModelInfo &modelInfo)
 register a new model with DtIndirectGeometryRegistrar

Protected Attributes

DtIndirectTextureCollectionPolicymyTextureCollectionPolicy
DtIndirectGeometryRegistrarmyIndirectGeometryRegistrar
DtCellToIndirectGeoMap myCellToIndirectGeoMap
MapMarkerNameToModelNode myMapMarkerNameToModelNode
Threading::Mutex myMapMarkerNameToModelNodeMutex
ModelsToModelInfo myModelsToModelInfo
tbb::atomic< intmyNextModelId
DtDemyDe

Private Member Functions

 DtIndirectGeometryLayerManager ()
 CTOR (unimplemented default CTOR)

Detailed Description

Handles a layer specified in the .earth file, and using the feature_custom plugin and point features.

Makes it so that it is rendered using indirect rendering. Contains the indirect registrar that will register the models referred to by the point features in a format that is suitable for consumption by the indirect engine. Maintains a map of each feature tile node it encounters, and a DtIndirectGeometry corresponding to it. Handles loading / unloading of the feature tile nodes This class is not used directly. It is used by the DtIndirectGeometryManager which wil maintain all the layers encountered in the .earth and invoke the methods of the corresponding layer

Member Typedef Documentation

typedef boost::unordered_map<std::string, osg::ref_ptr< osg::Node > > makVrv::DtIndirectGeometryLayerManager::MapMarkerNameToModelNode
protected
typedef tbb::concurrent_unordered_map<std::string, DtModelInfo> makVrv::DtIndirectGeometryLayerManager::ModelsToModelInfo
protected

PPP: This needs to change.

We don't need concurrency here, because the feature data callbacks and the final calls to onDataLoaded/onDataUnLoaded will occur in the main thread

Constructor & Destructor Documentation

makVrv::DtIndirectGeometryLayerManager::DtIndirectGeometryLayerManager ( DtDe de)

CTOR.

virtual makVrv::DtIndirectGeometryLayerManager::~DtIndirectGeometryLayerManager ( )
virtual

DTOR.

makVrv::DtIndirectGeometryLayerManager::DtIndirectGeometryLayerManager ( )
private

CTOR (unimplemented default CTOR)

Member Function Documentation

virtual void makVrv::DtIndirectGeometryLayerManager::onDataPremerge ( osg::Node *  newData)
virtual

Called when feature tile pages in.

Called by the DtIndirectGeometryManager before data for this layer has been added to the scenegraph from a background paging thread

virtual void makVrv::DtIndirectGeometryLayerManager::onDataLoaded ( const osg::Node *  newData)
virtual

Called when feature tile pages in.

Called by the DtIndirectGeometryManager when data for this layer is being loaded

virtual void makVrv::DtIndirectGeometryLayerManager::onDataUnloaded ( const osg::Node *  oldData)
virtual

Called when feature tile pages out (is about to be deleted).

Called by the DtIndirectGeometryManager when data for this layer is being unloaded

virtual void makVrv::DtIndirectGeometryLayerManager::processNewFeature ( const osgEarth::Features::CustomFeatureNode pFeatureNode,
const osg::Node *  data 
)
protectedvirtual

Internal method that will actually process the CustomFeatureNodes. Called via onDataLoaded.

virtual bool makVrv::DtIndirectGeometryLayerManager::getModelNode ( const std::string &  modelName,
osg::Node *&  modelNode,
int modelId 
)
protectedvirtual

Get the model node after reading the file, and the id for a model name(file) and cache it if does not exist.

Return the cached node and model id, if it exists. Will return false if the model file cannot be read (and modelNode and modelId will be 0).

virtual void makVrv::DtIndirectGeometryLayerManager::registerModelWithRegistrar ( const osg::Node *  modelNode,
const std::string &  modelName,
const DtModelInfo modelInfo 
)
protectedvirtual

register a new model with DtIndirectGeometryRegistrar

Member Data Documentation

DtIndirectTextureCollectionPolicy* makVrv::DtIndirectGeometryLayerManager::myTextureCollectionPolicy
protected
DtIndirectGeometryRegistrar* makVrv::DtIndirectGeometryLayerManager::myIndirectGeometryRegistrar
protected
DtCellToIndirectGeoMap makVrv::DtIndirectGeometryLayerManager::myCellToIndirectGeoMap
protected
MapMarkerNameToModelNode makVrv::DtIndirectGeometryLayerManager::myMapMarkerNameToModelNode
protected
Threading::Mutex makVrv::DtIndirectGeometryLayerManager::myMapMarkerNameToModelNodeMutex
protected
ModelsToModelInfo makVrv::DtIndirectGeometryLayerManager::myModelsToModelInfo
protected
tbb::atomic<int> makVrv::DtIndirectGeometryLayerManager::myNextModelId
protected
DtDe& makVrv::DtIndirectGeometryLayerManager::myDe
protected

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

Document ID: Generated on Wed Jul 25 16:57:45 EDT 2018 from SVN revision 190790
Copyright © 2005-2018 VT MÄK. All Rights Reserved (www.mak.com)