GeoServer地图在GMap中使用
我采用的是ArcGIS_Imagery_World_2D_MapProvider的方式,其中有两点要注意:
1、设置PureProjection为PlateCarreeProjection.Instance
2、构建URl,使用WMTS格式,EPSG:4326。URL如下
static readonly string UrlFormat = "http://localhost:8080/geoserver/gwc/service/wmts?layer=DB:DB&style=&tilematrixset=EPSG:4326&Service=WMTS&Request=GetTile&Version=1.0.0&Format=image%2Fpng&TileMatrix=EPSG:4326:{0}&TileRow={1}&TileCol={2}";
WMTS地址如何构建,参考下图:
1、进入Tile Layers,在select One浏览对应地图
2、F12查找切片地址