[core] move VertexBuffer<> to gfx namespace

This commit is contained in:
Konstantin Käfer
2019-03-05 18:36:41 +01:00
parent 4737a45383
commit 3a57aa65d7
23 changed files with 100 additions and 68 deletions

View File

@@ -1,5 +1,6 @@
#include <mbgl/gl/value.hpp>
#include <mbgl/gl/context.hpp>
#include <mbgl/gl/vertex_buffer.hpp>
#include <mbgl/gl/vertex_array_extension.hpp>
#include <mbgl/gl/enum.hpp>
@@ -485,7 +486,7 @@ GLint components(const gfx::AttributeDataType type) {
void VertexAttribute::Set(const optional<AttributeBinding>& binding, Context& context, AttributeLocation location) {
if (binding) {
context.vertexBuffer = binding->vertexBuffer;
context.vertexBuffer = reinterpret_cast<const gl::VertexBufferResource&>(*binding->vertexBufferResource).buffer;
MBGL_CHECK_ERROR(glEnableVertexAttribArray(location));
MBGL_CHECK_ERROR(glVertexAttribPointer(
location,