使用产品:iClient Classic 9d 9.0.1 操作系统:win10 x64 浏览器:Google浏览器
数据类型: wmts(https://tiles.openaerialmap.org/5a28639331eff4000c380690/0/5b1b6fb2-5024-4681-a175-9b667174f48c/wmts)
问题详细描述:加载wmts失败。希望能显示出“https://map.openaerialmap.org/#/-175.34457564353943,-21.096752491518497,16/square/20002233030/5a28640ebac48e5b1c58a81d?_k=rf265h”页面里的影像地图,但使用wmts无法加载。
问题重现步骤: HTML代码:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title>WMTS图层</title>
</head>
<body style=" margin: 0;overflow: hidden;background: #fff;width: 100%;height:100%;position: absolute;top: 0;">
<div id="map" style="margin:0 auto;width: 100%;height: 100%"></div>
<script type="text/javascript" exclude="iclient-classic" src="js/include-classic.js"></script>
<script type="text/javascript">
var map, layer,
host = "https://tiles.openaerialmap.org";
url = host + "/5a28639331eff4000c380690/0/5b1b6fb2-5024-4681-a175-9b667174f48c/wmts";
map = new SuperMap.Map("map", {
controls: [
new SuperMap.Control.ScaleLine(),
new SuperMap.Control.Zoom(),
new SuperMap.Control.Navigation({
dragPanOptions: {
enableKinetic: true
}
})]
});
//wmts或许所需要的matrixID信息
var matrixIds = [];
for (var i = 0; i < 2; ++i) {
matrixIds[i] = {identifier: 11 + i};
}
//当前图层的分辨率数组信息,和matrixIds一样,需要用户从wmts服务获取并明确设置,resolutions数组和matrixIds数组长度相同
var resolutions = [1/136494.693367, 1/68247.3466833];
//新建图层
layer = new SuperMap.Layer.WMTS({
name: "World",
url: url,
layer: "World",
style: "default",
matrixSet: "Kolovai UAV4R Subset",
format: "image/png",
resolutions: resolutions,
matrixIds: matrixIds,
opacity: 1,
requestEncoding: "KVP"
});
//图层添加并显示指定级别
map.addLayers([layer]);
map.setCenter(new SuperMap.LonLat(-175.349072071, -21.1049318752), 1);
</script>
</body>
</html>