Commit: 0dc30e9dd8daab7c5afd833bf117c4838bf6100d
Author: Mike Erwin
Date:   Thu Mar 30 01:43:51 2017 -0400
Branches: blender2.8
https://developer.blender.org/rB0dc30e9dd8daab7c5afd833bf117c4838bf6100d

fix build on Mac/clang

Not all code paths returned a value, so we can use a safe default (8-bit RGBA) 
when the input is bogus.

===================================================================

M       source/blender/draw/intern/draw_manager.c

===================================================================

diff --git a/source/blender/draw/intern/draw_manager.c 
b/source/blender/draw/intern/draw_manager.c
index 8eafeb8b749..efa677240dd 100644
--- a/source/blender/draw/intern/draw_manager.c
+++ b/source/blender/draw/intern/draw_manager.c
@@ -1273,6 +1273,7 @@ static GPUTextureFormat convert_tex_format(int 
fbo_format, int *channels)
                case DRW_BUF_DEPTH_24: *channels = 1; return 
GPU_DEPTH_COMPONENT24;
                default:
                        BLI_assert(false);
+                       *channels = 4; return GPU_RGBA8;
        }
 }

_______________________________________________
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to