显示热力图

point

/**
 * 显示热力图
 * @param data
 */
addHeatMapLayer(data) {
//添加数据源,该热力图效果,数据源类型支持geojson或vector两种形式
    try {
        this.map.addSource("heatmapSource", {
            type: "geojson",
            data
        })
        this.map.addLayer({
            "id": "heatmapLayer",
            "source": "heatmapSource",
            ...MapLayer.getHeatmapLayer()
        })
    } catch (e) {
        console.log(e)
    }
}
上次更新:
贡献者: QiaoJiazhou