elevation

The elevation object enables you to load elevation layers into the project and provides access to all loaded layers. The following member and method are available:

§  items

§  create()

 

items

static items : Array<TerraExplorerObject>

Returns an array of TerraExplorerObject containing all the elevation layers in the project.

 

create

create(description, url, layer, showInMyLayersMenu) → {promise}

Loads an elevation layer into the project.

Parameters

Name

Type       

Description

description

String

The name of the layer as it appears in the Layers tab of the TE4W sidebar. If an empty string is passed to this parameter, the layer is assigned a default name for display in the sidebar.

url

String

The URL of the SkylineGlobe Server (SGS) from which the layer is loaded, e.g., http://www.SkylineGlobe.com/SG.

layer

String

The ID or alias of the layer in the SkylineGlobe Server. You can obtain the layer ID by looking it up in the SGS Manager.

showInMyLayersMenu

Boolean

Determines whether the created layer is listed in TE4W's sidebar (with a star by the layer entry to indicate that it was loaded into the project from SkylineGlobe Server). If showInMyLayersMenu is set to false, the layer is not listed.

Returns

Promise - A promise that resolves to the newly created elevation layer TerraExplorerObject object when loaded or an error string if the layer failed to load.

Example

The following example creates an elevation layer:

Cesium.when(TerraExplorer.layers.elevation.create("ASTGTM2_N38W078",https://www.skylineglobe.com/SG,"ASTGTM2_N38W078_dem.Ei.mpt",true), function(teObject){

teObject.flyTo();})