[Bf-blender-cvs] [0926b896b6b] blender2.8: Eevee: Fix crash with transparency.

Clément Foucault noreply at git.blender.org
Tue Jul 18 10:11:38 CEST 2017


Commit: 0926b896b6b329a39bba7ddd10b92135147e416f
Author: Clément Foucault
Date:   Mon Jul 17 13:59:53 2017 +0200
Branches: blender2.8
https://developer.blender.org/rB0926b896b6b329a39bba7ddd10b92135147e416f

Eevee: Fix crash with transparency.

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

M	source/blender/draw/engines/eevee/eevee_materials.c

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

diff --git a/source/blender/draw/engines/eevee/eevee_materials.c b/source/blender/draw/engines/eevee/eevee_materials.c
index 46ed858603d..a526bdbefb5 100644
--- a/source/blender/draw/engines/eevee/eevee_materials.c
+++ b/source/blender/draw/engines/eevee/eevee_materials.c
@@ -801,7 +801,7 @@ static void material_opaque(
 			*shgrp_depth = DRW_shgroup_material_create(*gpumat_depth, do_cull ? psl->depth_pass_cull : psl->depth_pass);
 			*shgrp_depth_clip = DRW_shgroup_material_create(*gpumat_depth, do_cull ? psl->depth_pass_clip_cull : psl->depth_pass_clip);
 
-			if (shgrp_depth) {
+			if (*shgrp != NULL) {
 				if (ma->blend_method == MA_BM_CLIP) {
 					DRW_shgroup_uniform_float(*shgrp_depth, "alphaThreshold", &ma->alpha_threshold, 1);
 					DRW_shgroup_uniform_float(*shgrp_depth_clip, "alphaThreshold", &ma->alpha_threshold, 1);




More information about the Bf-blender-cvs mailing list