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>2020-09-02 01:27:41 +0300
committerClément Foucault <foucault.clem@gmail.com>2020-09-05 18:49:14 +0300
commitf72c1c4547e5fab769c22652d9872192029ad7fe (patch)
tree4b89ee42810e0505ed386b76bf5f76f5d4107a1c /source/blender/gpu/GPU_batch.h
parentc598e939ad25dfc3b4eb1c92b16de401bde0d88a (diff)
GPUTexture: Remove bind to edit calls
This is going to be unecessary after the GPU opengl texture backend refactor. For now add a save/restore mechanism to leave the state untouched. Also remove some calls where the caller would bind to particular binding point and set the shader uniform.
Diffstat (limited to 'source/blender/gpu/GPU_batch.h')
-rw-r--r--source/blender/gpu/GPU_batch.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/gpu/GPU_batch.h b/source/blender/gpu/GPU_batch.h
index e00aac85655..f26f706d058 100644
--- a/source/blender/gpu/GPU_batch.h
+++ b/source/blender/gpu/GPU_batch.h
@@ -146,6 +146,8 @@ void GPU_batch_program_set_builtin_with_config(GPUBatch *batch,
GPU_shader_uniform_4fv_array((batch)->shader, name, len, val);
#define GPU_batch_uniform_mat4(batch, name, val) \
GPU_shader_uniform_mat4((batch)->shader, name, val);
+#define GPU_batch_texture_bind(batch, name, tex) \
+ GPU_texture_bind(tex, GPU_shader_get_texture_binding((batch)->shader, name));
void GPU_batch_draw(GPUBatch *batch);
void GPU_batch_draw_range(GPUBatch *batch, int v_first, int v_count);