Skip to content

Commit

Permalink
Only render vector tile when there are executor groups
Browse files Browse the repository at this point in the history
  • Loading branch information
ahocevar committed Apr 29, 2020
1 parent 0549951 commit fe10577
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/ol/renderer/canvas/VectorTileLayer.js
Original file line number Diff line number Diff line change
Expand Up @@ -608,6 +608,10 @@ class CanvasVectorTileLayerRenderer extends CanvasTileLayerRenderer {
const tile = /** @type {import("../../VectorRenderTile.js").default} */ (tiles[
i
]);
const executorGroups = tile.executorGroups[getUid(layer)];
if (!executorGroups) {
continue;
}
const tileCoord = tile.tileCoord;
const tileExtent = tileGrid.getTileCoordExtent(tile.wrappedTileCoord);
const worldOffset =
Expand All @@ -629,7 +633,6 @@ class CanvasVectorTileLayerRenderer extends CanvasTileLayerRenderer {
worldOffset
)
);
const executorGroups = tile.executorGroups[getUid(layer)];
let clipped = false;
for (let t = 0, tt = executorGroups.length; t < tt; ++t) {
const executorGroup = executorGroups[t];
Expand Down

0 comments on commit fe10577

Please sign in to comment.