Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClément Foucault <foucault.clem@gmail.com>2020-10-14 19:18:42 +0300
committerClément Foucault <foucault.clem@gmail.com>2020-10-14 19:53:41 +0300
commit57de5686048f1eac07985eb2991f0b6f6c4fee22 (patch)
treeea4e5b4530444f8e3fb3e260b081c6a3993a04e0 /source/blender/editors/screen/area.c
parent327107412032d075c63427d86e5154a5e37b8d4a (diff)
Fix T81004 Python: Images drawn in the Sequence Editor have wrong colors
This was caused by the sequencer using a sRGB buffer without using the sRGB transform. This patch make it so that the framebuffer is rebound using the sRGB transform before the python draw callbacks.
Diffstat (limited to 'source/blender/editors/screen/area.c')
-rw-r--r--source/blender/editors/screen/area.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/editors/screen/area.c b/source/blender/editors/screen/area.c
index 6399778f62b..1a8c74c59b1 100644
--- a/source/blender/editors/screen/area.c
+++ b/source/blender/editors/screen/area.c
@@ -552,7 +552,10 @@ void ED_region_do_draw(bContext *C, ARegion *region)
* for drawing of borders/gestures etc */
ED_region_pixelspace(region);
+ GPUFrameBuffer *fb = GPU_framebuffer_active_get();
+ GPU_framebuffer_bind(fb);
ED_region_draw_cb_draw(C, region, REGION_DRAW_POST_PIXEL);
+ GPU_framebuffer_bind_no_srgb(fb);
region_draw_azones(area, region);