diff options
author | Mikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com> | 2019-05-13 11:25:29 +0300 |
---|---|---|
committer | Mikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com> | 2019-05-14 11:19:56 +0300 |
commit | 81823e35a68eb87d9433457fe9983d06793a77bf (patch) | |
tree | 8fd4fa93dd552d837b9014fda5a56bd1a0162ef8 /src/mbgl/text/cross_tile_symbol_index.cpp | |
parent | cd24f4c45f6b38e7f3dc73cf0afda9b86b3d85d4 (diff) | |
download | qtlocation-mapboxgl-81823e35a68eb87d9433457fe9983d06793a77bf.tar.gz |
[core] RenderTile shall never be created for a not renderable tile
A RenderTile is already never created for a not renderable tile, guarantied by the checks in `updateRenderables()`.
However, the client code had plenty of `isRenderable()` checks in the render path, which complicated the code and affected rendering performance.
This patch removes the unneeded checks from the client code and puts an assertion to `TilePyramid::addRenderTile()`.
Diffstat (limited to 'src/mbgl/text/cross_tile_symbol_index.cpp')
-rw-r--r-- | src/mbgl/text/cross_tile_symbol_index.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/mbgl/text/cross_tile_symbol_index.cpp b/src/mbgl/text/cross_tile_symbol_index.cpp index 5170bfad75..3af583ebd3 100644 --- a/src/mbgl/text/cross_tile_symbol_index.cpp +++ b/src/mbgl/text/cross_tile_symbol_index.cpp @@ -174,9 +174,7 @@ bool CrossTileSymbolIndex::addLayer(const RenderLayerSymbolInterface& symbolInte layerIndex.handleWrapJump(lng); for (const RenderTile& renderTile : symbolInterface.getRenderTiles()) { - if (!renderTile.tile.isRenderable()) { - continue; - } + assert(renderTile.tile.isRenderable()); auto bucket = symbolInterface.getSymbolBucket(renderTile); if (!bucket) { |