Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAntonioya <blendergit@gmail.com>2019-07-27 18:37:31 +0300
committerAntonioya <blendergit@gmail.com>2019-07-29 13:10:48 +0300
commitd438e71729d1e95edf58ee6b8e99def22adf813e (patch)
treed030dc5014d82e2bd3e33904a4c991a56ad171b7 /source/blender/draw
parentfd730fce0c202342cbc39f4c196c93a2f24ecc01 (diff)
GPencil: Use uniform_int_copy instead to pass reference
The constant variable was passed as reference to constant variable, but it's better use the new function to copy values. This could be the problem with T67772
Diffstat (limited to 'source/blender/draw')
-rw-r--r--source/blender/draw/engines/gpencil/gpencil_shader_fx.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/source/blender/draw/engines/gpencil/gpencil_shader_fx.c b/source/blender/draw/engines/gpencil/gpencil_shader_fx.c
index 306444303e2..0f4043ce278 100644
--- a/source/blender/draw/engines/gpencil/gpencil_shader_fx.c
+++ b/source/blender/draw/engines/gpencil/gpencil_shader_fx.c
@@ -463,12 +463,11 @@ static void gpencil_fx_shadow(ShaderFxData *fx,
DRW_shgroup_uniform_vec3(fx_shgrp, "loc", fxd->runtime.loc, 1);
}
- const int nowave = -1;
if (fxd->flag & FX_SHADOW_USE_WAVE) {
DRW_shgroup_uniform_int(fx_shgrp, "orientation", &fxd->orientation, 1);
}
else {
- DRW_shgroup_uniform_int(fx_shgrp, "orientation", &nowave, 1);
+ DRW_shgroup_uniform_int_copy(fx_shgrp, "orientation", -1);
}
DRW_shgroup_uniform_float(fx_shgrp, "amplitude", &fxd->amplitude, 1);
DRW_shgroup_uniform_float(fx_shgrp, "period", &fxd->period, 1);