30 class DtIndirectGeometryRegistrar;
31 class DtInstanceContainer;
32 class DtOsgShaderFilesCache;
33 class DtIndirectCullPass;
34 class DtCpuCullingHelper;
99 , osg::RenderInfo& renderInfo);
104 , osg::RenderInfo& renderInfo
108 virtual void bindGpuOutputInstanceBuffer(
void)
const;
111 virtual void unbindGpuOutputInstanceBuffer(
void)
const;
118 virtual bool bindIndirectThings();
121 virtual void unbindIndirectThings();
125 virtual bool useInstanceCount(
void)
const;
129 virtual int numDrawCommands(
void)
const;
132 virtual void setShadersFolderPath(
const std::string& shaderFolderPath);
135 virtual const std::string& shadersFolderPath(
void)
const;
144 virtual void releaseGLObjects(osg::State* state)
const;
147 virtual void reloadShaders()
const;
150 virtual unsigned int maxNumInstances(
void)
const;
158 virtual bool readyToUpdateBuffers();
161 virtual bool needTextureUpdate()
const;
165 virtual void updateGpuInputInstancesBuffer();
170 virtual void updateGpuInputPerGeomInstancesBuffer();
171 virtual void updateGpuGeometrySpecificationsBuffer(
const int numGeometries);
172 virtual void updateGpuMaterialsBuffer(
const int numGeometries);
173 virtual void updateGpuGeometryOffsetAndSizeBuffer(
int& numGeometries);
174 virtual void updateGpuIndirectBuffer();
175 virtual void clearInstanceCountofGpuIndirectBuffer();
176 virtual void clearStateIdCommandCountBuffer();
181 virtual bool updateGpuTexturesBuffer(osg::RenderInfo& renderInfo);
184 virtual void updateInstancesOffsetAndInstances(
const MapIntToInt& modelIdsToNumInstances);
187 virtual void updateStateIdMaxNumCommands(
const MapIntToInt& modelIdsToNumInstances);
190 virtual bool checkSpecBuffersOk(
void)
const;
292 static const std::string& theClassName();
DtGlBuffer * myGpuStateIdToMaxNumCommandsBuffer
Definition: DtGpuCullingAndLod.h:244
Contains the DtCullShaderConfig class declaration.
handles the running of the compute shader pass for indirect culling, LODing and switches ...
Definition: DtIndirectCullPass.h:35
DtIndirectCullPass * myCullPass
Definition: DtGpuCullingAndLod.h:224
int myStreamedMaterialBytes
Definition: DtGpuCullingAndLod.h:262
DtGlBuffer * myGpuOutputInstancesBuffer
The re-distributed/culled/lod'ed instances (a subset of the input instances)
Definition: DtGpuCullingAndLod.h:222
DtDe & myDe
Definition: DtGpuCullingAndLod.h:294
Virtual base class.
Definition: DtVirtualBaseClass.h:22
DtInstanceContainer * myInstanceContainer
Definition: DtGpuCullingAndLod.h:194
int numOfInstances
Definition: DtGpuCullingAndLod.h:56
#define DT_DLL_VRVOSG
Definition: vrvOsg.h:23
DtGlBuffer * myGpuSpecIndexToCommandIndexBuffer
Definition: DtGpuCullingAndLod.h:249
DtGlBuffer * myGpuTexturesBuffer
Definition: DtGpuCullingAndLod.h:226
Indirect geometry can have multiple models and their corresponding ids registered in it...
Definition: DtIndirectGeometryRegistrar.h:101
DtGlBuffer * myGpuInstancesOffsetAndNumInstances
Definition: DtGpuCullingAndLod.h:233
int myStreamedSpecModelID
Definition: DtGpuCullingAndLod.h:264
DtGeometrySpecification class declaration.
int myNumGeometries
Definition: DtGpuCullingAndLod.h:270
int myStreamedMaterialModelID
Definition: DtGpuCullingAndLod.h:261
shader configuration storage class.
Definition: DtCullShaderConfig.h:19
Definition: DtOsgShaderFilesCache.h:22
DtCullShaderConfig myCullShaderConfig
Definition: DtGpuCullingAndLod.h:230
std::map< int, int > MapIntToInt
Definition: DtCommonTypes.h:25
MapIntToInt myModelIdToIndex
Definition: DtGpuCullingAndLod.h:228
Definition: DtGpuCullingAndLod.h:59
creator for DtGpuCullingAndLod
Definition: DtGpuCullingAndLod.h:275
unsigned int myLastNumEffectTextures
Definition: DtGpuCullingAndLod.h:254
DtGlBuffer * myGpuInputInstancesBuffer
The input instances for the GPU (generated/updated from the passed in instance container) ...
Definition: DtGpuCullingAndLod.h:198
VectorInts myGeomSpecIndexToCommandIndex
Definition: DtGpuCullingAndLod.h:248
Contains makVrv::DtVirtualBaseClass class.
std::string myShaderFolderPath
Definition: DtGpuCullingAndLod.h:235
std::vector< int > VectorInts
Definition: DtCommonTypes.h:20
VectorStateIdOffsetAndMaxCommands myStateIdToMaxNumCommands
Definition: DtGpuCullingAndLod.h:241
int myMutableFirstTextureStreamedModel
Keep track of the first model using bindless textures.
Definition: DtGpuCullingAndLod.h:256
int myStreamedSpecBytes
Definition: DtGpuCullingAndLod.h:265
DtOsgShaderFilesCache * myShaderFilesCache
Definition: DtGpuCullingAndLod.h:236
Class per frame that must be passed to the DtICullingAndLOD It indicates what would have changed (ins...
Definition: DtGpuCullingAndLodDefines.h:94
int myStreamedSpecModelGeomIndex
Definition: DtGpuCullingAndLod.h:266
int offset
Definition: DtGpuCullingAndLod.h:61
Declarations for classes used in DtICullingAndLOD.
int myMutableFirstTextureStreamedIndex
What index to start using bindless textures for a model.
Definition: DtGpuCullingAndLod.h:258
A generic OpenGL buffer.
Definition: DtGlBuffer.h:25
std::vector< StateIdOffsetAndMaxCommands > VectorStateIdOffsetAndMaxCommands
Definition: DtGpuCullingAndLod.h:65
bool myNeedTextureUpdate
Definition: DtGpuCullingAndLod.h:259
The class that is used to communicate the camera viewing parameters to the DtICullingAndLOD interface...
Definition: DtGpuCullingAndLodDefines.h:38
DtGlBuffer * myGpuStateIdToCommandCountBuffer
Definition: DtGpuCullingAndLod.h:245
DtGlBuffer * myGpuIndirectBuffer
The indirect command buffer that will be generated.
Definition: DtGpuCullingAndLod.h:219
int offset
Definition: DtGpuCullingAndLod.h:55
int myStreamedGeometryOffsetModelID
Definition: DtGpuCullingAndLod.h:269
std::vector< DtIndirectOffsetAndSize > myGeometryOffsetAndSizes
An internal indexing buffer that allows the cull shader to go from and intance to its GeometrySpecifi...
Definition: DtGpuCullingAndLod.h:212
The DtDe is the core component of any VR-Vantage application.
Definition: DtDe.h:69
std::vector< InstancesOffsetAndNumOfInstances > myInstancesOffsetAndNumInstances
Definition: DtGpuCullingAndLod.h:232
Helper class to manage instances This class allows you to add a DtInstance_64 Internally, however it stores this as a DtInstance (which the GPU can directly read)
Definition: DtInstanceContainer.h:27
DtIndirectGeometryRegistrar * myRegistrar
Definition: DtGpuCullingAndLod.h:193
DtGlBuffer * myGpuGeometrySpecificationsBuffer
The spec buffer containing GeometrySpecifications for all the models/lods of the passed in instances...
Definition: DtGpuCullingAndLod.h:205
This class is a component of the DtIndirectGeometry It inputs are: -> the instances registered with Dt...
Definition: DtGpuCullingAndLod.h:50
unsigned int myMaxNumInstances
Definition: DtGpuCullingAndLod.h:238
DtDe & myDe
Definition: DtGpuCullingAndLod.h:251
DtGlBuffer * myGpuMaterialsBuffer
The spec buffer containing Materials for all the models/lods of the passed in instances.
Definition: DtGpuCullingAndLod.h:216
Definition: DtGpuCullingAndLod.h:53
DtGlBuffer * myGpuInputPerGeomInstancesBuffer
contains switch states/ lod info
Definition: DtGpuCullingAndLod.h:201
int maxCommands
Definition: DtGpuCullingAndLod.h:62
std::vector< DtGeometrySpecification > myGeometrySpecifications
c++ buffer that holds the same info
Definition: DtGpuCullingAndLod.h:208