CanvasMap
Getting Started Tutorials 3D Reference

Class CM3LayerTerrain extends CM3Layer

CM3LayerTerrain Class

Manages a layer that contains an image of the terrain
This can include:
- A DEM for elevation values
- An image to overlay on the DEM
- A bump map to add surface texture
- A reflectance map to change how light interacts with the surface

Settings Group: Elevation

Setting Name Type Options Default Comments
Exaggeration Exaggeration CMTYPE_FLOAT 1
Offset Offset CMTYPE_FLOAT 0
URL URL CMTYPE_STRING
RoundEdges Round Edges CMTYPE_BOOLEAN 1
OuterDrape Outer Drape CMTYPE_BOOLEAN false
DrapeColor Drape Color CMTYPE_COLOR rgb(0,0,0)
DrapeElevation Drape Elevation CMTYPE_FLOAT 0

Settings Group: TerrainMaterial

Setting Name Type Options Default Comments
Opacity Opacity CMTYPE_FLOAT 1
Transparent Transparent CMTYPE_BOOLEAN false
Color Color CMTYPE_COLOR rgb(255,255,255)
Side Side CMTYPE_ENUMERATED THREE.DoubleSide, THREE.FrontSide, THREE.BackSide THREE.DoubleSide
map Overlaid Image (map) CMTYPE_STRING null
bumpMap Bump Map CMTYPE_STRING null
bumpScale Bump Scale CMTYPE_INTEGER 10
specularMap Reflectance Map CMTYPE_STRING null
specular Specular Color CMTYPE_COLOR grey

Object Functions

Inherited From: CM3Layer
ReturnsFunctionThrows
RequestData()
GetDEMDataset()
SetPyramidURL()

Object Functions

RequestData()

Called to obtain the data for the layer from a URL.

GetDEMDataset()

Allows tiles to find the DEM dataset that is associated with this terrain.

SetPyramidURL()

Function to load data from CanvasMap pryamid files.