Om  1.0.0
A universal framework for multimedia simulation
Public Member Functions | List of all members
om::graphics::devices::opengl::OpenGLShader Class Reference

A class that represents an OpenGL hardware-executed shader program. More...

#include <omGraphicsOpenGLShader.h>

Inheritance diagram for om::graphics::devices::opengl::OpenGLShader:
om::graphics::materials::DeviceShader om::graphics::devices::DeviceResource

Public Member Functions

virtual ~OpenGLShader ()
 Destroy this shader and release all resources associated with it. More...
 
virtual ShaderSourceString getSource () const
 Get the source code used by this shader. More...
 
virtual Bool setSource (const ShaderSourceString &newSource, const ShaderLanguage &language=ShaderLanguage::DEFAULT)
 Set the source code used by the shader. More...
 
virtual Bool compile (StringOutputStream *compilationLog=((void *) 0))
 Compile the shader's source code and return whether or not the operation was successful. More...
 
virtual Bool isCompiled () const
 Return whether or not this shader has been compiled. More...
 
virtual Bool isValid () const
 Return whether or not the shader was successfully compiled. More...
 
OpenGLID getID () const
 Get a unique integral identifier of this shader for OpenGL. More...
 
- Public Member Functions inherited from om::graphics::materials::DeviceShader
const ShaderTypegetType () const
 Return an object indicating the type of shader this is. More...
 
- Public Member Functions inherited from om::graphics::devices::DeviceResource
virtual ~DeviceResource ()
 Destroy a device object, releasing all internal state. More...
 
GraphicsContextgetContext () const
 Return a pointer to the graphics context associated with this DeviceResource. More...
 

Additional Inherited Members

- Protected Member Functions inherited from om::graphics::materials::DeviceShader
 DeviceShader (devices::GraphicsContext *newContext, ShaderType newShaderType)
 Create a device shader for the specified context with the given shader type. More...
 
- Protected Member Functions inherited from om::graphics::devices::DeviceResource
 DeviceResource (GraphicsContext *newContext)
 Create a new device object that is associated with the specified graphics context. More...
 
- Protected Attributes inherited from om::graphics::materials::DeviceShader
ShaderType shaderType
 An enum value that is set by subclasses that specifies the kind of shader this is. More...
 

Detailed Description

A class that represents an OpenGL hardware-executed shader program.

Constructor & Destructor Documentation

virtual om::graphics::devices::opengl::OpenGLShader::~OpenGLShader ( )
virtual

Destroy this shader and release all resources associated with it.

Member Function Documentation

virtual ShaderSourceString om::graphics::devices::opengl::OpenGLShader::getSource ( ) const
virtual

Get the source code used by this shader.

Implements om::graphics::materials::DeviceShader.

virtual Bool om::graphics::devices::opengl::OpenGLShader::setSource ( const ShaderSourceString newSource,
const ShaderLanguage language = ShaderLanguage::DEFAULT 
)
virtual

Set the source code used by the shader.

Implements om::graphics::materials::DeviceShader.

virtual Bool om::graphics::devices::opengl::OpenGLShader::compile ( StringOutputStream compilationLog = ((void *) 0))
virtual

Compile the shader's source code and return whether or not the operation was successful.

Implements om::graphics::materials::DeviceShader.

virtual Bool om::graphics::devices::opengl::OpenGLShader::isCompiled ( ) const
virtual

Return whether or not this shader has been compiled.

Implements om::graphics::materials::DeviceShader.

virtual Bool om::graphics::devices::opengl::OpenGLShader::isValid ( ) const
virtual

Return whether or not the shader was successfully compiled.

Implements om::graphics::devices::DeviceResource.

OpenGLID om::graphics::devices::opengl::OpenGLShader::getID ( ) const
inline

Get a unique integral identifier of this shader for OpenGL.


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