From 220fbdf59341f620c06959280e2145132003c5df Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Foucault?= Date: Fri, 21 Aug 2020 13:48:34 +0200 Subject: GPUShader: Make GPUShader* an opaque pointer to blender::gpu::Shader This avoids the misleading inheritance. Also cleanup by setting the blender::gpu::Shader as active shader to avoid some casting. --- source/blender/gpu/intern/gpu_context_private.hh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'source/blender/gpu/intern/gpu_context_private.hh') diff --git a/source/blender/gpu/intern/gpu_context_private.hh b/source/blender/gpu/intern/gpu_context_private.hh index b774d6b0995..e8c9c976e9a 100644 --- a/source/blender/gpu/intern/gpu_context_private.hh +++ b/source/blender/gpu/intern/gpu_context_private.hh @@ -29,6 +29,7 @@ #include "GPU_context.h" +#include "gpu_shader_private.hh" #include "gpu_state_private.hh" #include @@ -43,7 +44,7 @@ struct GPUMatrixState; struct GPUContext { public: /** State managment */ - GPUShader *shader = NULL; + blender::gpu::Shader *shader = NULL; GPUFrameBuffer *current_fbo = NULL; GPUMatrixState *matrix_state = NULL; blender::gpu::GPUStateManager *state_manager = NULL; -- cgit v1.2.3