Keep track of used labels

This commit is contained in:
ahocevar
2019-01-22 21:00:21 +01:00
parent ea45068335
commit 592b6cf362
11 changed files with 150 additions and 37 deletions
@@ -248,6 +248,12 @@ class CanvasVectorTileLayerRenderer extends CanvasTileLayerRenderer {
const sourceTiles = tile.load();
const layerUid = getUid(layer);
const executorGroups = tile.executorGroups[layerUid];
if (executorGroups) {
for (let i = 0, ii = executorGroups.length; i < ii; ++i) {
executorGroups[i].dispose();
}
}
tile.executorGroups[layerUid] = [];
for (let t = 0, tt = sourceTiles.length; t < tt; ++t) {
const sourceTile = sourceTiles[t];