[Bf-blender-cvs] [0610bc88a3b] blender2.8: Eevee: Re fix Compilation on MSVC

Clément Foucault noreply at git.blender.org
Tue Apr 18 22:34:49 CEST 2017


Commit: 0610bc88a3b0e0bef3c2fba22b45fdfd233389f6
Author: Clément Foucault
Date:   Tue Apr 18 22:34:44 2017 +0200
Branches: blender2.8
https://developer.blender.org/rB0610bc88a3b0e0bef3c2fba22b45fdfd233389f6

Eevee: Re fix Compilation on MSVC

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

M	source/blender/draw/engines/eevee/eevee.c
M	source/blender/draw/intern/DRW_render.h

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

diff --git a/source/blender/draw/engines/eevee/eevee.c b/source/blender/draw/engines/eevee/eevee.c
index b898d66b155..ccb111a58bc 100644
--- a/source/blender/draw/engines/eevee/eevee.c
+++ b/source/blender/draw/engines/eevee/eevee.c
@@ -299,7 +299,7 @@ static DRWShadingGroup *eevee_cube_shgroup(struct GPUShader *sh, DRWPass *pass,
 	DRWShadingGroup *grp = DRW_shgroup_instance_create(sh, pass, geom);
 
 	for (int i = 0; i < 6; ++i)
-		DRW_shgroup_dynamic_call_add(grp, NULL);
+		DRW_shgroup_dynamic_call_add_empty(grp);
 
 	return grp;
 }
diff --git a/source/blender/draw/intern/DRW_render.h b/source/blender/draw/intern/DRW_render.h
index b4baa6d7b4c..765ce2934fe 100644
--- a/source/blender/draw/intern/DRW_render.h
+++ b/source/blender/draw/intern/DRW_render.h
@@ -250,6 +250,9 @@ void DRW_shgroup_dynamic_call_add_array(DRWShadingGroup *shgroup, const void *at
 	const void *array[] = {__VA_ARGS__}; \
 	DRW_shgroup_dynamic_call_add_array(shgroup, array, (sizeof(array) / sizeof(*array))); \
 } while (0)
+#define DRW_shgroup_dynamic_call_add_empty(shgroup) do { \
+	DRW_shgroup_dynamic_call_add_array(shgroup, NULL, 0); \
+} while (0)
 
 void DRW_shgroup_state_set(DRWShadingGroup *shgroup, DRWState state);
 void DRW_shgroup_attrib_int(DRWShadingGroup *shgroup, const char *name, int size);




More information about the Bf-blender-cvs mailing list