summaryrefslogtreecommitdiff
path: root/src/mbgl/text/glyph_atlas.cpp
diff options
context:
space:
mode:
authorKonstantin Käfer <mail@kkaefer.com>2016-09-29 15:32:48 +0200
committerJohn Firebaugh <john.firebaugh@gmail.com>2016-09-29 10:17:47 -0700
commitcc78b74098e02311cc646fe5b82c13641ff705fa (patch)
treeaf0219d5611f0984bf3b244a336fbc6074a44cb4 /src/mbgl/text/glyph_atlas.cpp
parent15aece8a30dcc1f1f97e28180edda46d05641a2d (diff)
downloadqtlocation-mapboxgl-cc78b74098e02311cc646fe5b82c13641ff705fa.tar.gz
[core] remove dependence on gl.h types
Diffstat (limited to 'src/mbgl/text/glyph_atlas.cpp')
-rw-r--r--src/mbgl/text/glyph_atlas.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mbgl/text/glyph_atlas.cpp b/src/mbgl/text/glyph_atlas.cpp
index b5b62062f3..2f8c44db59 100644
--- a/src/mbgl/text/glyph_atlas.cpp
+++ b/src/mbgl/text/glyph_atlas.cpp
@@ -203,7 +203,7 @@ void GlyphAtlas::removeGlyphs(uintptr_t tileUID) {
}
}
-void GlyphAtlas::upload(gl::Context& context, uint32_t unit) {
+void GlyphAtlas::upload(gl::Context& context, gl::TextureUnit unit) {
if (dirty) {
const bool first = !texture;
bind(context, unit);
@@ -241,12 +241,12 @@ void GlyphAtlas::upload(gl::Context& context, uint32_t unit) {
}
}
-void GlyphAtlas::bind(gl::Context& context, uint32_t unit) {
+void GlyphAtlas::bind(gl::Context& context, gl::TextureUnit unit) {
if (!texture) {
texture = context.createTexture();
context.activeTexture = unit;
context.texture[unit] = *texture;
-#ifndef GL_ES_VERSION_2_0
+#if not MBGL_USE_GLES2
MBGL_CHECK_ERROR(glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAX_LEVEL, 0));
#endif
MBGL_CHECK_ERROR(glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR));