GPUQuery: GL Backend isolation

This is part of the Vulkan task T68990.

This introduce a new GLQueryPool for managing queries in an
implementation agnostic manner.

This modify the GPU selection query to use this new object.
This also make use of blender::Vector for better code quality.

No real functionnal change.
This commit is contained in:
2020-09-07 23:52:55 +02:00
parent d4fd363d05
commit 5c2ac8520e
10 changed files with 294 additions and 63 deletions

View File

@@ -32,6 +32,7 @@
#include "gl_drawlist.hh"
#include "gl_framebuffer.hh"
#include "gl_index_buffer.hh"
#include "gl_query.hh"
#include "gl_shader.hh"
#include "gl_texture.hh"
#include "gl_uniform_buffer.hh"
@@ -95,6 +96,11 @@ class GLBackend : public GPUBackend {
return new GLIndexBuf();
};
QueryPool *querypool_alloc(void) override
{
return new GLQueryPool();
};
Shader *shader_alloc(const char *name) override
{
return new GLShader(name);