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:
authormattoverby <mattoverby@gmail.com>2020-08-28 23:00:01 +0300
committermattoverby <mattoverby@gmail.com>2020-08-28 23:00:01 +0300
commit44819c69a4e702b224c4ba166def9e212bee6d92 (patch)
tree45f0349bd9ad29892d14b0f63d496b309cd32ed8 /source/blender/gpu/opengl/gl_batch.hh
parent6c32148cd2ea90cde4d4e46beb5ad4969b044c49 (diff)
parent019cd2e56b377a35b1fa2c85aebe60fb8c495335 (diff)
fixed submodulessoc-2020-soft-body
Diffstat (limited to 'source/blender/gpu/opengl/gl_batch.hh')
-rw-r--r--source/blender/gpu/opengl/gl_batch.hh19
1 files changed, 10 insertions, 9 deletions
diff --git a/source/blender/gpu/opengl/gl_batch.hh b/source/blender/gpu/opengl/gl_batch.hh
index d70f43aed2a..9399148c68d 100644
--- a/source/blender/gpu/opengl/gl_batch.hh
+++ b/source/blender/gpu/opengl/gl_batch.hh
@@ -32,11 +32,12 @@
#include "glew-mx.h"
-#include "GPU_shader_interface.h"
-
namespace blender {
namespace gpu {
+class GLContext;
+class GLShaderInterface;
+
#define GPU_VAO_STATIC_LEN 3
/* Vao management: remembers all geometry state (vertex attribute bindings & element buffer)
@@ -45,9 +46,9 @@ namespace gpu {
class GLVaoCache {
private:
/** Context for which the vao_cache_ was generated. */
- struct GLContext *context_ = NULL;
+ GLContext *context_ = NULL;
/** Last interface this batch was drawn with. */
- GPUShaderInterface *interface_ = NULL;
+ GLShaderInterface *interface_ = NULL;
/** Cached vao for the last interface. */
GLuint vao_id_ = 0;
/** Used whend arb_base_instance is not supported. */
@@ -58,13 +59,13 @@ class GLVaoCache {
union {
/** Static handle count */
struct {
- const GPUShaderInterface *interfaces[GPU_VAO_STATIC_LEN];
+ const GLShaderInterface *interfaces[GPU_VAO_STATIC_LEN];
GLuint vao_ids[GPU_VAO_STATIC_LEN];
} static_vaos;
/** Dynamic handle count */
struct {
uint count;
- const GPUShaderInterface **interfaces;
+ const GLShaderInterface **interfaces;
GLuint *vao_ids;
} dynamic_vaos;
};
@@ -76,9 +77,9 @@ class GLVaoCache {
GLuint vao_get(GPUBatch *batch);
GLuint base_instance_vao_get(GPUBatch *batch, int i_first);
- GLuint lookup(const GPUShaderInterface *interface);
- void insert(const GPUShaderInterface *interface, GLuint vao_id);
- void remove(const GPUShaderInterface *interface);
+ GLuint lookup(const GLShaderInterface *interface);
+ void insert(const GLShaderInterface *interface, GLuint vao_id);
+ void remove(const GLShaderInterface *interface);
void clear(void);
private: