diff options
author | Bruno de Oliveira Abinader <bruno@mapbox.com> | 2015-11-06 19:52:47 +0200 |
---|---|---|
committer | Bruno de Oliveira Abinader <bruno@mapbox.com> | 2015-11-06 20:05:01 +0200 |
commit | 8894982625e732e62a4a12fabd7928800c7d5ded (patch) | |
tree | 49eb8ff97e15a4328f1582e5d79f37b94c29bbf2 /src/mbgl/renderer/painter_symbol.cpp | |
parent | 162ad67802d8d3eb1106b2c30feae607b4309afc (diff) | |
download | qtlocation-mapboxgl-8894982625e732e62a4a12fabd7928800c7d5ded.tar.gz |
[core] Use GL_TRUE/GL_FALSE instead of true/false
Diffstat (limited to 'src/mbgl/renderer/painter_symbol.cpp')
-rw-r--r-- | src/mbgl/renderer/painter_symbol.cpp | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/src/mbgl/renderer/painter_symbol.cpp b/src/mbgl/renderer/painter_symbol.cpp index 6538911587..2a8e0fdcc3 100644 --- a/src/mbgl/renderer/painter_symbol.cpp +++ b/src/mbgl/renderer/painter_symbol.cpp @@ -144,7 +144,7 @@ void Painter::renderSymbol(SymbolBucket& bucket, const SymbolLayer& layer, const config.depthMask = GL_FALSE; if (bucket.hasCollisionBoxData()) { - config.stencilTest = true; + config.stencilTest = GL_TRUE; config.program = collisionBoxShader->program; collisionBoxShader->u_matrix = matrix; @@ -158,16 +158,20 @@ void Painter::renderSymbol(SymbolBucket& bucket, const SymbolLayer& layer, const } - // TODO remove the `|| true` when #1673 is implemented - const bool drawAcrossEdges = !(layout.text.allow_overlap || layout.icon.allow_overlap || - layout.text.ignore_placement || layout.icon.ignore_placement) || true; + // TODO remove the `true ||` when #1673 is implemented + const bool drawAcrossEdges = true || !(layout.text.allow_overlap || layout.icon.allow_overlap || + layout.text.ignore_placement || layout.icon.ignore_placement); // Disable the stencil test so that labels aren't clipped to tile boundaries. // // Layers with features that may be drawn overlapping aren't clipped. These // layers are sorted in the y direction, and to draw the correct ordering near // tile edges the icons are included in both tiles and clipped when drawing. - config.stencilTest = drawAcrossEdges ? false : true; + if (drawAcrossEdges) { + config.stencilTest = GL_FALSE; + } else { + config.stencilTest = GL_TRUE; + } if (bucket.hasIconData()) { config.depthTest = layout.icon.rotation_alignment == RotationAlignmentType::Map; |