首页 / 浏览问题 / WebGIS / 问题详情
vue+leaflet 大地2000坐标系 初始化、放大,部分瓦片不显示
13EXP 2023年04月17日

使用产品:iserver 10.2.1

操作系统:win11 x64

数据类型: 文件型

问题详细描述:supermap+vue-leaflet加载大地坐标系GCS_China_Geodetic_Coordinate_System_2000地图, 初始化、放大,部分瓦片不显示

代码:

<template>
  <div id="map"></div>
</template>

<script>
import L from 'leaflet'
import { TiledMapLayer } from '@supermap/iclient-leaflet'

export default {
  name: 'AddMap',
  data() {
    return {
      map: {},
      mapUrl: 'http://111.39.31.82:8800/portalproxy/54di5l17/iserver/services/map-ugcv5-NGDT0310/rest/maps/NGDT0310'
    }
  },
  mounted() {
    this.init()
  },
  methods: {
    init() {
      this.map = L.map('map', {
        crs: L.CRS.EPSG4326,
        center: [30.61, 118.98],
        maxZoom: 18,
        zoom: 10
      })
      new TiledMapLayer(this.mapUrl).addTo(this.map)
    }
  }
}
</script>

<style>
#map {
  margin: 0;
  padding: 0;
  overflow: hidden;
  background: #fff;
  width: 100%;
  height: 100%;
  position: absolute;
}
</style>

初始化图片:

顶部放大后:

1个回答

您好,看您服务地址应该是对地图缓存发布的服务,您截图中的未出图部分看上去都是没有数据的,

您是否在iDesktop或iDesktopX切图的时候,勾选了“忽略无效区域瓦片”,如果勾选了的话完全没有数据的区域,在切图时就不会切出瓦片来。

希望可以帮助到您。
9,633EXP 2023年04月17日
...