|
| CompositorWorkspace (IdType id, const CompositorWorkspaceDef *definition, const CompositorChannelVec &externalRenderTargets, SceneManager *sceneManager, Camera *defaultCam, RenderSystem *renderSys, bool bEnabled, uint8 executionMask, uint8 viewportModifierMask, const Vector4 &vpOffsetScale, const UavBufferPackedVec *uavBuffers, const ResourceLayoutMap *initialLayouts, const ResourceAccessMap *initialUavAccess) |
|
virtual | ~CompositorWorkspace () |
|
void | _beginUpdate (bool forceBeginFrame) |
| Call before _update unless the final render target is not a render window. More...
|
|
void | _endUpdate (bool forceEndFrame) |
| Call after _update unless the final render target is not a render window. More...
|
|
void | _notifyBarriersDirty (void) |
|
void | _swapFinalTarget (vector< TextureGpu *>::type &swappedTargets) |
| In the case of RenderWindows, swaps/copies/flips the front with the back buffer. More...
|
|
void | _update (void) |
| Updates the workspace's nodes. More...
|
|
void | _validateFinalTarget (void) |
| For compatibility with D3D9, forces a device lost check on the RenderWindow, so that BeginScene doesn't fail. More...
|
|
void | addListener (CompositorWorkspaceListener *listener) |
|
void | fillUavDependenciesForNextWorkspace (ResourceLayoutMap &outInitialLayouts, ResourceAccessMap &outInitialUavAccess) const |
| When two workspaces work on the same channels/textures, to avoid race conditions in Compute Shaders each workspace needs to know what the the previous workspace did; and that information must be supplied during workspace creation. More...
|
|
Camera * | findCamera (IdString cameraName) const |
| Finds a camera in the scene manager we have. More...
|
|
CompositorNode * | findNode (IdString aliasName, bool includeShadowNodes=false) const |
| Finds a node instance with the given aliased name. More...
|
|
CompositorNode * | findNodeNoThrow (IdString aliasName, bool includeShadowNodes=false) const |
|
CompositorShadowNode * | findOrCreateShadowNode (IdString nodeDefName, bool &bCreated) |
| Finds a shadow node given it's definition name. More...
|
|
CompositorShadowNode * | findShadowNode (IdString nodeDefName) const |
| Finds a shadow node instance with a given name. More...
|
|
bool | getAmalgamatedProfiling (void) const |
|
CompositorManager2 * | getCompositorManager () |
| Gets the compositor manager (non const) More...
|
|
const CompositorManager2 * | getCompositorManager () const |
| Gets the compositor manager (const version) More...
|
|
Camera * | getDefaultCamera () const |
| Gets the default camera passed through mDefaultViewport. More...
|
|
const CompositorWorkspaceDef * | getDefinition (void) |
|
bool | getEnabled () const |
|
uint8 | getExecutionMask (void) const |
|
const CompositorChannelVec & | getExternalRenderTargets (void) const |
| Usually by convention the RenderTarget[0] is the one we're rendering to. May be empty. More...
|
|
TextureGpu * | getFinalTarget (void) const |
| Returns the RenderTarget we're rendering to. More...
|
|
size_t | getFrameCount (void) const |
|
const CompositorNamedBufferVec & | getGlobalBuffers (void) const |
|
const CompositorChannel & | getGlobalTexture (IdString name) const |
|
IdType | getId () const |
| Get the unique id of this object. More...
|
|
CompositorWorkspaceListener * | getListener (void) const |
|
const CompositorWorkspaceListenerVec & | getListeners (void) const |
|
const CompositorNodeVec & | getNodeSequence (void) const |
|
const ResourceLayoutMap & | getResourcesLayout (void) const |
|
SceneManager * | getSceneManager () const |
|
const ResourceAccessMap & | getUavsAccess (void) const |
|
const Vector4 & | getViewportModifier (void) const |
|
uint8 | getViewportModifierMask (void) const |
|
bool | isValid (void) const |
| Only valid workspaces can update without crashing. More...
|
|
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 *) |
|
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 * | operator new (size_t sz, void *ptr) |
| placement operator new More...
|
|
void * | operator new[] (size_t sz, const char *file, int line, const char *func) |
| array operator new, with debug line info More...
|
|
void * | operator new[] (size_t sz) |
|
bool | operator() (const IdObject *left, const IdObject *right) |
|
bool | operator() (const IdObject &left, const IdObject &right) |
|
void | reconnectAllNodes (void) |
| Reconnects all nodes. More...
|
|
void | recreateAllNodes (void) |
| Destroys and recreates all nodes. More...
|
|
void | removeListener (CompositorWorkspaceListener *listener) |
|
void | resetAllNumPassesLeft (void) |
| Resets the number of passes left for every pass (. More...
|
|
void | setAmalgamatedProfiling (bool bEnabled) |
| When building with OGRE_PROFILING enabled, setting this option to true will cause the profiler to collapse all per-pass profiling information into one group. More...
|
|
void | setEnabled (bool bEnabled) |
|
void | setListener (CompositorWorkspaceListener *listener) |
|
void | setViewportModifier (const Vector4 &modifier) |
|
void | setViewportModifierMask (uint8 mask) |
|
A compositor workspace is the main interface to render into an RT, be it a RenderWindow or an RTT (Render Texture Target).
Whereas Ogre 1.x needed you to set a Viewport in order to render to an RTT or RW and then call renderTarget->update, now you need to set a workspace definition instead and call workspace->_update().
- Compositors are not just a "fancy effects" system anymore, they tell Ogre how you want to render the scene. You can't render to an RT without setting a compositor!
- A workspace may be instantiated multiple times for different RTs, or using different cameras (i.e. multiple monitors, stereo 3D, etc), while they all will share the same definition. A workspace definition (
- See also
- CompositorWorkspaceDef) contains all the information needed by this CompositorWorkspace to instantiate and know which nodes to create and how to connect them. CompositorNodeDef A workspace may define global textures that are visible to all of its Node instances.
- If you want to have (e.g.) two monitors rendering the same but with different compositor effects, you will also have to create two different definitions (CompositorWorkspaceDefs)
- The intention of Ogre 2.0's compositor is to ideally have one Workspace per monitor (or per eye) while handling all RTTs inside that workspace with compositor nodes, local and global textures (including manually updated stuff like procedural textures, terrain's auto generated normal maps, etc); but it is also possible to do things the 1.x way: use additional Workspaces for manually rendering and controlling RTTs.
- Users with basic needs (no advanced effects) can
- See also
- CompositorManager2::createBasicWorkspaceDef for quickly having a basic definition set for them.
- For more information about Compositors, consult the Ogre 2.0 Porting Manual in the Docs folder.
- Author
- Matias N. Goldberg
- Version
- 1.1