DtOsgShaderManager injects custom shaders into the scenes, and keeps their uniform parameters set to match fixed function pipeline capabilities as much as possible.
More...
Detailed Description
DtOsgShaderManager injects custom shaders into the scenes, and keeps their uniform parameters set to match fixed function pipeline capabilities as much as possible.
Constructor & Destructor Documentation
| virtual makVrv::DtOsgShaderManager::~DtOsgShaderManager |
( |
| ) |
|
|
virtual |
| makVrv::DtOsgShaderManager::DtOsgShaderManager |
( |
DtDe & |
de | ) |
|
|
protected |
| makVrv::DtOsgShaderManager::DtOsgShaderManager |
( |
| ) |
|
|
private |
Member Function Documentation
Get/create instance of sky object manager.
| static std::string makVrv::DtOsgShaderManager::theClassName |
( |
| ) |
|
|
static |
Get the name this class is registered by.
| void makVrv::DtOsgShaderManager::setPerPixelLightingEnabled |
( |
bool |
enabled | ) |
|
Toggles global use of shader-based lighting effects.
| bool makVrv::DtOsgShaderManager::getPerPixelLightingEnabled |
( |
| ) |
const |
Retrieves whether per-pixel shader-based lighting is active.
| void makVrv::DtOsgShaderManager::generateShaders |
( |
osg::Node * |
node, |
|
|
const std::string & |
name = "", |
|
|
bool |
shareState = true, |
|
|
bool |
force = false |
|
) |
| |
Generates virtual shader programs for a graph.
node: Graph for which to generate shader components name: Optional name to give to virtual programs (useful for debugging) shareState: Run a pass on the node to share equivalent state attributes. This is equivalent to calling optimizeStateSharing(node) after calling this. force: Force shader generation on the node graph, disregarding the ignore userdata flag (see osgEarth::ShaderGenerator::setIgnoreHint)
| void makVrv::DtOsgShaderManager::ts_generateShaders |
( |
osg::Node * |
node, |
|
|
DtOsgFileCache & |
fileCache, |
|
|
const std::string & |
name = "", |
|
|
bool |
shareState = true, |
|
|
bool |
force = false |
|
) |
| |
threadsafe implementation of generateShaders
| void makVrv::DtOsgShaderManager::removeShaders |
( |
osg::Node * |
node | ) |
|
Remove virtual shader programs for a graph.
node: Graph for which to remove shader components
| void makVrv::DtOsgShaderManager::ts_removeShaders |
( |
osg::Node * |
node | ) |
|
threadsafe implementation of removeShaders
| void makVrv::DtOsgShaderManager::optimizeStateSharing |
( |
osg::Node * |
node | ) |
|
Runs a pass over the provided graph and consolidates equivalent state attributes.
This can result in better draw performance by reducing OpenGL state changes
| const std::string& makVrv::DtOsgShaderManager::getShaderFolderPath |
( |
| ) |
const |
Gets the location of the shader sources.
| void makVrv::DtOsgShaderManager::cullReset |
( |
| ) |
|
Clear the internal list of light sources and implement state changes when the cull visitor is reset each frame.
| void makVrv::DtOsgShaderManager::disableShaders |
( |
osg::StateSet * |
stateSet | ) |
|
Disable per-pixel lighting on this state set.
| void makVrv::DtOsgShaderManager::installEnvironmentMap |
( |
osg::Camera * |
camera | ) |
|
Installs an environment map texture/uniform on the specified camera.
This needs to be per camera so that the correct environment map is used based on the camera.
Member Data Documentation
| bool makVrv::DtOsgShaderManager::myPerPixelLightingStateChanged |
|
protected |
| bool makVrv::DtOsgShaderManager::myPerPixelLightingEnabled |
|
protected |
| bool makVrv::DtOsgShaderManager::myPendingPerPixelLightingState |
|
protected |
| DtDe& makVrv::DtOsgShaderManager::myDe |
|
protected |
| osg::ref_ptr<DtOpenGLCubeMap> makVrv::DtOsgShaderManager::myEnvironmentMapTexture |
|
protected |
The documentation for this class was generated from the following file: