[Bf-blender-cvs] [cdf0df10a6d] blender2.8: DRW: Fix bound_ubo_slots allocation size.

Clément Foucault noreply at git.blender.org
Tue Mar 20 15:11:22 CET 2018


Commit: cdf0df10a6dd812918cabcfc2a702c9cf4a14fef
Author: Clément Foucault
Date:   Tue Mar 20 15:16:10 2018 +0100
Branches: blender2.8
https://developer.blender.org/rBcdf0df10a6dd812918cabcfc2a702c9cf4a14fef

DRW: Fix bound_ubo_slots allocation size.

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

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 dbcfa02c555..db59c083b42 100644
--- a/source/blender/draw/intern/draw_manager.c
+++ b/source/blender/draw/intern/draw_manager.c
@@ -452,7 +452,7 @@ static void drw_viewport_var_init(void)
 		DST.RST.bound_ubos = MEM_callocN(sizeof(GPUUniformBuffer *) * GPU_max_ubo_binds(), "Bound GPUUniformBuffer refs");
 	}
 	if (DST.RST.bound_ubo_slots == NULL) {
-		DST.RST.bound_ubo_slots = MEM_callocN(sizeof(char) * GPU_max_textures(), "Bound Ubo Slots");
+		DST.RST.bound_ubo_slots = MEM_callocN(sizeof(char) * GPU_max_ubo_binds(), "Bound Ubo Slots");
 	}
 
 	if (view_ubo == NULL) {



More information about the Bf-blender-cvs mailing list