VR-Forces 4.3.1 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
DtTerrainPatchObjectForestManager.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2015 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 
6 #pragma once
7 
8 #include <vrvSt/vrvSt.h>
9 #include <string>
10 
11 #include <boost/unordered_map.hpp>
12 #include <boost/unordered_set.hpp>
13 
14 #include <vrvCore/DtTreeRecord.h>
15 
16 namespace osg
17 {
18  class Node;
19 }
20 
21 namespace osgEarth
22 {
23  class Map;
24  class MapNode;
25  class ModelLayer;
26 }
27 
28 namespace makVrv
29 {
30  class DtDe;
31  class DtOsgTerrainPatchObject;
32  class DtStreamedSpeedTreeForest;
33 
39  {
40  public:
44 
45  void onDataLoaded(osgEarth::Map* map, osgEarth::ModelLayer* layer,
46  osg::Node* data);
47  void onDataUnLoaded(osgEarth::Map* map, osgEarth::ModelLayer* layer,
48  osg::Node* data);
49 
50  void onLayerLoaded(osgEarth::MapNode* mapNode,
51  osgEarth::ModelLayer* layer);
52  void onLayerUnLoaded(osgEarth::MapNode* mapNode,
53  osgEarth::ModelLayer* layer);
54 
55  protected:
56  DtStreamedSpeedTreeForest* createForest(const std::string& strName);
57  bool hasForest(const std::string& strName);
58  DtStreamedSpeedTreeForest* getForest(const std::string& strName);
59  void destroyForest(const std::string& strName);
60  size_t numForests(void) const;
61  void destroyAllForests(void);
62 
63  protected:
64  static std::string getForestName(osgEarth::Map* map,
65  osgEarth::ModelLayer* layer);
66 
67  protected:
68  typedef boost::unordered_map<std::string, DtStreamedSpeedTreeForest*>
71 
73 
75  };
76 }

Document ID: Generated on Wed Jul 29 00:55:00 EDT 2015 from SVN revision 155257
Copyright © 2005-2015 VT MÄK. All Rights Reserved (www.mak.com)