VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
pagedLodTerrainSourcePager.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 
24 {
25 public:
26 
28  DtVantageTerrainEngine* terrainEngine,
29  osg::Group* rootNode,
30  makVrf::DtSurfaceCharacteristicMapConstPtr surfaceCharacterMap);
31 
32  //DtPagedLodTerrainSourcePager(
37 
38  virtual ~DtPagedLodTerrainSourcePager() override;
39 
42 
43  virtual bool pageInGeometry(
44  const DtTerrainPagingGeometryPtr geometry,
45  DtTerrainIntersectIDType intersectId = 0) override;
46 
47  virtual bool pageOutNodes(std::list<DtNodeId>& nodesToRemove) override;
48 
50  virtual void updatePageTracker(DtTerrainIntersectIDType intersectId = 0) override;
51 
52  virtual const NodePagingRecordMap& pagedInNodes() const;
53 
54  virtual DtString type() const override;
55 
58  static DtTerrainSourcePager* terrainChooserFunction(
59  osg::Node& node,
60  DtVantageTerrainEngine* terrainEngine,
61  makVrf::DtSurfaceCharacteristicMapConstPtr surfaceCharacterMap);
62 
63 protected:
65  osg::Node* terrainRoot();
66 
67  virtual bool pageInData(
68  DtPageInVisitor& visitor,
69  DtTerrainIntersectIDType intersectId = 0);
70 
71 protected:
74  {
75  public:
77 
78  explicit DtActivePageVisitor(
79  const NodePagingRecordMap&, DtTerrainIntersectIDType intersectId = 0);
80 
81  virtual void apply(osg::Group& node) override;
82  virtual void apply(osg::LOD& node) override;
83  virtual void apply(osg::PagedLOD& node) override;
84 
85  private:
87  };
88 
91  osg::Matrix myMatrix;
92 
95 
97 
98 };
99 
std::shared_ptr< const DtSurfaceCharacteristicMap > DtSurfaceCharacteristicMapConstPtr
Definition: surfaceCharacteristicsMap.h:36
virtual void apply(osg::Transform &node) override
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:56
std::unordered_map< std::string, NodePagingRecord > NodePagingRecordMap
Definition: vantageTerrainImplementationUtil.h:103
const NodePagingRecordMap & myPagedInNodes
Definition: pagedLodTerrainSourcePager.h:86
unsigned long long DtTerrainIntersectIDType
Definition: terrainInterfaceDefines.h:28
virtual DtString type() const =0
virtual DtTerrainSourceTracker * createTerrainSourceTracker(DtVantageTerrainEngine *)=0
Creates and returns a DtTerrainSourceTracker.
NodePagingRecordMap myPagedInNodes
Holds all the nodes which have been paged in.
Definition: pagedLodTerrainSourcePager.h:94
Visitor class used to find the active paged of a OSG scene graph.
Definition: pagedLodTerrainSourcePager.h:73
std::shared_ptr< DtTerrainPagingGeometry > DtTerrainPagingGeometryPtr
Definition: terrainPagingGeometry.h:46
A DtPagedLodTerrainSourcePager pages in data from a specific terrain patch.
Definition: pagedLodTerrainSourcePager.h:22
Visitor class used to find the active paged of a OSG scene graph.
Definition: boundingVolumeTerrainSourcePager.h:48
OSG Visitor class which pages the highest level of detail of paged LOD nodes in. This is a base class...
Definition: pageInVisitor.h:71
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...
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
osg::ref_ptr< osg::Node > myRootNode
The node on which this pager operates.
Definition: pagedLodTerrainSourcePager.h:90
makVrf::DtSurfaceCharacteristicMapConstPtr mySurfaceCharacterMap
Definition: pagedLodTerrainSourcePager.h:96
virtual void updatePageTracker(DtTerrainIntersectIDType intersectId=0) override=0
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:112
osg::Matrix myMatrix
Definition: pagedLodTerrainSourcePager.h:91

Document ID: Generated on Thu Oct 23 22:29:17 EDT 2025 from SVN revision 280951
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)