VR-Forces 4.10 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Classes | Public Types | Public Member Functions | Protected Member Functions | Protected Attributes
makVrv::DtShaderEffect Class Referenceabstract

DtShaderEffect injects custom shaders into the scenes, There are derrived classes of this for snow and rain on the ground effects. More...

Inheritance diagram for makVrv::DtShaderEffect:
Inheritance graph
[legend]

Classes

struct  DtShaderEffectTextureData
 Structure for holding per texture data for bindless textures. More...
 

Public Types

typedef std::vector
< DtShaderEffectTextureData
TextureDataPtrVector
 

Public Member Functions

virtual ~DtShaderEffect ()
 DTOR. More...
 
 DtShaderEffect ()=delete
 unimplemented private default constructor More...
 
 DtShaderEffect (const DtShaderEffect &)=delete
 Copy Constructor not implemented – Copy not allowed. More...
 
DtShaderEffectoperator= (const DtShaderEffect &)=delete
 Assignment Operator not implemented – Copy not allowed. More...
 
virtual void initializeEffect (const std::vector< osg::StateSet * > &statesets, DtIndirectTextureProcessor *textureProcessor, DtOsgRenderer &osgRenderer)
 initializes or reinitializes the effects. More...
 
virtual void registerWeatherEffectsObject (DtOsgWeatherEffectsObject *weatherEffectsObject)=0
 called by the DtOsgWeatherEffectsObject constructor to register itself when it is created. More...
 
virtual void updateTextureUniforms (unsigned int contextId)
 update the texture uniforms for this shader effect More...
 
virtual void setCameraLocation (const DtVector &location)
 sets a location for localized effects. More...
 
virtual void setEffectDirty (bool dirty)
 set this effect dirty so that it will be reinitialized before the next time it is run More...
 
virtual bool effectDirty ()
 get if this effect is dirty More...
 
virtual void updateImGui ()=0
 update the imgui widgets and readback any changes from them More...
 
virtual void updateUniforms ()=0
 update the uniforms that may need to be changed based on the imgui or regular gui inputs. More...
 
virtual void releaseGLObjects (osg::State *state)
 release the gl objects for this class More...
 
- Public Member Functions inherited from makVrv::DtVirtualBaseClass
 DtVirtualBaseClass ()
 Do nothing constructor. More...
 
virtual ~DtVirtualBaseClass ()
 Virtual do nothing destructor. More...
 

Protected Member Functions

 DtShaderEffect (DtDe &de)
 constructor More...
 
virtual int loadShaderEffectTexture (const std::string &filename, const std::string &uniformName)
 load a texture from a file and set it up as a bindless texture with the address in the specified uniform name More...
 
virtual int addShaderEffectTexture (osg::Texture *shaderEffectTexture, const std::string &uniformName)
 add a texture and set it up as a bindless texture with the address in the specified uniform name More...
 

Protected Attributes

DtDemyDe
 
TextureDataPtrVector myShaderEffectTextures
 
bool myEffectDirty
 

Detailed Description

DtShaderEffect injects custom shaders into the scenes, There are derrived classes of this for snow and rain on the ground effects.

Member Typedef Documentation

Constructor & Destructor Documentation

virtual makVrv::DtShaderEffect::~DtShaderEffect ( )
virtual

DTOR.

makVrv::DtShaderEffect::DtShaderEffect ( )
delete

unimplemented private default constructor

makVrv::DtShaderEffect::DtShaderEffect ( const DtShaderEffect )
delete

Copy Constructor not implemented – Copy not allowed.

makVrv::DtShaderEffect::DtShaderEffect ( DtDe de)
protected

constructor

Member Function Documentation

DtShaderEffect& makVrv::DtShaderEffect::operator= ( const DtShaderEffect )
delete

Assignment Operator not implemented – Copy not allowed.

virtual void makVrv::DtShaderEffect::initializeEffect ( const std::vector< osg::StateSet * > &  statesets,
DtIndirectTextureProcessor textureProcessor,
DtOsgRenderer osgRenderer 
)
virtual

initializes or reinitializes the effects.

Called by DtOsgRenderer at startup and whenever reload shaders is triggered reloads the shader changes if triggered from reload shaders but the texture is not reloaded off disk due to osgFileCache

Reimplemented in makVrv::DtShaderEffectSnow, and makVrv::DtShaderEffectRain.

virtual void makVrv::DtShaderEffect::registerWeatherEffectsObject ( DtOsgWeatherEffectsObject weatherEffectsObject)
pure virtual

called by the DtOsgWeatherEffectsObject constructor to register itself when it is created.

Implemented in makVrv::DtShaderEffectSnow, and makVrv::DtShaderEffectRain.

virtual void makVrv::DtShaderEffect::updateTextureUniforms ( unsigned int  contextId)
virtual

update the texture uniforms for this shader effect

virtual void makVrv::DtShaderEffect::setCameraLocation ( const DtVector location)
virtual

sets a location for localized effects.

Reimplemented in makVrv::DtShaderEffectRain.

virtual void makVrv::DtShaderEffect::setEffectDirty ( bool  dirty)
virtual

set this effect dirty so that it will be reinitialized before the next time it is run

virtual bool makVrv::DtShaderEffect::effectDirty ( )
virtual

get if this effect is dirty

virtual void makVrv::DtShaderEffect::updateImGui ( )
pure virtual

update the imgui widgets and readback any changes from them

Implemented in makVrv::DtShaderEffectSnow, and makVrv::DtShaderEffectRain.

virtual void makVrv::DtShaderEffect::updateUniforms ( )
pure virtual

update the uniforms that may need to be changed based on the imgui or regular gui inputs.

Implemented in makVrv::DtShaderEffectSnow, and makVrv::DtShaderEffectRain.

virtual void makVrv::DtShaderEffect::releaseGLObjects ( osg::State *  state)
virtual

release the gl objects for this class

Reimplemented in makVrv::DtShaderEffectSnow, and makVrv::DtShaderEffectRain.

virtual int makVrv::DtShaderEffect::loadShaderEffectTexture ( const std::string &  filename,
const std::string &  uniformName 
)
protectedvirtual

load a texture from a file and set it up as a bindless texture with the address in the specified uniform name

virtual int makVrv::DtShaderEffect::addShaderEffectTexture ( osg::Texture *  shaderEffectTexture,
const std::string &  uniformName 
)
protectedvirtual

add a texture and set it up as a bindless texture with the address in the specified uniform name

Member Data Documentation

DtDe& makVrv::DtShaderEffect::myDe
protected
TextureDataPtrVector makVrv::DtShaderEffect::myShaderEffectTextures
protected
bool makVrv::DtShaderEffect::myEffectDirty
protected

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

Document ID: Generated on Tue Sep 21 17:42:52 EDT 2021 from SVN revision 234861
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)