Compositor: Difference between revisions

65 bytes removed ,  20 February 2019
no edit summary
No edit summary
No edit summary
Line 138: Line 138:
; wrap-s, wrap-t and wrap-r (Optional)
; wrap-s, wrap-t and wrap-r (Optional)
: They change the wrap mode for each coordinate. Possible values are: clamp, clamp-to-edge, clamp-to-border, repeat and mirror. The default value for every coordinate is clamp-to-border.
: They change the wrap mode for each coordinate. Possible values are: clamp, clamp-to-edge, clamp-to-border, repeat and mirror. The default value for every coordinate is clamp-to-border.
; condition
: A valid boolean condition to enable the buffer at startup (doesn't work at runtime).


A typical [[PropertyList XML File|property tree structure]] describing a buffer may be as follows:
A typical [[PropertyList XML File|property tree structure]] describing a buffer may be as follows:
Line 171: Line 173:
; effect-override
; effect-override
: Use the specified effect to draw every object. This is useful for special passes like G-buffer and shadow map optimization.
: Use the specified effect to draw every object. This is useful for special passes like G-buffer and shadow map optimization.
; condition
: A valid boolean condition to enable the pass at startup (doesn't work at runtime).


There are specific pass types, each with their own set of custom parameters:
There are specific pass types, each with their own set of custom parameters:
Line 215: Line 219:
; multisample-color-samples (Optional)
; multisample-color-samples (Optional)
: MSAA color samples. Default value is 0.
: MSAA color samples. Default value is 0.
; condition
: A valid boolean condition to enable the attachment at startup (doesn't work at runtime).


Passes can also receive buffers as input and use them in their shaders. This is accomplished by the <code><binding/></code> tag, which has the following parameters:
Passes can also receive buffers as input and use them in their shaders. This is accomplished by the <code><binding/></code> tag, which has the following parameters:
Line 222: Line 228:
; unit
; unit
: The texture unit to place the texture on. Effects will be able to access the buffer on this texture unit.
: The texture unit to place the texture on. Effects will be able to access the buffer on this texture unit.
; condition
: A valid boolean condition to enable the binding at startup (doesn't work at runtime).


Example XML for a ''scene'' type pass:
Example XML for a ''scene'' type pass:
Line 283: Line 291:
* Finish Clustered Forward Rendering.
* Finish Clustered Forward Rendering.
* Some kind of versioning system to be able to make breaking changes in the future if/when the compositor is updated in any significant way, without people having to manually update their configs.
* Some kind of versioning system to be able to make breaking changes in the future if/when the compositor is updated in any significant way, without people having to manually update their configs.
* Coherently support static conditional branching (<condition> tags available for both passes and buffers), as well as using property tree parameters (via a <property> tag ala Effects). For simplicity and to avoid major architectural changes, these conditional checks should only be performed on startup (no dynamic branching). For example, the user should be able to select if they want shadows and their size in the launcher, not on the in-sim Rendering dialog.


== Known Issues ==
== Known Issues ==
343

edits