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

Callback to set a uniform value on a per-view basis. More...

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

Public Member Functions

 DtPerViewUniformCallback ()
 CTOR. More...
 
 DtPerViewUniformCallback (const DtPerViewUniformCallback &, const osg::CopyOp &)
 Copy CTOR. More...
 
 META_Object (makVrv, DtPerViewUniformCallback)
 
virtual ~DtPerViewUniformCallback ()
 DTOR. More...
 
virtual void drawImplementation (osg::RenderInfo &renderInfo, const osg::Drawable *drawable) const
 Draw with the appropriate uniform value. More...
 
void setValue (const osg::View *v, int val)
 Set the uniform value for the specified view. More...
 
float getValue (const osg::View *v) const
 Get the uniform value for the specified view. More...
 

Protected Types

typedef std::pair< const
osg::Program::PerContextProgram
*, GLuint
ProgramKey
 
typedef boost::unordered_map
< ProgramKey, GLuint
ProgramToUniformLoc
 
typedef boost::unordered_map
< const osg::View *, float > 
ViewToValue
 

Protected Member Functions

GLuint findLocation (const osg::Program::PerContextProgram *program)
 Find the uniform's location in the program object. More...
 

Protected Attributes

ProgramToUniformLoc myProgramToUniformLoc
 
ViewToValue myViewToValue
 

Detailed Description

Callback to set a uniform value on a per-view basis.

Member Typedef Documentation

typedef std::pair<const osg::Program::PerContextProgram*, GLuint> makVrv::DtPerViewUniformCallback::ProgramKey
protected
typedef boost::unordered_map<const osg::View*, float> makVrv::DtPerViewUniformCallback::ViewToValue
protected

Constructor & Destructor Documentation

makVrv::DtPerViewUniformCallback::DtPerViewUniformCallback ( )

CTOR.

makVrv::DtPerViewUniformCallback::DtPerViewUniformCallback ( const DtPerViewUniformCallback ,
const osg::CopyOp &   
)

Copy CTOR.

virtual makVrv::DtPerViewUniformCallback::~DtPerViewUniformCallback ( )
virtual

DTOR.

Member Function Documentation

makVrv::DtPerViewUniformCallback::META_Object ( makVrv  ,
DtPerViewUniformCallback   
)
virtual void makVrv::DtPerViewUniformCallback::drawImplementation ( osg::RenderInfo &  renderInfo,
const osg::Drawable *  drawable 
) const
virtual

Draw with the appropriate uniform value.

void makVrv::DtPerViewUniformCallback::setValue ( const osg::View *  v,
int  val 
)

Set the uniform value for the specified view.

float makVrv::DtPerViewUniformCallback::getValue ( const osg::View *  v) const

Get the uniform value for the specified view.

GLuint makVrv::DtPerViewUniformCallback::findLocation ( const osg::Program::PerContextProgram *  program)
protected

Find the uniform's location in the program object.

Member Data Documentation

ProgramToUniformLoc makVrv::DtPerViewUniformCallback::myProgramToUniformLoc
protected
ViewToValue makVrv::DtPerViewUniformCallback::myViewToValue
protected

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

Document ID: Generated on Thu Aug 27 10:56:05 EDT 2020 from SVN revision 217100
Copyright © 2005-2020 MAK Technologies. All Rights Reserved (www.mak.com)