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-01-16 06:41:27 +0300
committerClément Foucault <foucault.clem@gmail.com>2019-01-17 21:44:01 +0300
commit4c9589909807f346e23966379f240dd57d057a1d (patch)
tree40bad4807d5b5cdd5e632f00562477bf7bb7754c /source/blender/gpu/GPU_shader.h
parent938b08b33654f6bc3419519fc364021115d19dba (diff)
GPU: Rename GPU_shader_get_uniform to GPU_shader_get_uniform_ensure
This is in order to make the API more multithread friendly inside the draw manager. GPU_shader_get_uniform will only serve to query the shader interface and not do any GL call, making it threadsafe. For now it only print a warning if the uniform was not queried before.
Diffstat (limited to 'source/blender/gpu/GPU_shader.h')
-rw-r--r--source/blender/gpu/GPU_shader.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/source/blender/gpu/GPU_shader.h b/source/blender/gpu/GPU_shader.h
index 4803c6c0792..62e1101a141 100644
--- a/source/blender/gpu/GPU_shader.h
+++ b/source/blender/gpu/GPU_shader.h
@@ -82,6 +82,7 @@ int GPU_shader_get_program(GPUShader *shader);
void *GPU_shader_get_interface(GPUShader *shader);
int GPU_shader_get_uniform(GPUShader *shader, const char *name);
+int GPU_shader_get_uniform_ensure(GPUShader *shader, const char *name);
int GPU_shader_get_builtin_uniform(GPUShader *shader, int builtin);
int GPU_shader_get_uniform_block(GPUShader *shader, const char *name);
void GPU_shader_uniform_vector(