本身的地图效果:
Mars3d的蓝色地图效果:
关键代码:
basemaps: [
{
name: "高德电子",
icon: "img/basemaps/gaode_vec.png",
type: "gaode",
layer: "vec",
show: true,
invertColor: true,
filterColor: "#4e70a6",
brightness: 0.6,
contrast: 1.8,
gamma: 0.3,
hue: 1,
saturation: 0,
credit: creditHtml
}
]
示例链接:
功能示例(Vue版) | Mars3D三维可视化平台 | 火星科技
创建地球后直接New一个GaodeLayer也可以,实现以下效果:
// 叠加的图层
let tileLayer
export function addTileLayer() {
removeTileLayer()
// 方式2:在创建地球后调用addLayer添加图层(直接new对应type类型的图层类)
tileLayer = new mars3d.layer.GaodeLayer({
name: "高德电子",
icon: "img/basemaps/gaode_vec.png",
type: "gaode",
layer: "vec",
show: true,
invertColor: true,
filterColor: "#4e70a6",
brightness: 0.6,
contrast: 1.8,
gamma: 0.3,
hue: 1,
saturation: 0,
})
map.addLayer(tileLayer)
}
实现的效果: