WMTS 地图切片Web服务 协议数据解析

1. WMTS 描述

WMTS(Web Map Tiles Service):地图切片Web服务。

2. 数据示例:

arcgis online 导出的wmts xml:

https://sampleserver6.arcgisonline.com/arcgis/rest/services/WorldTimeZones/MapServer/WMTS

内容解析:

  1. contents中可能包含多个layer, 每个layer对应一个请求地址,首先找到source_url
  1. Find the

Style value which is "default". In the URL, replace {Style} with default or the corresponding value in your XML file.

  1. Find the

TileMatrixSet value which is "default028mm". In the URL, replace {TileMatrixSet} with default028mm or the corresponding value in your XML file.

  1. Update the template and set {TileMatrix}/{TileRow}/{TileCol} to {z}/{y}/{x} and add the image file extension (.png) to the end of the URL.
javascript 复制代码
https://maps.vcgi.vermont.gov/arcgis/rest/services/EGC_services/IMG_VCGI_LIDARHILLSHD_WM_CACHE_v1/ImageServer/WMTS/tile/1.0.0/EGC_services_IMG_VCGI_LIDARHILLSHD_WM_CACHE_v1/default/default028mm/{z}/{x}/{y}.png
  1. 获取tileSize

  2. 之后则可以在mapbox中加载此raster 图层进行展示

相关推荐
梨子同志10 分钟前
Monorepo
前端
lihaozecq12 分钟前
继 Web Coding Agent 后,我做了一个本地优先的桌面 AI Agent
前端·agent
用户2986985301418 分钟前
在 React 中使用 JavaScript 将 Excel 转换为 SVG
前端·javascript·react.js
CodingSpace31 分钟前
ESLint
前端
Csvn39 分钟前
异步错误捕获的六大陷阱:await 裹着 try-catch 就一定稳了吗?
前端
用户0595401744642 分钟前
向量库静默丢数据踩坑实录:Playwright 端到端测试让我排查了72小时
前端·css
星栈1 小时前
SPA 写累了?试试 LiveView:服务端管状态,前端不写 JS
前端·前端框架·elixir
labixiong1 小时前
手写Promise--微任务、静态方法、async/await 全搞懂(三)
前端·javascript
Asize1 小时前
CSS 3D:从布局到立方体
前端
梨子同志1 小时前
React
前端