首页 / 浏览问题 / 三维GIS / 问题详情
泛光尾迹线坐标多了不动
35EXP 2021年04月28日
您好,我想问下我的泛光尾迹线加在项目里面线动一下就不动了该怎么解决

1个回答

您好,您那边是不是给线设置了贴地或贴对象,如果是的话取消该设置
6,077EXP 2021年04月28日
没有设置呀  viewer.entities.add({
    polyline: {
        positions: Cesium.Cartesian3.fromDegreesArrayHeights(lonLatArr),
        width: 0.5, // 线的宽度,像素为单位
        material: materialColor
    },
    name: "watchLine",
  });
  viewer.entities.add({
    polyline: {
        positions: Cesium.Cartesian3.fromDegreesArrayHeights(lonLatArr),
        width: 4, // 线的宽度,像素为单位
        material: new Cesium.PolylineTrailMaterialProperty({ // 尾迹线材质
            color: arryColor,   //尾迹线颜色
            trailLength: 0.2,   //尾迹线长度
            period: 5.0          //终点到起点的运行周期
        })
    },
    name: "watchLine",
  });

我就是这样加的
有没有用什么前端框架,把尾迹线这个功能单独提出来到官网示例去看是否正常
前端用的vue 会有什么影响吗

使用vue的话建议 Cesium下的所有对象都不要 放入到 store、data、computed 中,避免被vue劫持,导致帧率严重下降甚至卡住

好的 谢谢
...