OGRE: Ogre::ShadowTextureManager Class Reference - OGRE Documentation

# Ogre::ShadowTextureManager Class Reference

Class to manage the available shadow textures which may be shared between many SceneManager instances if formats agree. More...

`#include <OgreShadowTextureManager.h>`

Inheritance diagram for Ogre::ShadowTextureManager:

[legend]

List of all members.

## Public Member Functions
| ShadowTextureManager ()
virtual | ~ShadowTextureManager ()
virtual void | getShadowTextures (const ShadowTextureConfigList &config, ShadowTextureList &listToPopulate)
| Populate an incoming list with shadow texture references as requested in the configuration list.
virtual TexturePtr | getNullShadowTexture (PixelFormat format)
| Get an appropriately defined 'null' texture, i.e.
virtual void | clearUnused ()
| Remove any shadow textures that are no longer being referenced.
virtual void | clear ()
| Dereference all the shadow textures kept in this class and remove them from TextureManager; note that it is up to the SceneManagers to clear their local references.
void * | operator new (size_t sz, const char *file, int line, const char *func)
| operator new, with debug line info
void * | operator new (size_t sz)
void * | operator new (size_t sz, void *ptr)
| placement operator new
void * | operator new[] (size_t sz, const char *file, int line, const char *func)
| array operator new, with debug line info
void * | operator new[] (size_t sz)
void | operator delete (void *ptr)
void | operator delete (void *ptr, void *)
void | operator delete (void *ptr, const char *, int, const char *)
void | operator delete[] (void *ptr)
void | operator delete[] (void *ptr, const char *, int, const char *)
## Static Public Member Functions
static ShadowTextureManager & | getSingleton (void)
| Override standard Singleton retrieval.
static ShadowTextureManager * | getSingletonPtr (void)
| Override standard Singleton retrieval.
## Protected Attributes
ShadowTextureList | mTextureList
ShadowTextureList | mNullTextureList
size_t | mCount
## Static Protected Attributes
static T * | ms_Singleton

## Detailed Description

Class to manage the available shadow textures which may be shared between many SceneManager instances if formats agree.

Remarks:
  The management of the list of shadow textures has been separated out into a dedicated class to enable the clean management of shadow textures across many scene manager instances. Where multiple scene managers are used with shadow textures, the configuration of those shadows may or may not be consistent - if it is, it is good to centrally manage the textures so that creation and destruction responsibility is clear.

Definition at line 72 of file OgreShadowTextureManager.h.

## Constructor & Destructor Documentation

Ogre::ShadowTextureManager::ShadowTextureManager | ( |  | ) |

virtual Ogre::ShadowTextureManager::~ShadowTextureManager | ( |  | ) | `[virtual]`

## Member Function Documentation

virtual void Ogre::ShadowTextureManager::getShadowTextures | ( | const ShadowTextureConfigList & | config,
|  | ShadowTextureList & | listToPopulate |
| ) |  |  | `[virtual]`

Populate an incoming list with shadow texture references as requested in the configuration list.

virtual TexturePtr Ogre::ShadowTextureManager::getNullShadowTexture | ( | PixelFormat | format | ) | `[virtual]`

Get an appropriately defined 'null' texture, i.e.

one which will always result in no shadows.

virtual void Ogre::ShadowTextureManager::clearUnused | ( |  | ) | `[virtual]`

Remove any shadow textures that are no longer being referenced.

Remarks:
  This should be called fairly regularly since references may take a little while to disappear in some cases (if referenced by materials)

virtual void Ogre::ShadowTextureManager::clear | ( |  | ) | `[virtual]`

Dereference all the shadow textures kept in this class and remove them from TextureManager; note that it is up to the SceneManagers to clear their local references.

static ShadowTextureManager& Ogre::ShadowTextureManager::getSingleton | ( | void |  | ) | `[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.

Reimplemented from Ogre::Singleton< T >.

static ShadowTextureManager* Ogre::ShadowTextureManager::getSingletonPtr | ( | void |  | ) | `[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.

Reimplemented from Ogre::Singleton< T >.

template<class Alloc>

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

operator new, with debug line info

Definition at line 62 of file OgreMemoryAllocatedObject.h.

template<class Alloc>

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

Definition at line 67 of file OgreMemoryAllocatedObject.h.

template<class Alloc>

void* Ogre::AllocatedObject< Alloc >::operator new | ( | size_t | sz,
|  | void * | ptr |
| ) |  |  | `[inherited]`

placement operator new

Definition at line 73 of file OgreMemoryAllocatedObject.h.

template<class Alloc>

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

array operator new, with debug line info

Definition at line 79 of file OgreMemoryAllocatedObject.h.

template<class Alloc>

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

Definition at line 84 of file OgreMemoryAllocatedObject.h.

template<class Alloc>

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

Definition at line 89 of file OgreMemoryAllocatedObject.h.

template<class Alloc>

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

Definition at line 95 of file OgreMemoryAllocatedObject.h.

template<class Alloc>

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

Definition at line 101 of file OgreMemoryAllocatedObject.h.

template<class Alloc>

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

Definition at line 106 of file OgreMemoryAllocatedObject.h.

template<class Alloc>

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

Definition at line 112 of file OgreMemoryAllocatedObject.h.

## Member Data Documentation

ShadowTextureList Ogre::ShadowTextureManager::mTextureList`[protected]`

Definition at line 75 of file OgreShadowTextureManager.h.

ShadowTextureList Ogre::ShadowTextureManager::mNullTextureList`[protected]`

Definition at line 76 of file OgreShadowTextureManager.h.

size_t Ogre::ShadowTextureManager::mCount`[protected]`

Definition at line 77 of file OgreShadowTextureManager.h.

template<typename T>

T* Ogre::Singleton< T >::ms_Singleton`[static, protected, inherited]`

Definition at line 61 of file OgreSingleton.h.

Referenced by Ogre::Singleton< Ogre::FontManager >::getSingleton(), Ogre::Singleton< Ogre::FontManager >::getSingletonPtr(), Ogre::Singleton< Ogre::FontManager >::Singleton(), and Ogre::Singleton< Ogre::FontManager >::~Singleton().

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

- OgreShadowTextureManager.h

Copyright © 2008 Torus Knot Software Ltd
This work is licensed under a Creative Commons Attribution-ShareAlike 2.5 License.
Last modified Sun Jul 26 11:36:59 2009