关于javascript:leaflet基于平面坐标系做时序播放功能方案

2次阅读

共计 535 个字符,预计需要花费 2 分钟才能阅读完成。

1. 初始化 map,bounds 和 origin 从 iserver 公布的底图的根底信息获取

this.baseMap = L.map(this.initId, {
    crs: L.CRS.NonEarthCRS({bounds: L.bounds([-45888490.52,-47298112.34], [45888490.52, 45888490.52]),
        origin: L.point(-45888490.52,45888490.52)
    }),
    center: [733210.56 , -1230428.86],
    maxZoom: 18,
    zoomControl:false,
    attributionControl:false,
    zoom: 1,
});

2. 创立一个 layerGroup 对时序图层等业务进行治理
3.collectionId 和 names 需开发人员本人获取本人业务服务的相干

const imageBounds = '须要时序性能产品的 bound'
const imageUrl = '******************'
thit.imageLayer =L.imageOverlay(imageUrl, imageBounds)
that.AniLayerGroup.addLayer(this.imageLayer)
正文完
 0