Skip to content

Commit

Permalink
UPBGE: Fix potential dynamic uniform for material specularity.
Browse files Browse the repository at this point in the history
Fix issue #518.
  • Loading branch information
panzergame committed Jul 29, 2017
1 parent b8153f2 commit 73c3843
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion source/blender/gpu/intern/gpu_material.c
Original file line number Diff line number Diff line change
Expand Up @@ -1104,7 +1104,7 @@ static void shade_one_light(GPUShadeInput *shi, GPUShadeResult *shr, GPULamp *la
(GPU_link_changed(shi->spec) || ma->spec != 0.0f || !(ma->constflag & MA_CONSTANT_MATERIAL)))
{
if (lamp->type == LA_HEMI) {
GPU_link(mat, "shade_hemi_spec", vn, lv, view, GPU_uniform(&ma->spec), shi->har, visifac, &t);
GPU_link(mat, "shade_hemi_spec", vn, lv, view, GPU_select_uniform(&ma->spec, GPU_DYNAMIC_MAT_SPEC, NULL, ma), shi->har, visifac, &t);
GPU_link(mat, "shade_add_spec", t, lcol, shi->specrgb, &outcol);
GPU_link(mat, "shade_add_clamped", shr->spec, outcol, &shr->spec);
}
Expand Down

0 comments on commit 73c3843

Please sign in to comment.