diff options
author | Mike Erwin <significant.bit@gmail.com> | 2017-03-27 04:07:58 +0300 |
---|---|---|
committer | Mike Erwin <significant.bit@gmail.com> | 2017-03-27 04:23:54 +0300 |
commit | cc53c180acea384e451af547b1e6aeff3107adde (patch) | |
tree | 38099591df989b57cda8e54729eceb29ee51cb52 /source/blender/gpu/intern/gpu_shader.c | |
parent | a68cc0dc26bf55a9087375f8d104fcccd8571844 (diff) |
GPU_shader automatically uses new matrix values
Whether used from Gawain or from traditional OpenGL draw methods.
TODO: make sure we bind matrices only once per shader change.
Part of T49450
Diffstat (limited to 'source/blender/gpu/intern/gpu_shader.c')
-rw-r--r-- | source/blender/gpu/intern/gpu_shader.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/gpu/intern/gpu_shader.c b/source/blender/gpu/intern/gpu_shader.c index d2d8011829b..711a6a180a3 100644 --- a/source/blender/gpu/intern/gpu_shader.c +++ b/source/blender/gpu/intern/gpu_shader.c @@ -39,6 +39,7 @@ #include "GPU_shader.h" #include "GPU_uniformbuffer.h" #include "GPU_texture.h" +#include "GPU_matrix.h" #include "gpu_shader_private.h" @@ -505,6 +506,7 @@ void GPU_shader_bind(GPUShader *shader) BLI_assert(shader && shader->program); glUseProgram(shader->program); + gpuBindMatrices(shader->program); } void GPU_shader_unbind(void) |