GeoArcGISTiledElevationTerrainProvider

new Cesium.GeoArcGISTiledElevationTerrainProvider(options)

自定义ArcGIS地形Provider。支持坐标系①WGS84经纬度②CGCS2000经纬度③高斯投影坐标系;支持切片方案①墨卡托切片方案②360度金字塔切片方案③ArcGIS Server建议方案。 其中第一个方案要求坐标系是WGS84的,第二个方案要求坐标系是WGS84或者CGCS2000的,第三个方案要求坐标系是高斯投影坐标系下的。
Name Type Description
options Object 参数选项
Name Type Default Description
url Resource | String | Promise.<Resource> | Promise.<String> ArcGIS地形服务地址
token String optional 服务token
tilingScheme TilingScheme | GeoProjectedTilingScheme optional 切片方案
topLevel Number 5 optional 请求服务的最小层级
bottomLevel Number 25 optional 请求服务的最大层级
Author:
  • liuhonglei
Examples:
// 墨卡托切片方案
        var terrainProvider = new Cesium.GeoArcGISTiledElevationTerrainProvider({
          url : 'https://192.168.100.231:6443/arcgis/rest/services/Dem/nx_mercator/ImageServer',
        });
        viewer.terrainProvider = terrainProvider;
        viewer.camera.setView({
          destination: Cesium.Cartesian3.fromDegrees(106, 37.5, 20000)
        });
// 360度金字塔方案
        var tilingScheme = new Cesium.GeoGeographicTilingScheme({
            viewer: viewer,
            resolutions: [0.010986328125000002, 0.005493164062500001, 0.0027465820312500004, 0.0013732910156250002,
            6.866455078125001E-4, 3.4332275390625005E-4, 1.7166137695312503E-4],
            origin: [-180.0, 90],
            extent: [115.578088473602, 28.652956471074, 115.890803585974, 28.874243879182],
            matrixWidth: 106,
            matrixHeight: 22,
            identifier: 0
        });
        var terrainProvider = new Cesium.GeoArcGISTiledElevationTerrainProvider({
            url: 'https://192.168.100.231:6443/arcgis/rest/services/Dem/ganjiang/ImageServer',
            tilingScheme: tilingScheme
        });
        viewer.terrainProvider = terrainProvider;
        viewer.camera.setView({
            destination: Cesium.Cartesian3.fromDegrees(115.73444602978799, 28.763600175127998, 20000)
        });
// 高斯投影坐标系建议方案
 var tilingScheme = new Cesium.GeoProjectedTilingScheme({
            viewer: viewer,
            resolutions: [2116.670900008467,1058.3354500042335,529.1677250021168,264.5838625010584,
                132.2919312505292,66.1459656252646,33.0729828126323,16.933367200067735],
            origin: [-5123200.0, 1.00021E7],
            extent: [499988.31453309144, 4540539.362186298, 584163.6431428336, 4652136.257245313],
            matrixWidth: 11,
            matrixHeight: 11,
            identifier: 0
        });
        var terrainProvider = new Cesium.GeoArcGISTiledElevationTerrainProvider({
            url: 'https://192.168.100.231:6443/arcgis/rest/services/Dem/shenyang1/ImageServer',
            tilingScheme: tilingScheme
        });
        viewer.terrainProvider = terrainProvider;
        viewer.camera.setView({
            destination: Cesium.Cartesian3.fromDegrees(0, 0, 5700)
        });

Members

availability : TileAvailability

瓦片可用性

credit : Credit

版权信息

errorEvent : Event

异步请求出错时的响应事件

hasVertexNormals : Boolean

是否支持法线

hasWaterMask : Boolean

是否水体掩膜

ready : Boolean

是否provider已准备好

readyPromise : Promise.<Boolean>

provider准备好的promise

tilingScheme : GeographicTilingScheme

切片方案

Methods

staticCesium.GeoArcGISTiledElevationTerrainProvider.getInstanceByCapabilities(options)Promise

通过请求服务元信息创建GeoArcGISTiledElevationTerrainProvider
Name Type Description
options Object 参数选项:
Name Type Description
viewer Viewer optional 三维球对象
url Resource | String 地形服务地址
parameters Object optional 传递给服务的附加参数
Returns:
如果请求元信息成功,则创建Provider
Example:
var promise = Cesium.GeoArcGISTiledElevationTerrainProvider.getInstanceByCapabilities({
 url: 'https://192.168.100.231:6443/arcgis/rest/services/Dem/ganjiang/ImageServer'
});
promise.then(function(terrainProvider) {
 viewer.terrainProvider = terrainProvider;
});