Go to the documentation of this file.
28 #ifndef __OverlayManager_H__
29 #define __OverlayManager_H__
211 return (mTemplates.find (strName) != mTemplates.end()) ;
Abstract definition of a 2D element to be displayed in an Overlay.
void destroyAll(void)
Destroys all existing overlays.
const StringVector & getScriptPatterns(void) const
Gets the file patterns which should be used to find scripts for this class.
Defines the interface which all components wishing to supply OverlayElement subclasses must implement...
Superclass for all objects that wish to use custom memory allocators when their new / delete operator...
bool parseChildren(DataStreamPtr &chunk, const String &line, Overlay *pOverlay, bool isTemplate, OverlayContainer *parent=NULL)
bool hasViewportChanged(void) const
Method for determining if the viewport has changed dimensions.
OverlayElement * getOverlayElement(const String &name, bool isTemplate=false)
Gets a reference to an existing element.
Manages Overlay objects, parsing them from .overlay files and storing a lookup library of them.
void destroyAllOverlayElements(bool isTemplate=false)
Destroys all the OverlayElement created so far.
A viewpoint from which the scene will be rendered.
void destroy(const String &name)
Destroys an existing overlay by name.
void destroyOverlayElement(const String &instanceName, bool isTemplate=false)
Destroys a OverlayElement.
map< String, OverlayElement * >::type ElementMap
void skipToNextCloseBrace(DataStreamPtr &chunk)
vector< String >::type StringVector
void skipToNextOpenBrace(DataStreamPtr &chunk)
Overlay * create(const String &name)
Create a new Overlay.
LoadedScripts mLoadedScripts
TemplateIterator getTemplateIterator()
Returns an iterator over all templates in this manager.
void destroyOverlayElementImpl(const String &instanceName, ElementMap &elementMap)
OverlayElement * createOverlayElementImpl(const String &typeName, const String &instanceName, ElementMap &elementMap)
OrientationMode getViewportOrientationMode(void) const
Gets the orientation mode of the destination viewport.
Real getLoadingOrder(void) const
Gets the relative loading order of scripts of this type.
void parseElementAttrib(const String &line, Overlay *pOverlay, OverlayElement *pElement)
bool hasOverlayElementImpl(const String &name, ElementMap &elementMap)
StringVector mScriptPatterns
static OverlayManager & getSingleton(void)
Override standard Singleton retrieval.
OrientationMode
Specifies orientation mode.
Overlay * getByName(const String &name)
Retrieve an Overlay by name.
An abstraction of a viewport, i.e.
#define _OgreOverlayExport
static OverlayManager * getSingletonPtr(void)
Override standard Singleton retrieval.
int getViewportHeight(void) const
Gets the height of the destination viewport in pixels.
map< String, OverlayElementFactory * >::type FactoryMap
Template class for creating single-instance global classes.
OverlayElement * createOverlayElementFromTemplate(const String &templateName, const String &typeName, const String &instanceName, bool isTemplate=false)
const FactoryMap & getOverlayElementFactoryMap() const
Get const access to the list of registered OverlayElement factories.
bool hasOverlayElement(const String &name, bool isTemplate=false)
Tests if an element exists.
void destroy(Overlay *overlay)
Destroys an existing overlay.
void parseScript(DataStreamPtr &stream, const String &groupName)
Parse a script file.
void addOverlayElementFactory(OverlayElementFactory *elemFactory)
Registers a new OverlayElementFactory with this manager.
OverlayMapIterator getOverlayIterator(void)
int getViewportWidth(void) const
Gets the width of the destination viewport in pixels.
Abstract class defining the interface used by classes which wish to perform script loading to define ...
Concrete IteratorWrapper for nonconst access to the underlying key-value container.
set< String >::type LoadedScripts
bool isTemplate(String strName) const
OverlayElement * getOverlayElementImpl(const String &name, ElementMap &elementMap)
void destroyOverlayElement(OverlayElement *pInstance, bool isTemplate=false)
Destroys a OverlayElement.
ElementMap & getElementMap(bool isTemplate)
float Real
Software floating point type.
bool mViewportDimensionsChanged
OverlayElement * cloneOverlayElementFromTemplate(const String &templateName, const String &instanceName)
void destroyOverlayElementImpl(OverlayElement *pInstance, ElementMap &elementMap)
virtual ~OverlayManager()
void parseAttrib(const String &line, Overlay *pOverlay)
void parseNewElement(DataStreamPtr &chunk, String &elemType, String &elemName, bool isContainer, Overlay *pOverlay, bool isTemplate, String templateName=String(""), OverlayContainer *container=0)
void _queueOverlaysForRendering(Camera *cam, RenderQueue *pQueue, Viewport *vp)
Internal method for queueing the visible overlays for rendering.
OverlayElement * createOverlayElementFromFactory(const String &typeName, const String &instanceName)
map< String, Overlay * >::type OverlayMap
MapIterator< ElementMap > TemplateIterator
Represents a layer which is rendered on top of the 'normal' scene contents.
OrientationMode mLastViewportOrientationMode
MapIterator< OverlayMap > OverlayMapIterator
void destroyAllOverlayElementsImpl(ElementMap &elementMap)
Class to manage the scene object rendering queue.
A 2D element which contains other OverlayElement instances.
OverlayElement * createOverlayElement(const String &typeName, const String &instanceName, bool isTemplate=false)
Creates a new OverlayElement of the type requested.
Real getViewportAspectRatio(void) const
Copyright © 2012 Torus Knot Software Ltd

This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.