diff options
Diffstat (limited to 'source/blender/gpu')
-rw-r--r-- | source/blender/gpu/intern/gpu_material.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/gpu/intern/gpu_material.c b/source/blender/gpu/intern/gpu_material.c index 6dff5802c31..62c3f848284 100644 --- a/source/blender/gpu/intern/gpu_material.c +++ b/source/blender/gpu/intern/gpu_material.c @@ -693,7 +693,7 @@ static void shade_one_light(GPUShadeInput *shi, GPUShadeResult *shr, GPULamp *la shr->spec, &shr->spec); add_user_list(&mat->lamps, lamp); - add_user_list(&lamp->materials, ma); + add_user_list(&lamp->materials, shi->gpumat->ma); return; } @@ -702,7 +702,7 @@ static void shade_one_light(GPUShadeInput *shi, GPUShadeResult *shr, GPULamp *la } else if((G.fileflags & G_FILE_GLSL_NO_SHADOWS) && (lamp->mode & LA_ONLYSHADOW)) { add_user_list(&mat->lamps, lamp); - add_user_list(&lamp->materials, ma); + add_user_list(&lamp->materials, shi->gpumat->ma); return; } else @@ -755,7 +755,7 @@ static void shade_one_light(GPUShadeInput *shi, GPUShadeResult *shr, GPULamp *la } add_user_list(&mat->lamps, lamp); - add_user_list(&lamp->materials, ma); + add_user_list(&lamp->materials, shi->gpumat->ma); } static void material_lights(GPUShadeInput *shi, GPUShadeResult *shr) |