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:
authorJeroen Bakker <jeroen@blender.org>2021-07-09 10:00:13 +0300
committerJeroen Bakker <jeroen@blender.org>2021-07-09 10:00:13 +0300
commitdbcdc536b6a20c7218c3b6f4871d8c29e5127366 (patch)
tree1f551ed67c40e344dd1d5c5af79472686098914a /source/blender/gpu
parent93092876871adf96338ac3b7a1312cc984b84c8a (diff)
Fix crash: incorrect uniform location for builtins.
Diffstat (limited to 'source/blender/gpu')
-rw-r--r--source/blender/gpu/opengl/gl_shader_interface.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/gpu/opengl/gl_shader_interface.cc b/source/blender/gpu/opengl/gl_shader_interface.cc
index d9291cd642a..c5c8e2397d1 100644
--- a/source/blender/gpu/opengl/gl_shader_interface.cc
+++ b/source/blender/gpu/opengl/gl_shader_interface.cc
@@ -334,7 +334,7 @@ GLShaderInterface::GLShaderInterface(const UniformBuiltinStructType *type_info,
for (int32_t u_int = 0; u_int < GPU_NUM_UNIFORMS; u_int++) {
GPUUniformBuiltin u = static_cast<GPUUniformBuiltin>(u_int);
const ShaderInput *block = this->uniform_get(builtin_uniform_name(u));
- builtins_[u] = (block != nullptr) ? block->binding : -1;
+ builtins_[u] = (block != nullptr) ? block->location : -1;
}
/* Builtin Uniforms Blocks */