我的代码跟示例不同的是这
promise = scene.open("http://192.168.0.159:8090/iserver/services/3D-220210/rest/realspace");
我直接加载的
示例代码是这样的
var modelUrls = [ "http://www.supermapol.com/realspace/services/data-dizhiti/rest/data/datasources/%E5%9C%B0%E8%B4%A8%E4%BD%93/datasets/Layer1/features/1.stream", "http://www.supermapol.com/realspace/services/data-dizhiti/rest/data/datasources/%E5%9C%B0%E8%B4%A8%E4%BD%93/datasets/Layer2/features/1.stream", "http://www.supermapol.com/realspace/services/data-dizhiti/rest/data/datasources/%E5%9C%B0%E8%B4%A8%E4%BD%93/datasets/Layer3/features/1.stream", "http://www.supermapol.com/realspace/services/data-dizhiti/rest/data/datasources/%E5%9C%B0%E8%B4%A8%E4%BD%93/datasets/Layer4/features/1.stream", "http://www.supermapol.com/realspace/services/data-dizhiti/rest/data/datasources/%E5%9C%B0%E8%B4%A8%E4%BD%93/datasets/Layer5/features/1.stream", "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", ];
不知道.stream是什么文件
或者能不能远程帮我看看
您好,地质体裁剪与开挖使用的地址为数据服务地址,您加载的服务为三维服务,数据服务需要工作空间中有数据集,然后使用该工作空间发数据服务后参考"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"路径进行加载即可
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