osgGL2::ShaderObject is an application-level abstraction of the OpenGL Shading Language glShaderObject.
Inheritance:
Public Classes
-
enum Type
Public Methods
-
ShaderObject()
-
ShaderObject(Type type)
-
ShaderObject(Type type, const char* sourceText)
-
ShaderObject(const ShaderObject& rhs, const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY)
- Copy constructor using CopyOp to manage deep vs shallow copy
-
META_Object(osgGL2, ShaderObject)
-
int compare(const ShaderObject& sa) const
-
void setShaderSource( const char* sourceText )
- Load the ShaderObject's source code text from a string.
-
inline const std::string& getShaderSource() const
- Retreive the source code text
-
bool loadShaderSourceFromFile( const char* fileName )
- Load the ShaderObject's source code text from a file.
-
inline Type getType() const
- Get the ShaderObject type as an enum.
-
const char* getTypename() const
- Get the ShaderObject type as a descriptive string.
-
void dirtyShaderObject()
- Mark us as "dirty" and in need of recompilation
-
void build(unsigned int contextID) const
- Perform a recompilation of all our PCSOs
-
void attach(unsigned int contextID, GLhandleARB progObj) const
- For a given GL context, attach a glShaderObject to a glProgramObject
Protected Classes
-
class PerContextShaderObj: public osg::Referenced
- PCSO is an OSG-internal encapsulation of glShaderObjects per-GL context.
Protected Fields
-
Type _type
-
std::string _shaderSource
-
std::vector< ProgramObjectPtr > _programObjectList
-
mutable osg::buffered_value< osg::ref_ptr<PerContextShaderObj> > _pcsoList
Protected Methods
-
virtual ~ShaderObject()
-
PerContextShaderObj* getPCSO(unsigned int contextID) const
-
void addProgObjRef( ProgramObject* progObj )
Documentation
osgGL2::ShaderObject is an application-level abstraction of the OpenGL Shading Language glShaderObject.
It is a container to load the shader source code text and manage its
compilation.
A ShaderObject may be attached to more than one osgGL2::ProgramObject.
ShaderObject will automatically manage per-context instancing of the
internal objects, if that is necessary for a particular display
configuration.
- enum Type
- VERTEX
- FRAGMENT
- UNKNOWN
- ShaderObject()
- ShaderObject(Type type)
- ShaderObject(Type type, const char* sourceText)
- ShaderObject(const ShaderObject& rhs, const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY)
- Copy constructor using CopyOp to manage deep vs shallow copy
- META_Object(osgGL2, ShaderObject)
- int compare(const ShaderObject& sa) const
- void setShaderSource( const char* sourceText )
- Load the ShaderObject's source code text from a string.
- inline const std::string& getShaderSource() const
- Retreive the source code text
- bool loadShaderSourceFromFile( const char* fileName )
- Load the ShaderObject's source code text from a file.
- inline Type getType() const
- Get the ShaderObject type as an enum.
- const char* getTypename() const
- Get the ShaderObject type as a descriptive string.
- void dirtyShaderObject()
- Mark us as "dirty" and in need of recompilation
- void build(unsigned int contextID) const
- Perform a recompilation of all our PCSOs
- void attach(unsigned int contextID, GLhandleARB progObj) const
- For a given GL context, attach a glShaderObject to a glProgramObject
- virtual ~ShaderObject()
- PerContextShaderObj* getPCSO(unsigned int contextID) const
- void addProgObjRef( ProgramObject* progObj )
- Type _type
- std::string _shaderSource
- std::vector< ProgramObjectPtr > _programObjectList
- mutable osg::buffered_value< osg::ref_ptr<PerContextShaderObj> > _pcsoList
- This class has no child classes.
- Friends:
- void ProgramObject::addShader( ShaderObject* shadObj )
Alphabetic index HTML hierarchy of classes or Java
This page was generated with the help of DOC++.