Classes
Methods
-
module:ol/tilegrid/WMTS.createFromCapabilitiesMatrixSet(matrixSet, opt_extent, opt_matrixLimits){module:ol/tilegrid/WMTS~WMTSTileGrid}
tilegrid/WMTS.js, line 108 -
Create a tile grid from a WMTS capabilities matrix set and an optional TileMatrixSetLimits.
Name Type Description matrixSetObject An object representing a matrixSet in the capabilities document.
extentmodule:ol/extent~Extent An optional extent to restrict the tile ranges the server provides.
matrixLimitsArray.<Object> An optional object representing the available matrices for tileGrid.
Returns:
WMTS tileGrid instance.
Type Definitions
-
Properties:
Name Type Argument Description extentmodule:ol/extent~Extent <optional>
Extent for the tile grid. No tiles outside this extent will be requested by
module:ol/source/Tilesources. When nooriginororiginsare configured, theoriginwill be set to the top-left corner of the extent.originmodule:ol/coordinate~Coordinate <optional>
The tile grid origin, i.e. where the
xandyaxes meet ([z, 0, 0]). Tile coordinates increase left to right and upwards. If not specified,extentororiginsmust be provided.originsArray.<module:ol/coordinate~Coordinate> <optional>
Tile grid origins, i.e. where the
xandyaxes meet ([z, 0, 0]), for each zoom level. If given, the array length should match the length of theresolutionsarray, i.e. each resolution can have a different origin. Tile coordinates increase left to right and upwards. If not specified,extentororiginmust be provided.resolutionsArray.<number> Resolutions. The array index of each resolution needs to match the zoom level. This means that even if a
minZoomis configured, the resolutions array will have a length ofmaxZoom + 1matrixIdsArray.<string> matrix IDs. The length of this array needs to match the length of the
resolutionsarray.sizesArray.<module:ol/size~Size> <optional>
Number of tile rows and columns of the grid for each zoom level. The values here are the
TileMatrixWidthandTileMatrixHeightadvertised in the GetCapabilities response of the WMTS, and define the grid's extent together with theorigin. Anextentcan be configured in addition, and will further limit the extent for which tile requests are made by sources. Note that when the top-left corner of theextentis used asoriginororigins, then theyvalue must be negative because OpenLayers tile coordinates increase upwards.tileSizenumber | module:ol/size~Size <optional>
Tile size.
tileSizesArray.<module:ol/size~Size> <optional>
Tile sizes. The length of this array needs to match the length of the
resolutionsarray.widthsArray.<number> <optional>
Number of tile columns that cover the grid's extent for each zoom level. Only required when used with a source that has
wrapXset totrue, and only when the grid's origin differs from the one of the projection's extent. The array length has to match the length of theresolutionsarray, i.e. each resolution will have a matching entry here.