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
path: root/source
diff options
context:
space:
mode:
authorClément Foucault <foucault.clem@gmail.com>2021-11-25 15:40:04 +0300
committerClément Foucault <foucault.clem@gmail.com>2021-11-25 15:40:04 +0300
commit845716e6002752bed1bf78a911a47729816a1c80 (patch)
tree07405d0447af059e8590eecf19ed1a74da42c9bb /source
parent82808e18e6562e9c06626a4e938cb2ad4fa34a0f (diff)
Fix T92609 Default Compositing tab shows red overlay when stereoscopy is turned on
This was caused by the drawing not being done on the right frammebuffer.
Diffstat (limited to 'source')
-rw-r--r--source/blender/gpu/intern/gpu_viewport.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/source/blender/gpu/intern/gpu_viewport.c b/source/blender/gpu/intern/gpu_viewport.c
index ccd9a4c061b..c9dbb94eb87 100644
--- a/source/blender/gpu/intern/gpu_viewport.c
+++ b/source/blender/gpu/intern/gpu_viewport.c
@@ -590,11 +590,12 @@ GPUTexture *GPU_viewport_depth_texture(GPUViewport *viewport)
/* Overlay framebuffer for drawing outside of DRW module. */
GPUFrameBuffer *GPU_viewport_framebuffer_overlay_get(GPUViewport *viewport)
{
- GPU_framebuffer_ensure_config(&viewport->overlay_fb,
- {
- GPU_ATTACHMENT_TEXTURE(viewport->depth_tx),
- GPU_ATTACHMENT_TEXTURE(viewport->color_overlay_tx[0]),
- });
+ GPU_framebuffer_ensure_config(
+ &viewport->overlay_fb,
+ {
+ GPU_ATTACHMENT_TEXTURE(viewport->depth_tx),
+ GPU_ATTACHMENT_TEXTURE(viewport->color_overlay_tx[viewport->active_view]),
+ });
return viewport->overlay_fb;
}