Blender Git Loki

Git Commits -> Revision 278011e

Revision 278011e by Jeroen Bakker (master)
November 24, 2020, 12:22 (GMT)
Fix T80748: Render Emissive Colors in Compositor Backdrop

This change will use the image engine to draw the backdrop of the compositor. With this patch the alpha blending will be done in Linear Scene Reference space and shows pure emissive colors.

See differential for an example image.

**Technical changes**

As only the backdrop drawing is done using the draw manager there are some technical changes.
1. The overlay buffer is partly drawn outside the draw manager. When drawing the backdrop image the overlay buffer needs to be masked to simulate premultiplied alpha under.
2. The backdrop of the node editor is done in region pixel space. A `DRWView` is constructed with this space.
3. UDIM textures uses world position to generate the UV coordinates. This has been implemented more strict by the `IMAGE_DRAW_FLAG_USE_WORLD_POS`. When the flag isn't used the local coordinates are used to generate the UV coordinates what is image space.
4. The draw manager now checks the actual `eSpaceType` of the space data to use different code paths. In the future the movie clip editor will be added.

NOTE: The preview images in nodes are drawn in display space and cannot show pure emissive colors. As preview images are used on more locations it is best to fix this in a separate patch.

Reviewed By: Cl�ment Foucault

Differential Revision: https://developer.blender.org/D9451

Commit Details:

Full Hash: 278011e44d433dc202b2ab8e7907e323fb23c82d
Parent Commit: 82cc21d
Lines Changed: +313, -186

12 Modified Paths:

/source/blender/draw/engines/image/image_engine.c (+205, -85) (Diff)
/source/blender/draw/engines/image/image_private.h (+2, -0) (Diff)
/source/blender/draw/engines/image/shaders/engine_image_frag.glsl (+10, -10) (Diff)
/source/blender/draw/engines/image/shaders/engine_image_vert.glsl (+5, -4) (Diff)
/source/blender/draw/engines/overlay/overlay_background.c (+7, -2) (Diff)
/source/blender/draw/engines/overlay/overlay_engine.c (+27, -11) (Diff)
/source/blender/draw/engines/overlay/overlay_grid.c (+3, -3) (Diff)
/source/blender/draw/engines/overlay/overlay_private.h (+1, -1) (Diff)
/source/blender/draw/engines/overlay/shaders/background_frag.glsl (+4, -0) (Diff)
/source/blender/draw/intern/draw_manager.c (+31, -6) (Diff)
/source/blender/editors/space_node/CMakeLists.txt (+1, -0) (Diff)
/source/blender/editors/space_node/drawnode.c (+17, -64) (Diff)
Tehnyt: Miika HämäläinenViimeksi päivitetty: 07.11.2014 14:18MiikaH:n Sivut a.k.a. MiikaHweb | 2003-2021