Commit 159d6d16 by wanghao

同步v3.4.9代码

parent fd5c83de
......@@ -708,7 +708,7 @@
"name": "三维地名服务",
"thumbnail": "layerg-other-tdtDm.jpg",
"main": "layer-graphic/other/tdtDm",
"libs": ["mars3d", "mars3d-tdt"]
"libs": ["mars3d", "mars3d-tdt"]
},
{
"name": "矢量瓦片方式加载GeoJson",
......
/**
* Mars3D三维可视化平台 mars3d
*
* 版本信息:v3.4.8
* 编译日期:2022-09-26 09:04:57
* 版本信息:v3.4.9
* 编译日期:2022-10-09 09:17:47
* 版权所有:Copyright by 火星科技 http://mars3d.cn
* 使用单位:免费公开版 ,2022-06-01
*/
......
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -2,6 +2,7 @@ import * as mars3d from "mars3d"
export let map // mars3d.Map三维地图对象
export let graphicLayer
export const eventTarget = new mars3d.BaseClass() // 事件对象,用于抛出事件到面板中
// 需要覆盖config.json中地图属性参数(当前示例框架中自动处理合并)
export const mapOptions = {
......@@ -99,6 +100,8 @@ export function addDemoGraphic1() {
instances: arrData
})
graphicLayer.addGraphic(flatBillboard)
eventTarget.fire("addTableData", { graphicLayer })
})
.catch(function (error) {
console.log("加载JSON出错", error)
......
......@@ -2,6 +2,7 @@ import * as mars3d from "mars3d"
export let map // mars3d.Map三维地图对象
export let graphicLayer // 矢量图层对象
export const eventTarget = new mars3d.BaseClass() // 事件对象,用于抛出事件到面板中
// 需要覆盖config.json中地图属性参数(当前示例框架中自动处理合并)
export const mapOptions = {
......@@ -111,6 +112,7 @@ function addDemoGraphic1(graphicLayer) {
})
graphicLayer.addGraphic(graphic)
}
eventTarget.fire("addTableData", { graphicLayer })
})
.catch(function (error) {
console.log("加载JSON出错", error)
......
......@@ -24,7 +24,6 @@ export const mapOptions = {
export function onMounted(mapInstance) {
map = mapInstance // 记录map
globalNotify("已知问题提示", `(1) SatelliteSensor性能比较差,后期会尝试优化,非投射需求时建议用conicSensor或rectSensor`)
// 创建矢量数据图层
......@@ -84,6 +83,7 @@ export function addDemoGraphic1(sensorParams) {
reverse: reverse
})
graphicLayer.addGraphic(satelliteSensor)
eventTarget.fire("addTableData", { graphicLayer })
}
// 生成演示数据(测试数据量)
......
......@@ -64,8 +64,8 @@ export function onUnmounted() {
}
// 查看场景出图
export function showMapImg() {
return map.expImage({ download: false }).then((result) => {
export function showMapImg(options = {}) {
return map.expImage({ download: false, ...options }).then((result) => {
return result.image
})
}
......@@ -79,6 +79,7 @@ export function downLoad() {
export function downLoad2() {
map.expImage({
height: 300, // 指定 高度 或 宽度(指定1种就行,对应的自动缩放)
// width: 300, //同时指定后去裁剪中间部分
download: true
})
}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论