Compositor: Difference between revisions

Jump to navigation Jump to search
no edit summary
m (shuffle around to status paragraph)
No edit summary
Line 126: Line 126:
=== Passes ===
=== Passes ===


A pass wraps around an [http://public.vrac.iastate.edu/vancegroup/docs/OpenSceneGraphReferenceDocs-3.0/a00089.html osg::Camera]. The following types of passes are supported:
A pass wraps around an [http://public.vrac.iastate.edu/vancegroup/docs/OpenSceneGraphReferenceDocs-3.0/a00089.html osg::Camera]. Passes all have some common parameters:


; scene
; condition
: Renders the scene from the point of view given by the CameraGroup.
: A valid XML expression that enables the pass when met.
; shadow-map
; clear-color, clear-accum, clear-depth and clear-stencil
: Renders the scene from a light's point of view.
: Default values are black, black, 1.0 and 0 respectively.
; quad
; clear-color-bit, clear-accum-bit, clear-depth-bit and clear-stencil-bit
: Renders a fullscreen quad with an optional [[Effects|effect]] applied. Useful for screen space shaders (like SSAO, Screen Space Reflections or bloom) and deferred rendering.
: Default values are true, false, true, false, respectively.
 
There are specific pass types, each with their own set of custom parameters:
 
* '''scene'''
Renders the scene from the point of view given by the CameraGroup.
; clustered-forward
: Enables the use of clustered forward rendering for this pass.
; cubemap-face
: Ignores the given view and projection matrices and uses a custom one that renders the scene as if it was seen from inside a cubemap looking towards the specified face.
 
* '''quad'''
Renders a fullscreen quad with an optional [[Effects|effect]] applied. Useful for screen space shaders (like SSAO, Screen Space Reflections or bloom) and deferred rendering.
; geometry
: Specifies the x, y, width and height of the fullscreen quad inside the viewport using normalized coordinates.
; effect
: The quad will use this effect.
 
* '''shadow-map'''
Renders the scene from a light's point of view.
; light-num
: The OpenGL light number to use for this shadow map.
; near-m and far-m
: They specify the range of the shadow map.


Passes can render to a buffer (Render to Texture), to several buffers (Multiple Render Targets) or directly to the framebuffer. This is accomplished by the <code><attachment/></code> tag. Possible parameters of an attachment are:
Passes can render to a buffer (Render to Texture), to several buffers (Multiple Render Targets) or directly to the framebuffer. This is accomplished by the <code><attachment/></code> tag. Possible parameters of an attachment are:
343

edits

Navigation menu