![]() |
VR-Forces 5.0.3 Developer's Guide
|
Manage interface block bindings. This knowledge was previously distributed several places in the code. This encapsulates the knowledge of which shader interface block names map to which bindings. It can be used for UBOs and SSBOs, and maybe other bindings later on if it grows to do so. It is only used at setup time, so performance is not critical.

Public Member Functions | |
| virtual GLuint | binding (const std::string &name) const |
| virtual GLuint | binding (const std::string &name, int index) const |
| virtual void | bindBlocks (GLuint programId) const |
| virtual std::string | name (const std::string &name) const |
| virtual std::string | name (const std::string &name, int index) const |
Public Member Functions inherited from makVrv::DtVirtualBaseClass | |
| DtVirtualBaseClass () | |
| virtual | ~DtVirtualBaseClass () |
Static Public Member Functions | |
| static DtBindingManager & | instance (DtDe &) |
Static Public Attributes | |
| static const int | theLightBlockBase = 6 |
| static const int | theLightBlockCount = 5 |
| static const char * | osgMaterialUniformBlock |
| static const char * | osgAlphaThresholdBlock |
| static const char * | osgTransformStackBlock |
| static const char * | vrvPerChannelUniformBlock |
| static const char * | vrvLightDataBlock |
| static const char * | vrvTileLightIndexList |
Protected Types | |
| typedef std::map< std::string, std::pair< DtBufferType, GLuint > > | BindingMap |
Protected Member Functions | |
| DtBindingManager () | |
| virtual | ~DtBindingManager () |
| virtual std::string | indexedName (const std::string &name, int index) const |
| virtual void | initializeBlockBindings () |
| virtual void | setBinding (const std::string &name, DtBufferType bufferType, GLuint binding) |
| virtual void | setBinding (const std::string &name, DtBufferType bufferType, int index, GLuint binding) |
Protected Attributes | |
| BindingMap | bindingMap |
Private Member Functions | |
| DtBindingManager (const DtBindingManager &rhs) | |
| DtBindingManager & | operator= (const DtBindingManager &rhs) |
|
protected |
Map of binding names to bindings.
|
protected |
CTOR. cannot construct directly.
|
protectedvirtual |
cannot destruct directly
|
private |
not allowed
|
static |
Get an instance of the shared settings manager from the DtDe;.
|
private |
not allowed
|
virtual |
query binding for given name
|
virtual |
query binding for given name and index
|
virtual |
Bind interface blocks for the given program ID. This need only be done at program creation time, unless reset via some other mechanism.
|
virtual |
query interface block name for given string
|
virtual |
query interface block name given binding base name and index
|
protectedvirtual |
generate indexed name by appending index number
|
protectedvirtual |
initialize the block bindings
|
protectedvirtual |
set binding for given name
|
protectedvirtual |
set binding for given name and index
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
protected |