summaryrefslogtreecommitdiff
path: root/src/mbgl/gl/context.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mbgl/gl/context.hpp')
-rw-r--r--src/mbgl/gl/context.hpp17
1 files changed, 6 insertions, 11 deletions
diff --git a/src/mbgl/gl/context.hpp b/src/mbgl/gl/context.hpp
index aa8d2c4c84..41e5b5f22d 100644
--- a/src/mbgl/gl/context.hpp
+++ b/src/mbgl/gl/context.hpp
@@ -8,6 +8,7 @@
#include <mbgl/gl/framebuffer.hpp>
#include <mbgl/gl/vertex_array.hpp>
#include <mbgl/gl/types.hpp>
+#include <mbgl/gfx/texture.hpp>
#include <mbgl/gfx/draw_mode.hpp>
#include <mbgl/gfx/depth_mode.hpp>
#include <mbgl/gfx/stencil_mode.hpp>
@@ -42,6 +43,8 @@ public:
Context(const Context&) = delete;
Context& operator=(const Context& other) = delete;
+ std::unique_ptr<gfx::CommandEncoder> createCommandEncoder() override;
+
void initializeExtensions(const std::function<gl::ProcAddress(const char*)>&);
void enableDebugging();
@@ -189,15 +192,6 @@ private:
State<value::PointSize> pointSize;
#endif // MBGL_USE_GLES2
- std::unique_ptr<gfx::VertexBufferResource> createVertexBufferResource(const void* data, std::size_t size, const gfx::BufferUsageType) override;
- void updateVertexBufferResource(gfx::VertexBufferResource&, const void* data, std::size_t size) override;
- std::unique_ptr<gfx::IndexBufferResource> createIndexBufferResource(const void* data, std::size_t size, const gfx::BufferUsageType) override;
- void updateIndexBufferResource(gfx::IndexBufferResource&, const void* data, std::size_t size) override;
-
- std::unique_ptr<gfx::TextureResource> createTextureResource(Size, const void* data, gfx::TexturePixelType, gfx::TextureChannelDataType) override;
- void updateTextureResource(gfx::TextureResource&, Size, const void* data, gfx::TexturePixelType, gfx::TextureChannelDataType) override;
- void updateTextureResourceSub(gfx::TextureResource&, const uint16_t xOffset, const uint16_t yOffset, Size, const void* data, gfx::TexturePixelType, gfx::TextureChannelDataType) override;
-
std::unique_ptr<gfx::OffscreenTexture> createOffscreenTexture(
Size, gfx::TextureChannelDataType = gfx::TextureChannelDataType::UnsignedByte) override;
std::unique_ptr<gfx::OffscreenTexture> createOffscreenTexture(
@@ -205,6 +199,9 @@ private:
gfx::Renderbuffer<gfx::RenderbufferPixelType::Depth>&,
gfx::TextureChannelDataType = gfx::TextureChannelDataType::UnsignedByte) override;
+ std::unique_ptr<gfx::TextureResource>
+ createTextureResource(Size, gfx::TexturePixelType, gfx::TextureChannelDataType) override;
+
std::unique_ptr<gfx::RenderbufferResource> createRenderbufferResource(gfx::RenderbufferPixelType, Size size) override;
std::unique_ptr<gfx::DrawScopeResource> createDrawScopeResource() override;
@@ -218,8 +215,6 @@ private:
VertexArray createVertexArray();
bool supportsVertexArrays() const;
- std::unique_ptr<gfx::CommandEncoder> createCommandEncoder() override;
-
friend detail::ProgramDeleter;
friend detail::ShaderDeleter;
friend detail::BufferDeleter;