![]() |
VR-Forces 4.8 Class Documentation
|
State component that injects lighting shaders and uniforms into a state set. More...

Public Member Functions | |
| DtOsgLightingComponent (int maxLights, DtDe &de) | |
| CTOR. More... | |
| virtual | ~DtOsgLightingComponent () |
| DTOR. More... | |
| virtual void | update (const VectorLights &lights, const osg::State &state) |
| Update the lighting uniforms with new light data. More... | |
| virtual void | setMaxLights (int maxNumLights) |
| Sets the total maximum number of lights to activate (including dynamic lights). More... | |
| virtual const Vector2_uint32 & | tileSize (void) const |
| virtual const Vector2_uint32 & | gridMaxDims (void) const |
| virtual osg::Uniform * | getEnableLightingUniform () const |
| Gets the uniform that toggles lighting. More... | |
| virtual void | setAmbientFactor (float ambientFactor) |
| Sets the ambient factor uniform. More... | |
| virtual void | setUseGlobalAmbient (bool useGlobalAmbient) |
| Enables/Disables the usage of the material ambient and global ambient. More... | |
| virtual void | setDiffuseFactor (float diffuseFactor) |
| Sets the difuse factor uniform. More... | |
| virtual void | setUseGlobalDiffuse (bool useGlobalDiffuse) |
| Enables/Disables the usage of the material diffuse and global diffuse. More... | |
| virtual void | setUseHDR (bool useHDR) |
| Enables/Disables HDR Lighting. More... | |
| virtual void | setDirty (bool isDirty) |
| Sets dirty state for reinstallation. More... | |
| virtual void | setEmissionFactor (float emissionFactor) |
| Sets the emission factor uniform. More... | |
| virtual bool | dirty () const |
| Checks if component needs to be re-installed. More... | |
| virtual void | releaseGLObjects (void) |
| virtual bool | install (osg::StateSet *stateset) |
| Install this component on a state set. More... | |
| virtual bool | uninstall (osg::StateSet *stateset) |
| Uninstall this component from a state set. More... | |
Public Member Functions inherited from makVrv::DtOsgStateComponent | |
| DtOsgStateComponent (DtDe &de) | |
| CTOR. More... | |
Static Public Member Functions | |
| static int | textureStartOffset (void) |
Protected Member Functions | |
| virtual void | setLightPointScale (double scale) |
| virtual void | setDynamicLightScale (double scale) |
| virtual void | setEmissiveTextureScale (double scale) |
| virtual void | setSpecularScale (double scale) |
| virtual void | setShininessScale (double scale) |
| virtual osg::ref_ptr < osg::Uniform > | createUniform (const std::string &name, osg::Uniform::Type type, int count=1) |
| virtual void | packLights (const osg::Matrixd &normalMatrix, const VectorLights &lights, const osg::State &state) |
| virtual void | updateTextureLightDataGrid (void) |
| virtual void | updateTiledShadingData (const VectorLights &lights, const osg::State &state) |
| virtual void | updateTileLightIndexList () |
| Updates the per-light-grid index lists. More... | |
| virtual void | updateTileLightGridCountOffsets () |
| Updates the offsets and counts into the index grid. More... | |
| virtual int | lightGridSize () |
| Returns the number of lights in the light grid. More... | |
| virtual int | maxUboSize () |
| Returns the maximum UBO size that we'll use for a light UBO. More... | |
Protected Member Functions inherited from makVrv::DtOsgStateComponent | |
| virtual | ~DtOsgStateComponent () |
| DTOR. More... | |
| std::string | loadShaderSource (const std::string &strFileName) const |
| Loads shader source code from a path. More... | |
Static Protected Attributes | |
| static bool | bColorRampTextureWasTried |
Private Member Functions | |
| DtOsgLightingComponent () | |
| private default constructor. not allowed. More... | |
| DtOsgLightingComponent (const DtOsgLightingComponent &) | |
| prevent copy-construction More... | |
| DtOsgLightingComponent & | operator= (const DtOsgLightingComponent &) |
| prevent assignment More... | |
State component that injects lighting shaders and uniforms into a state set.
|
virtual |
DTOR.
|
private |
private default constructor. not allowed.
|
private |
prevent copy-construction
|
private |
prevent assignment
|
virtual |
Update the lighting uniforms with new light data.
|
virtual |
Sets the total maximum number of lights to activate (including dynamic lights).
|
virtual |
|
virtual |
|
virtual |
Gets the uniform that toggles lighting.
|
virtual |
Sets the ambient factor uniform.
|
virtual |
Enables/Disables the usage of the material ambient and global ambient.
|
virtual |
Sets the difuse factor uniform.
|
virtual |
Enables/Disables the usage of the material diffuse and global diffuse.
|
virtual |
Enables/Disables HDR Lighting.
|
inlinevirtual |
Sets dirty state for reinstallation.
|
virtual |
Sets the emission factor uniform.
|
inlinevirtual |
Checks if component needs to be re-installed.
|
virtual |
|
virtual |
Install this component on a state set.
Implements makVrv::DtOsgStateComponent.
|
virtual |
Uninstall this component from a state set.
Implements makVrv::DtOsgStateComponent.
|
static |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
Updates the per-light-grid index lists.
|
protectedvirtual |
Updates the offsets and counts into the index grid.
|
protectedvirtual |
Returns the number of lights in the light grid.
|
protectedvirtual |
Returns the maximum UBO size that we'll use for a light UBO.
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
Holds tile grid space offset and count pairs into the light data.
|
protected |
Holds a set of indexes, one per light tile.
This can get big, so cannot fit in a UBO.
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
staticprotected |
|
protected |
|
protected |
|
protected |