OGRE: Ogre::RTShader::ProgramManager Class Reference

| OGRE 2.2.4 Object-Oriented Graphics Rendering Engine

Public Member Functions | Static Public Member Functions | Friends | List of all members
Ogre::RTShader::ProgramManager Class Reference
Core » RTShader

A singleton manager class that manages shader based programs. More...

`#include <OgreShaderProgramManager.h>`

Inheritance diagram for Ogre::RTShader::ProgramManager:
[legend]

## Public Member Functions
| ProgramManager ()
| Class default constructor. More...
| ~ProgramManager ()
| Class destructor. More...
void | acquirePrograms (Pass *pass, TargetRenderState *renderState)
| Acquire CPU/GPU programs set associated with the given render state and bind them to the pass. More...
void | flushGpuProgramsCache ()
| Flush the local GPU programs cache. More...
void | operator delete (void *ptr)
void | operator delete (void *ptr, const char *, int, const char *)
void | operator delete (void *ptr, void *)
void | operator delete[] (void *ptr)
void | operator delete[] (void *ptr, const char *, int, const char *)
void * | operator new (size_t sz)
void * | operator new (size_t sz, const char *file, int line, const char *func)
| operator new, with debug line info More...
void * | operator new (size_t sz, void *ptr)
| placement operator new More...
void * | operator new[] (size_t sz)
void * | operator new[] (size_t sz, const char *file, int line, const char *func)
| array operator new, with debug line info More...
void | releasePrograms (Pass *pass, TargetRenderState *renderState)
| Release CPU/GPU programs set associated with the given render state and pass. More...

## Static Public Member Functions
static ProgramManager & | getSingleton ()
| Override standard Singleton retrieval. More...
static ProgramManager * | getSingletonPtr ()
| Override standard Singleton retrieval. More...

## Friends
class | ProgramSet
class | ShaderGenerator
class | TargetRenderState

## Detailed Description

A singleton manager class that manages shader based programs.

## Constructor & Destructor Documentation

## ◆ ProgramManager()

Ogre::RTShader::ProgramManager::ProgramManager | ( |  | ) |

Class default constructor.

## ◆ ~ProgramManager()

Ogre::RTShader::ProgramManager::~ProgramManager | ( |  | ) |

Class destructor.

## Member Function Documentation

## ◆ acquirePrograms()

void Ogre::RTShader::ProgramManager::acquirePrograms | ( | Pass * | pass,
|  | TargetRenderState * | renderState
| ) |  |

Acquire CPU/GPU programs set associated with the given render state and bind them to the pass.

Parameters

  pass | The pass to bind the programs to.
  renderState | The render state that describes the program that need to be generated.

## ◆ flushGpuProgramsCache()

void Ogre::RTShader::ProgramManager::flushGpuProgramsCache | ( |  | ) |

Flush the local GPU programs cache.

## ◆ getSingleton()

static ProgramManager& Ogre::RTShader::ProgramManager::getSingleton | ( |  | ) |
| static

Override standard Singleton retrieval.

Remarks
  Why do we do this? Well, it's because the Singleton implementation is in a .h file, which means it gets compiled into anybody who includes it. This is needed for the Singleton template to work, but we actually only want it compiled into the implementation of the class based on the Singleton, not all of them. If we don't change this, we get link errors when trying to use the Singleton-based class from an outside dll.

  This method just delegates to the template version anyway, but the implementation stays in this single compilation unit, preventing link errors.

## ◆ getSingletonPtr()

static ProgramManager* Ogre::RTShader::ProgramManager::getSingletonPtr | ( |  | ) |
| static

Override standard Singleton retrieval.

Remarks
  Why do we do this? Well, it's because the Singleton implementation is in a .h file, which means it gets compiled into anybody who includes it. This is needed for the Singleton template to work, but we actually only want it compiled into the implementation of the class based on the Singleton, not all of them. If we don't change this, we get link errors when trying to use the Singleton-based class from an outside dll.

  This method just delegates to the template version anyway, but the implementation stays in this single compilation unit, preventing link errors.

## ◆ operator delete() [1/3]

template<class Alloc >

void Ogre::AllocatedObject< Alloc >::operator delete | ( | void * | ptr | ) |
| inlineinherited

## ◆ operator delete() [2/3]

template<class Alloc >

void Ogre::AllocatedObject< Alloc >::operator delete | ( | void * | ptr,
|  | const char * | ,
|  | int | ,
|  | const char * |
| ) |  |
| inlineinherited

## ◆ operator delete() [3/3]

template<class Alloc >

void Ogre::AllocatedObject< Alloc >::operator delete | ( | void * | ptr,
|  | void * |
| ) |  |
| inlineinherited

## ◆ operator delete[]() [1/2]

template<class Alloc >

void Ogre::AllocatedObject< Alloc >::operator delete[] | ( | void * | ptr | ) |
| inlineinherited

## ◆ operator delete[]() [2/2]

template<class Alloc >

void Ogre::AllocatedObject< Alloc >::operator delete[] | ( | void * | ptr,
|  | const char * | ,
|  | int | ,
|  | const char * |
| ) |  |
| inlineinherited

## ◆ operator new() [1/3]

template<class Alloc >

void* Ogre::AllocatedObject< Alloc >::operator new | ( | size_t | sz | ) |
| inlineinherited

## ◆ operator new() [2/3]

template<class Alloc >

void* Ogre::AllocatedObject< Alloc >::operator new | ( | size_t | sz,
|  | const char * | file,
|  | int | line,
|  | const char * | func
| ) |  |
| inlineinherited

operator new, with debug line info

## ◆ operator new() [3/3]

template<class Alloc >

void* Ogre::AllocatedObject< Alloc >::operator new | ( | size_t | sz,
|  | void * | ptr
| ) |  |
| inlineinherited

placement operator new

## ◆ operator new[]() [1/2]

template<class Alloc >

void* Ogre::AllocatedObject< Alloc >::operator new[] | ( | size_t | sz | ) |
| inlineinherited

## ◆ operator new[]() [2/2]

template<class Alloc >

void* Ogre::AllocatedObject< Alloc >::operator new[] | ( | size_t | sz,
|  | const char * | file,
|  | int | line,
|  | const char * | func
| ) |  |
| inlineinherited

array operator new, with debug line info

## ◆ releasePrograms()

void Ogre::RTShader::ProgramManager::releasePrograms | ( | Pass * | pass,
|  | TargetRenderState * | renderState
| ) |  |

Release CPU/GPU programs set associated with the given render state and pass.

Parameters

  pass | The pass to release the programs from.
  renderState | The render state holds the programs.

## Friends And Related Function Documentation

## ◆ ProgramSet

friend class ProgramSet
| friend

## ◆ ShaderGenerator

friend class ShaderGenerator
| friend

## ◆ TargetRenderState

friend class TargetRenderState
| friend

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

- OgreShaderProgramManager.h