VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
threeDTileTerrainSourcePager.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2021 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
6 #pragma once
7 
10 
12 
17 
18 #include <set>
19 
20 namespace osgEarth
21 {
22  namespace Contrib
23  {
24  namespace ThreeDTiles
25  {
26  class ThreeDTileNode;
27  class ThreeDTilesetNode;
28  class ThreeDTilesetContentNode;
29  class Tile;
30  }
31  }
32 }
33 namespace osgDb
34 {
35  class Options;
36 }
37 
41 {
42 public:
43  typedef std::map<std::string, NodePagingRecord> NodePagingRecordMap;
44 
46  DtThreeDTileTerrainSourcePager(DtVantageTerrainEngine* terrainEngine, osg::Group* rootNode, makVrf::DtSurfaceCharacteristicMapConstPtr surfaceCharacterMap);
47 
50 
53 
55  virtual bool pageInGeometry(const DtTerrainPagingGeometryPtr geometry, DtTerrainIntersectIDType intersectId = 0);
56 
58  virtual bool pageOutNodes(std::list<DtNodeId>& nodesToRemove);
59 
61  virtual void updatePageTracker(DtTerrainIntersectIDType intersectId = 0);
62 
64  virtual const NodePagingRecordMap& pagedInNodes() const;
65 
68  static DtTerrainSourcePager* terrainChooserFunction(osg::Node& node, DtVantageTerrainEngine* terrainEngine, makVrf::DtSurfaceCharacteristicMapConstPtr surfaceCharacterMap);
69 
70 protected:
72  osg::Node* terrainRoot();
73 
74 protected:
77  {
78  public:
80 
81  explicit DtActivePageVisitor(const NodePagingRecordMap&, float geometricError, DtTerrainIntersectIDType intersectId = 0);
82 
83  virtual void apply(osg::Group& node);
84 
85  protected:
87  virtual void findPageInPageOutBounds(const osgEarth::Contrib::ThreeDTiles::Tile* tile, const osgDB::Options* options);
89  virtual void findPageInPageOutSub(const osgEarth::Contrib::ThreeDTiles::Tile* tile);
90  private:
93  };
94 
97  osg::Matrix myMatrix;
98 
101 
103 
109 
110 };
111 
NodePagingRecordMap myPagedInNodes
Holds all the nodes which have been paged in.
Definition: threeDTileTerrainSourcePager.h:100
DtBoost::shared_ptr< DtTerrainPagingGeometry > DtTerrainPagingGeometryPtr
Definition: terrainPagingGeometry.h:46
DtThreeDTileTerrainSourcePager is a derived terrainSourcePager that handles a source such as 3d tile...
Definition: threeDTileTerrainSourcePager.h:39
float myGeometricError
Definition: threeDTileTerrainSourcePager.h:92
virtual bool pageOutNodes(std::list< DtNodeId > &nodesToRemove)=0
This function must cause the page out of the nodeIds specified. It should return true when successful...
DtTerrainSourcePager is the base class for terrain pagers. There will be one terrainSourcePager per t...
Definition: terrainSourcePager.h:58
const NodePagingRecordMap & myPagedInNodes
Definition: threeDTileTerrainSourcePager.h:91
virtual void updatePageTracker(DtTerrainIntersectIDType intersectId=0)=0
osg::Matrix myMatrix
Definition: threeDTileTerrainSourcePager.h:97
unsigned long long DtTerrainIntersectIDType
Definition: terrainInterfaceDefines.h:28
virtual DtTerrainSourceTracker * createTerrainSourceTracker(DtVantageTerrainEngine *)=0
Creates and returns a DtTerrainSourceTracker.
Visitor class used to find the active paged of a OSG scene graph.
Definition: threeDTileTerrainSourcePager.h:76
DtBoost::shared_ptr< const DtSurfaceCharacteristicMap > DtSurfaceCharacteristicMapConstPtr
Definition: surfaceCharacteristicsMap.h:31
std::map< std::string, NodePagingRecord > NodePagingRecordMap
Definition: threeDTileTerrainSourcePager.h:43
Visitor class used to find the active paged of a OSG scene graph.
Definition: boundingVolumeTerrainSourcePager.h:48
Base class for Terrain Source trackers. Determines if the necessary data To perform an intersection i...
Definition: terrainSourceTracker.h:75
virtual bool pageInGeometry(const DtTerrainPagingGeometryPtr geometry, DtTerrainIntersectIDType intersectId=0)=0
This function must page in all the geometry specified by the argument, and return true when successfu...
float myGeometricError
3Dtile geometric error (set this in the earth file with &lt;ThreeDTiles vrfsim:geometricError=2.0&gt; it will limit the resolution of the geometry loaded if you don&#39;t set it -1 (it will load everything) set to a value from 0.01 to 15.0
Definition: threeDTileTerrainSourcePager.h:108
makVrf::DtSurfaceCharacteristicMapConstPtr mySurfaceCharacterMap
Definition: threeDTileTerrainSourcePager.h:102
DtBoundingVolumeTerrainSourcePager is a derived terrainSourcePager that handles a source such as meta...
Definition: boundingVolumeTerrainSourcePager.h:21
#define DT_DLL_vantageTerrainImplementation
This file is used to determine how to build.
Definition: vantageTerrainImplementationDefines.h:28
virtual void apply(osg::Transform &node)
This class wraps the VR-Vantage Display Engine, and uses as a terrain loader and intersector. This is the terrain engine that powers the DtVantageTerrainImplementation. The DtVantageTerrainEngine runs the DtDe it its own thread, and processes commands thought the command queue.
Definition: vantageTerrainEngine.h:109
osg::ref_ptr< osg::Node > myRootNode
The node on which this pager operates.
Definition: threeDTileTerrainSourcePager.h:96

Document ID: Generated on Wed Mar 27 22:49:11 EDT 2024 from SVN revision 264633
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)