From 16e7bd521012c52de10384a4a15b8b3889228d4b Mon Sep 17 00:00:00 2001 From: elias couppe Date: Thu, 4 Apr 2024 12:15:01 +0200 Subject: [PATCH] fix(2D:VectorTiles): Tile Grid en 512px --- DRAFT_CHANGELOG.md | 2 ++ src/OpenLayers/OlMapVectorTile.js | 24 ++++++++++++------------ 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/DRAFT_CHANGELOG.md b/DRAFT_CHANGELOG.md index 289f17611..a8f9d991e 100644 --- a/DRAFT_CHANGELOG.md +++ b/DRAFT_CHANGELOG.md @@ -16,6 +16,8 @@ * [Fixed] + - corrige tileGrid Vector Tile (512px) + * [Deprecated] * [Security] diff --git a/src/OpenLayers/OlMapVectorTile.js b/src/OpenLayers/OlMapVectorTile.js index 4892acfee..351f9ec69 100644 --- a/src/OpenLayers/OlMapVectorTile.js +++ b/src/OpenLayers/OlMapVectorTile.js @@ -1221,12 +1221,12 @@ OlMap.prototype._addMapBoxLayer = function (layerObj) { // overlaps // projection format : vectorFormat, - tileGrid : olCreateXYZTileGrid({ // TODO scheme tms ? - extent : _glSource.bounds, // [minx, miny, maxx, maxy] - maxZoom : _glSource.maxzoom || 22, - minZoom : _glSource.minzoom || 1, - tileSize : _glSource.tileSize || 256 - }), + // tileGrid : olCreateXYZTileGrid({ // TODO scheme tms ? + // extent : _glSource.bounds, // [minx, miny, maxx, maxy] + // maxZoom : _glSource.maxzoom || 22, + // minZoom : _glSource.minzoom || 1, + // tileSize : _glSource.tileSize || 256 + // }), urls : _glTiles }); vectorSource._title = _title; @@ -1311,12 +1311,12 @@ OlMap.prototype._addMapBoxLayer = function (layerObj) { // INFO // on supprime la grille pour forcer l'utilisation par defaut des tuiles en 512 // sur du vecteur tuilé - tileGrid : olCreateXYZTileGrid({ // TODO scheme tms ? - extent : _glSource.bounds, // [minx, miny, maxx, maxy] - maxZoom : _glSource.maxzoom || 22, - minZoom : _glSource.minzoom || 1, - tileSize : _glSource.tileSize || 256 - }), + // tileGrid : olCreateXYZTileGrid({ // TODO scheme tms ? + // extent : _glSource.bounds, // [minx, miny, maxx, maxy] + // maxZoom : _glSource.maxzoom || 22, + // minZoom : _glSource.minzoom || 1, + // tileSize : _glSource.tileSize || 256 + // }), urls : tiles }); vectorSource._title = _title;