OGRE  1.10.5
Object-Oriented Graphics Rendering Engine
Ogre::GLSLESProgram Class Reference

Specialisation of HighLevelGpuProgram to provide support for OpenGL Shader Language (GLSL ES) for OpenGL ES 2.0. More...

#include <OgreGLSLESProgram.h>

+ Inheritance diagram for Ogre::GLSLESProgram:

Classes

class  CmdOptimisation
 Command object for running the GLSL optimiser. More...
 

Public Member Functions

 GLSLESProgram (ResourceManager *creator, const String &name, ResourceHandle handle, const String &group, bool isManual, ManualResourceLoader *loader)
 
 ~GLSLESProgram ()
 
GpuProgram_getBindingDelegate (void)
 Since GLSL has no assembly, use this shader for binding. More...
 
void attachToProgramObject (const GLuint programObject)
 
void bindProgram (void)
 Execute the binding functions for this program. More...
 
void bindProgramParameters (GpuProgramParametersSharedPtr params, uint16 mask)
 Execute the param binding functions for this program. More...
 
void bindProgramPassIterationParameters (GpuProgramParametersSharedPtr params)
 Execute the pass iteration param binding functions for this program. More...
 
void bindProgramSharedParameters (GpuProgramParametersSharedPtr params, uint16 mask)
 Execute the shared param binding functions for this program. More...
 
size_t calculateSize (void) const
 
bool compile (const bool checkErrors=false)
 compile source into shader object More...
 
GLuint createGLProgramHandle ()
 
GpuProgramParametersSharedPtr createParameters (void)
 Overridden from GpuProgram. More...
 
void detachFromProgramObject (const GLuint programObject)
 
GLuint getGLProgramHandle () const
 
GLuint getGLShaderHandle () const
 GL Shader Handle. More...
 
bool getIsOptimised (void)
 Gets if the GLSL source has been optimised successfully. More...
 
const StringgetLanguage (void) const
 Overridden from GpuProgram. More...
 
String getOptimisedSource (void)
 Gets he optimised GLSL source. More...
 
bool getOptimiserEnabled (void) const
 Gets if the GLSL optimiser is enabled. More...
 
void setIsOptimised (bool flag)
 Sets if the GLSL source has been optimised successfully. More...
 
void setOptimisedSource (const String &src)
 Sets the optimised GLSL source. More...
 
void setOptimiserEnabled (bool enabled)
 Sets if the GLSL optimiser is enabled. More...
 
void unbindProgram (void)
 Execute the unbinding functions for this program. More...
 

Detailed Description

Specialisation of HighLevelGpuProgram to provide support for OpenGL Shader Language (GLSL ES) for OpenGL ES 2.0.

Remarks
GLSL ES has no target assembler or entry point specification like DirectX 9 HLSL. Vertex and Fragment shaders only have one entry point called "main". When a shader is compiled, microcode is generated but can not be accessed by the application. GLSL ES also does not provide assembler low level output after compiling. The GL ES Render system assumes that the Gpu program is a GL Gpu program so GLSLESProgram will create a GLSLESGpuProgram that is subclassed from GLES2GpuProgram for the low level implementation. The GLES2Program class will create a shader object and compile the source but will not create a program object. It's up to GLES2GpuProgram class to request a program object to link the shader object to.

Constructor & Destructor Documentation

◆ GLSLESProgram()

Ogre::GLSLESProgram::GLSLESProgram ( ResourceManager creator,
const String name,
ResourceHandle  handle,
const String group,
bool  isManual,
ManualResourceLoader loader 
)

◆ ~GLSLESProgram()

Ogre::GLSLESProgram::~GLSLESProgram ( )

Member Function Documentation

◆ getGLShaderHandle()

GLuint Ogre::GLSLESProgram::getGLShaderHandle ( ) const
inline

GL Shader Handle.

◆ attachToProgramObject()

void Ogre::GLSLESProgram::attachToProgramObject ( const GLuint  programObject)

◆ detachFromProgramObject()

void Ogre::GLSLESProgram::detachFromProgramObject ( const GLuint  programObject)

◆ getGLProgramHandle()

GLuint Ogre::GLSLESProgram::getGLProgramHandle ( ) const
inline

◆ createGLProgramHandle()

GLuint Ogre::GLSLESProgram::createGLProgramHandle ( )

◆ setOptimiserEnabled()

void Ogre::GLSLESProgram::setOptimiserEnabled ( bool  enabled)

Sets if the GLSL optimiser is enabled.

◆ getOptimiserEnabled()

bool Ogre::GLSLESProgram::getOptimiserEnabled ( void  ) const
inline

Gets if the GLSL optimiser is enabled.

◆ setIsOptimised()

void Ogre::GLSLESProgram::setIsOptimised ( bool  flag)
inline

Sets if the GLSL source has been optimised successfully.

◆ getIsOptimised()

bool Ogre::GLSLESProgram::getIsOptimised ( void  )
inline

Gets if the GLSL source has been optimised successfully.

◆ setOptimisedSource()

void Ogre::GLSLESProgram::setOptimisedSource ( const String src)
inline

Sets the optimised GLSL source.

◆ getOptimisedSource()

String Ogre::GLSLESProgram::getOptimisedSource ( void  )
inline

Gets he optimised GLSL source.

◆ getLanguage()

const String& Ogre::GLSLESProgram::getLanguage ( void  ) const

Overridden from GpuProgram.

◆ createParameters()

GpuProgramParametersSharedPtr Ogre::GLSLESProgram::createParameters ( void  )

Overridden from GpuProgram.

◆ compile()

bool Ogre::GLSLESProgram::compile ( const bool  checkErrors = false)

compile source into shader object

◆ _getBindingDelegate()

GpuProgram* Ogre::GLSLESProgram::_getBindingDelegate ( void  )
inline

Since GLSL has no assembly, use this shader for binding.

◆ bindProgram()

void Ogre::GLSLESProgram::bindProgram ( void  )

Execute the binding functions for this program.

◆ unbindProgram()

void Ogre::GLSLESProgram::unbindProgram ( void  )

Execute the unbinding functions for this program.

◆ bindProgramParameters()

void Ogre::GLSLESProgram::bindProgramParameters ( GpuProgramParametersSharedPtr  params,
uint16  mask 
)

Execute the param binding functions for this program.

◆ bindProgramSharedParameters()

void Ogre::GLSLESProgram::bindProgramSharedParameters ( GpuProgramParametersSharedPtr  params,
uint16  mask 
)

Execute the shared param binding functions for this program.

◆ bindProgramPassIterationParameters()

void Ogre::GLSLESProgram::bindProgramPassIterationParameters ( GpuProgramParametersSharedPtr  params)

Execute the pass iteration param binding functions for this program.

◆ calculateSize()

size_t Ogre::GLSLESProgram::calculateSize ( void  ) const

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