Ogre::LodStrategyManager Class Reference
LOD

Manager for lod strategies. More...

`#include <OgreLodStrategyManager.h>`

Inheritance diagram for Ogre::LodStrategyManager:
[legend]

List of all members.

## Public Member Functions

| LodStrategyManager ()
| Default constructor.
| ~LodStrategyManager ()
| Destructor.
void | addStrategy (LodStrategy *strategy)
| Add a strategy to the manager.
LodStrategy * | removeStrategy (const String &name)
| Remove a strategy from the manager with a specified name.
void | removeAllStrategies ()
| Remove and delete all strategies from the manager.
LodStrategy * | getStrategy (const String &name)
| Get the strategy with the specified name.
void | setDefaultStrategy (LodStrategy *strategy)
| Set the default strategy.
void | setDefaultStrategy (const String &name)
| Set the default strategy by name.
LodStrategy * | getDefaultStrategy ()
| Get the current default strategy.
MapIterator< StrategyMap > | getIterator ()
| Get an iterator for all contained strategies.
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 LodStrategyManager & | getSingleton (void)
| Override standard Singleton retrieval.
static LodStrategyManager * | getSingletonPtr (void)
| Override standard Singleton retrieval.

## Static Protected Attributes

static LodStrategyManager * | msSingleton

## Private Types

typedef map< String, LodStrategy * >::type | StrategyMap
| Map of strategies.

## Private Attributes

StrategyMap | mStrategies
| Internal map of strategies.
LodStrategy * | mDefaultStrategy
| Default strategy.

## Detailed Description

Manager for lod strategies.

Definition at line 46 of file OgreLodStrategyManager.h.

## Member Typedef Documentation

typedef map<String, LodStrategy *>::type Ogre::LodStrategyManager::StrategyMap`[private]`

Map of strategies.

Definition at line 49 of file OgreLodStrategyManager.h.

## Constructor & Destructor Documentation

Ogre::LodStrategyManager::LodStrategyManager | ( |  | ) |

Default constructor.

Ogre::LodStrategyManager::~LodStrategyManager | ( |  | ) |

Destructor.

## Member Function Documentation

void Ogre::LodStrategyManager::addStrategy | ( | LodStrategy * | strategy | ) |

Add a strategy to the manager.

LodStrategy* Ogre::LodStrategyManager::getDefaultStrategy | ( |  | ) |

Get the current default strategy.

MapIterator<StrategyMap> Ogre::LodStrategyManager::getIterator | ( |  | ) |

Get an iterator for all contained strategies.

static LodStrategyManager& Ogre::LodStrategyManager::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< LodStrategyManager >.

static LodStrategyManager* Ogre::LodStrategyManager::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< LodStrategyManager >.

LodStrategy* Ogre::LodStrategyManager::getStrategy | ( | const String & | name | ) |

Get the strategy with the specified name.

template<class Alloc >

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

Definition at line 95 of file OgreMemoryAllocatedObject.h.

template<class Alloc >

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

Definition at line 101 of file OgreMemoryAllocatedObject.h.

template<class Alloc >

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

Definition at line 107 of file OgreMemoryAllocatedObject.h.

template<class Alloc >

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

Definition at line 112 of file OgreMemoryAllocatedObject.h.

template<class Alloc >

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

Definition at line 118 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]`

operator new, with debug line info

Definition at line 67 of file OgreMemoryAllocatedObject.h.

template<class Alloc >

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

Definition at line 72 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 78 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 85 of file OgreMemoryAllocatedObject.h.

template<class Alloc >

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

Definition at line 90 of file OgreMemoryAllocatedObject.h.

void Ogre::LodStrategyManager::removeAllStrategies | ( |  | ) |

Remove and delete all strategies from the manager.

Remarks:
  All strategies are deleted. If finer control is required over strategy destruction, use removeStrategy.

LodStrategy* Ogre::LodStrategyManager::removeStrategy | ( | const String & | name | ) |

Remove a strategy from the manager with a specified name.

Remarks:
  The removed strategy is returned so the user can control how it is destroyed.

void Ogre::LodStrategyManager::setDefaultStrategy | ( | LodStrategy * | strategy | ) |

Set the default strategy.

void Ogre::LodStrategyManager::setDefaultStrategy | ( | const String & | name | ) |

Set the default strategy by name.

## Member Data Documentation

LodStrategy* Ogre::LodStrategyManager::mDefaultStrategy`[private]`

Default strategy.

Definition at line 55 of file OgreLodStrategyManager.h.

LodStrategyManager * Ogre::Singleton< LodStrategyManager >::msSingleton`[static, protected, inherited]`

Definition at line 75 of file OgreSingleton.h.

StrategyMap Ogre::LodStrategyManager::mStrategies`[private]`

Internal map of strategies.

Definition at line 52 of file OgreLodStrategyManager.h.

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

- OgreLodStrategyManager.h

Copyright © 2012 Torus Knot Software Ltd
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.
Last modified Sun Sep 2 2012 07:27:30