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:
authorClément Foucault <foucault.clem@gmail.com>2019-05-11 15:42:26 +0300
committerClément Foucault <foucault.clem@gmail.com>2019-05-14 11:57:03 +0300
commitad0e95688d254abee315622ebdc3aeb0d2ba979d (patch)
treefe08a1fdd16b3bdd4e9e645b4a8f3e39a5856066 /source/blender/draw/intern/draw_manager_exec.c
parent2d28df783a029ee5b64da005b2fa400e4e8de976 (diff)
Cleanup: DRW: Remove pointers to materials
Diffstat (limited to 'source/blender/draw/intern/draw_manager_exec.c')
-rw-r--r--source/blender/draw/intern/draw_manager_exec.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/source/blender/draw/intern/draw_manager_exec.c b/source/blender/draw/intern/draw_manager_exec.c
index efea155d35d..a1532243381 100644
--- a/source/blender/draw/intern/draw_manager_exec.c
+++ b/source/blender/draw/intern/draw_manager_exec.c
@@ -818,12 +818,12 @@ static void draw_geometry_prepare(DRWShadingGroup *shgroup, DRWCall *call)
(float *)state->modelviewprojection);
}
if (shgroup->objectinfo != -1) {
- float objectinfo[4];
- objectinfo[0] = state->objectinfo[0];
- objectinfo[1] = call->single.ma_index; /* WATCH this is only valid for single drawcalls. */
- objectinfo[2] = state->objectinfo[1];
- objectinfo[3] = (state->flag & DRW_CALL_NEGSCALE) ? -1.0f : 1.0f;
- GPU_shader_uniform_vector(shgroup->shader, shgroup->objectinfo, 4, 1, (float *)objectinfo);
+ float infos[4];
+ infos[0] = state->ob_index;
+ // infos[1]; /* UNUSED. */
+ infos[2] = state->ob_random;
+ infos[3] = (state->flag & DRW_CALL_NEGSCALE) ? -1.0f : 1.0f;
+ GPU_shader_uniform_vector(shgroup->shader, shgroup->objectinfo, 4, 1, (float *)infos);
}
if (shgroup->orcotexfac != -1) {
GPU_shader_uniform_vector(