Current Situation
Currently, post-processing in FUDGE is hard-coded in the render loop:
- Opaque nodes are drawn first.
- Specific effects like SSAO, bloom and outline are applied in a fixed order.
- Semitransparent objects are drawn after opaque objects.
- Finally, the framebuffer is copied to the canvas.
This approach ties the engine and effects together, making it impossible for creators to implement custom pipelines or reorder/compose post-processing effects.
Proposed Idea
Introduce a custom render pipeline or compositor system:
- Allow creators to define their own post-processing sequences, combining effects like bloom, SSAO, outline, custom shaders, or entirely new effects.
- The engine itself would also use this compositing system, making core rendering flexible and modular.
- Post-processing would no longer be rigidly ordered or hard-coded in the render loop.
Expected Benefits
- Flexible post-processing: Creators can implement custom effects or reorder existing ones without modifying engine internals.
- Modular engine rendering: Core engine rendering can leverage the same pipeline, avoiding duplicated code for engine and creator effects.
- Improved experimentation: Enables rapid iteration and testing of new visual effects directly from user scripts or scene configuration.
- Potential performance optimization: By allowing fine-grained control over passes, redundant framebuffer operations could be reduced, and unnecessary effects could be skipped.
- Future-proofing: Easier integration of advanced features like HDR pipelines, multiple render targets, or deferred rendering compositing.
Current Situation
Currently, post-processing in FUDGE is hard-coded in the render loop:
This approach ties the engine and effects together, making it impossible for creators to implement custom pipelines or reorder/compose post-processing effects.
Proposed Idea
Introduce a custom render pipeline or compositor system:
Expected Benefits