[Bf-blender-cvs] [d89f9d70c52] blender2.8: Eevee: Fix bug with transparent object + volume rendering.
Clément Foucault
noreply at git.blender.org
Tue May 8 14:31:26 CEST 2018
Commit: d89f9d70c52001e09ee3ab80a3547ba140e00aec
Author: Clément Foucault
Date: Tue May 8 14:31:08 2018 +0200
Branches: blender2.8
https://developer.blender.org/rBd89f9d70c52001e09ee3ab80a3547ba140e00aec
Eevee: Fix bug with transparent object + volume rendering.
This was because the main_fb was not bound back to be updated.
Following draw calls were drawn without depth buffer.
===================================================================
M source/blender/draw/engines/eevee/eevee_volumes.c
===================================================================
diff --git a/source/blender/draw/engines/eevee/eevee_volumes.c b/source/blender/draw/engines/eevee/eevee_volumes.c
index 9b039345fce..700a8d81565 100644
--- a/source/blender/draw/engines/eevee/eevee_volumes.c
+++ b/source/blender/draw/engines/eevee/eevee_volumes.c
@@ -572,7 +572,11 @@ void EEVEE_volumes_resolve(EEVEE_ViewLayerData *UNUSED(sldata), EEVEE_Data *veda
SWAP(GPUFrameBuffer *, fbl->main_fb, fbl->effect_fb);
SWAP(GPUFrameBuffer *, fbl->main_color_fb, fbl->effect_color_fb);
SWAP(GPUTexture *, txl->color, txl->color_post);
+
+ /* Restore */
+ GPU_framebuffer_texture_detach(fbl->effect_fb, dtxl->depth);
GPU_framebuffer_texture_attach(fbl->main_fb, dtxl->depth, 0, 0);
+ GPU_framebuffer_bind(fbl->main_fb);
}
}
More information about the Bf-blender-cvs
mailing list