首页 / 浏览问题 / 三维GIS / 问题详情

1个回答

您好,地质体裁剪与开挖使用的地址为数据服务地址,您加载的服务为三维服务,数据服务需要工作空间中有数据集,然后使用该工作空间发数据服务后参考"http://www.supermapol.com/realspace/services/data-dizhiti/rest/data/datasources/%E5%9C%B0%E8%B4%A8%E4%BD%93/datasets/Layer6/features/1.stream"路径进行加载即可

1,225EXP 2022年02月17日
var modelUrls = [
        'http://192.168.0.159:8090/iserver/services/data-220210/rest/data/datasources/dizhiti0112/datasets/GeoBodyResult/features/1-6-0.stream',
        'http://192.168.0.159:8090/iserver/services/data-220210/rest/data/datasources/dizhiti0112/datasets/GeoBodyResult/features/1-6-1.stream',
        'http://192.168.0.159:8090/iserver/services/data-220210/rest/data/datasources/dizhiti0112/datasets/GeoBodyResult/features/1-6-2.stream',
        'http://192.168.0.159:8090/iserver/services/data-220210/rest/data/datasources/dizhiti0112/datasets/GeoBodyResult/features/1-6-3.stream',
        'http://192.168.0.159:8090/iserver/services/data-220210/rest/data/datasources/dizhiti0112/datasets/GeoBodyResult/features/1-6-4.stream',
        'http://192.168.0.159:8090/iserver/services/data-220210/rest/data/datasources/dizhiti0112/datasets/GeoBodyResult/features/1-6-5.stream',
      ];

你帮忙看一下 这样写对吗 那还需要我加载三维服务吗

这样写是可以的,是否加载三维服务需要看您本身的需求,单独的剖切不需要加载三维服务
solidModelsProfile.addedEvent.addEventListener(param => {
        viewer.camera.flyTo(
            {
              destination: new Cesium.Cartesian3.fromDegrees(115.01865862015738, 39.01237767989015, 60000)
              //destination: new Cesium.Cartesian3.fromDegrees(param.modelPosition[0].position.x, param.modelPosition[0].position.y, 60000)
            })
      })

我这Cannot read properties of undefined (reading 'addEventListener') 这是为什么报错

按我上面写的url会报400

...