summaryrefslogtreecommitdiff
path: root/src/mbgl/geometry/line_atlas.cpp
diff options
context:
space:
mode:
authorKonstantin Käfer <mail@kkaefer.com>2016-09-27 13:00:27 +0200
committerJohn Firebaugh <john.firebaugh@gmail.com>2016-09-27 11:03:29 -0700
commitce42d22984d19fa020e6fba77e2585c0fd9dacf4 (patch)
tree76e1a33a58bfb023987de1cc7aca59e649624db3 /src/mbgl/geometry/line_atlas.cpp
parent21386b31465302d63cae5d93680442555c8560f1 (diff)
downloadqtlocation-mapboxgl-ce42d22984d19fa020e6fba77e2585c0fd9dacf4.tar.gz
[core] rename gl::Config to gl::Context
Diffstat (limited to 'src/mbgl/geometry/line_atlas.cpp')
-rw-r--r--src/mbgl/geometry/line_atlas.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/mbgl/geometry/line_atlas.cpp b/src/mbgl/geometry/line_atlas.cpp
index bc81c38f53..2f4616f6e6 100644
--- a/src/mbgl/geometry/line_atlas.cpp
+++ b/src/mbgl/geometry/line_atlas.cpp
@@ -1,7 +1,7 @@
#include <mbgl/geometry/line_atlas.hpp>
#include <mbgl/gl/gl.hpp>
#include <mbgl/gl/object_store.hpp>
-#include <mbgl/gl/gl_config.hpp>
+#include <mbgl/gl/context.hpp>
#include <mbgl/platform/log.hpp>
#include <mbgl/platform/platform.hpp>
@@ -121,30 +121,30 @@ LinePatternPos LineAtlas::addDash(const std::vector<float>& dasharray, LinePatte
return position;
}
-void LineAtlas::upload(gl::ObjectStore& store, gl::Config& config, uint32_t unit) {
+void LineAtlas::upload(gl::ObjectStore& store, gl::Context& context, uint32_t unit) {
if (dirty) {
- bind(store, config, unit);
+ bind(store, context, unit);
}
}
-void LineAtlas::bind(gl::ObjectStore& store, gl::Config& config, uint32_t unit) {
+void LineAtlas::bind(gl::ObjectStore& store, gl::Context& context, uint32_t unit) {
bool first = false;
if (!texture) {
texture = store.createTexture();
- config.activeTexture = unit;
- config.texture[unit] = *texture;
+ context.activeTexture = unit;
+ context.texture[unit] = *texture;
MBGL_CHECK_ERROR(glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR));
MBGL_CHECK_ERROR(glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR));
MBGL_CHECK_ERROR(glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT));
MBGL_CHECK_ERROR(glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE));
first = true;
- } else if (config.texture[unit] != *texture) {
- config.activeTexture = unit;
- config.texture[unit] = *texture;
+ } else if (context.texture[unit] != *texture) {
+ context.activeTexture = unit;
+ context.texture[unit] = *texture;
}
if (dirty) {
- config.activeTexture = unit;
+ context.activeTexture = unit;
if (first) {
MBGL_CHECK_ERROR(glTexImage2D(
GL_TEXTURE_2D, // GLenum target