Page MenuHome

EEVEE: GLSL Renderpasses
ClosedPublic

Authored by Jeroen Bakker (jbakker) on Nov 7 2019, 2:39 PM.

Details

Summary

Most of the renderpasses in EEVEE used post-processing on the CPU. For
final image rendering this is sufficient, but when we want to display
the data to the user we don't want to transfer to the CPU to do post
processing to then upload it back to the GPU to display the result.

This patch moves the renderpass postprocessing to a GLSL shader.

This is the first step to do, before we will enable the renderpasses in the viewport.

Diff Detail

Repository
rB Blender

Event Timeline

source/blender/draw/engines/eevee/eevee_private.h
66

remove this define. it isn't used.

source/blender/draw/engines/eevee/eevee_renderpasses.c
61

Remove comment, is relevant for the next phase, not the current patch

source/blender/draw/engines/eevee/eevee_renderpasses.c
70

Add some documentation about the usage and expected results.

129

latest

source/blender/draw/engines/eevee/shaders/renderpass_postprocess_frag.glsl
2

remove line, is an unused define

source/blender/draw/engines/eevee/shaders/renderpass_postprocess_frag.glsl
32

we have a function in bsdf_common.lib for converting to view depth

Jeroen Bakker (jbakker) planned changes to this revision.Nov 8 2019, 10:23 AM

after testing I want to do some more code reorganization. It seems that also later we always need the renderpass_fb, what leads a different interface.

Code refactor and cleanup

Jeroen Bakker (jbakker) marked an inline comment as done.Nov 21 2019, 8:16 AM

Optimized shader normal pass

source/blender/draw/engines/eevee/shaders/renderpass_postprocess_frag.glsl
41

any(notEqual())

This revision is now accepted and ready to land.Nov 27 2019, 3:05 PM
This revision was automatically updated to reflect the committed changes.