28#ifndef __CompositorManager_H__
29#define __CompositorManager_H__
244 : width(w), height(h), format(f), fsaa(aa), fsaaHint(aaHint), sRGBwrite(srgb)
Chain of compositor effects applying to one viewport.
An instance of a Compositor object for one Viewport.
Interface for compositor logics, which can be automatically binded to compositors,...
Class for managing Compositor settings for Ogre.
TexturesByDef mTexturesByDef
static CompositorManager & getSingleton(void)
Override standard Singleton retrieval.
CompositorLogic * getCompositorLogic(const String &name)
Get a compositor logic by its name.
void freePooledTextures(bool onlyIfUnreferenced=true)
Free pooled textures from the shared pool (compositor instances still using them will keep them in me...
CustomCompositionPass * getCustomCompositionPass(const String &name)
Get a custom composition pass by its name.
bool isInputToOutputTarget(CompositorInstance *inst, TexturePtr tex)
void parseScript(DataStreamPtr &stream, const String &groupName)
void setCompositorEnabled(Viewport *vp, const String &compositor, bool value)
Set the state of a compositor on a viewport to enabled or disabled.
map< Viewport *, CompositorChain * >::type Chains
void removeAll(void)
Overridden from ResourceManager since we have to clean up chains too.
static CompositorManager * getSingletonPtr(void)
Override standard Singleton retrieval.
vector< TexturePtr >::type TextureList
void _reconstructAllCompositorResources()
Internal method for forcing all active compositors to recreate their resources.
bool isInputPreviousTarget(CompositorInstance *inst, TexturePtr tex)
vector< CompositorInstance * >::type Instances
List of instances.
std::pair< String, String > StringPair
CustomCompositionPassMap mCustomCompositionPasses
VectorIterator< TextureList > TextureIterator
map< StringPair, TextureDefMap >::type ChainTexturesByDef
map< TextureDef, TextureList *, TextureDefLess >::type TexturesByDef
set< Texture * >::type UniqueTextureSet
void removeCompositor(Viewport *vp, const String &compositor)
Remove a compositor from a viewport.
void registerCompositorLogic(const String &name, CompositorLogic *logic)
Register a compositor logic for listening in to expecting composition techniques.
void unregisterCompositorLogic(const String &name)
Removes a listener for compositor logic registered with registerCompositorLogic.
map< String, CustomCompositionPass * >::type CustomCompositionPassMap
Map of registered custom composition passes.
bool isInputToOutputTarget(CompositorInstance *inst, const Ogre::String &localName)
CompositorPtr create(const String &name, const String &group, bool isManual=false, ManualResourceLoader *loader=0, const NameValuePairList *createParams=0)
Create a new compositor.
map< String, CompositorLogic * >::type CompositorLogicMap
Map of registered compositor logics.
CompositorChain * getCompositorChain(Viewport *vp)
Get the compositor chain for a Viewport.
ChainTexturesByDef mChainTexturesByDef
CompositorInstance * addCompositor(Viewport *vp, const String &compositor, int addPosition=-1)
Add a compositor to a viewport.
Renderable * _getTexturedRectangle2D()
Get a textured fullscreen 2D rectangle, for internal use.
CompositorLogicMap mCompositorLogics
virtual ~CompositorManager()
void removeCompositorChain(Viewport *vp)
Remove the compositor chain from a viewport if exists.
bool hasCompositorChain(Viewport *vp) const
Returns whether exists compositor chain for a viewport.
CompositorPtr getByName(const String &name, const String &groupName=ResourceGroupManager::AUTODETECT_RESOURCE_GROUP_NAME)
Get a resource by name.
void initialise(void)
Initialises the Compositor manager, which also triggers it to parse all available ....
void freeChains()
Clear composition chains for all viewports.
void registerCustomCompositionPass(const String &name, CustomCompositionPass *customPass)
Register a custom composition pass.
bool isInputPreviousTarget(CompositorInstance *inst, const Ogre::String &localName)
map< TextureDef, TexturePtr, TextureDefLess >::type TextureDefMap
Resource * createImpl(const String &name, ResourceHandle handle, const String &group, bool isManual, ManualResourceLoader *loader, const NameValuePairList *params)
Overridden from ResourceManager.
TexturePtr getPooledTexture(const String &name, const String &localName, size_t w, size_t h, PixelFormat f, uint aa, const String &aaHint, bool srgb, UniqueTextureSet &texturesAlreadyAssigned, CompositorInstance *inst, CompositionTechnique::TextureScope scope)
Utility function to get an existing pooled texture matching a given definition, or creating one if on...
Interface for custom composition passes, allowing custom operations (in addition to the quad,...
Interface describing a manual resource loader.
Allows the rendering of a simple 2D rectangle This class renders a simple 2D rectangle; this rectangl...
Abstract class defining the interface all renderable objects must implement.
static String AUTODETECT_RESOURCE_GROUP_NAME
Special resource group name which causes resource group to be automatically determined based on searc...
Defines a generic resource handler.
Abstract class representing a loadable resource (e.g.
Reference-counted shared pointer, used for objects where implicit destruction is required.
Template class for creating single-instance global classes.
Concrete IteratorWrapper for nonconst access to the underlying container.
An abstraction of a viewport, i.e.
map< String, String >::type NameValuePairList
Name / value parameter pair (first = name, second = value)
PixelFormat
The pixel format used for images, textures, and render surfaces.
unsigned long long int ResourceHandle
virtual ~TextureDefLess()
bool _OgreExport operator()(const TextureDef &x, const TextureDef &y) const
TextureDef(size_t w, size_t h, PixelFormat f, uint aa, const String &aaHint, bool srgb)
std::map< K, V, P, A > type