HillshadeLayer

fun HillshadeLayer(sourceState: SourceState, layerId: String = remember { generateRandomLayerId("hillshade") }, hillshadeAccentColor: ColorValue = ColorValue.INITIAL, hillshadeAccentColorTransition: Transition = Transition.INITIAL, hillshadeEmissiveStrength: DoubleValue = DoubleValue.INITIAL, hillshadeEmissiveStrengthTransition: Transition = Transition.INITIAL, hillshadeExaggeration: DoubleValue = DoubleValue.INITIAL, hillshadeExaggerationTransition: Transition = Transition.INITIAL, hillshadeHighlightColor: ColorValue = ColorValue.INITIAL, hillshadeHighlightColorTransition: Transition = Transition.INITIAL, hillshadeIlluminationAnchor: HillshadeIlluminationAnchorValue = HillshadeIlluminationAnchorValue.INITIAL, hillshadeIlluminationDirection: DoubleValue = DoubleValue.INITIAL, hillshadeShadowColor: ColorValue = ColorValue.INITIAL, hillshadeShadowColorTransition: Transition = Transition.INITIAL, visibility: VisibilityValue = VisibilityValue.INITIAL, minZoom: LongValue = LongValue.INITIAL, maxZoom: LongValue = LongValue.INITIAL, sourceLayer: StringValue = StringValue.INITIAL, filter: Filter = Filter.INITIAL)

Client-side hillshading visualization based on DEM data. Currently, the implementation only supports Mapbox Terrain RGB and Mapzen Terrarium tiles.

See also

Parameters

sourceState

the source that drives this layer.

layerId

the ID of the layer, by default, a random id will be generated with UUID.

hillshadeAccentColor

The shading color used to accentuate rugged terrain like sharp cliffs and gorges. Default value: "#000000".

hillshadeAccentColorTransition

Defines the transition of hillshadeAccentColor. Default value: "#000000".

hillshadeEmissiveStrength

Controls the intensity of light emitted on the source features. Default value: 0. Minimum value: 0.

hillshadeEmissiveStrengthTransition

Defines the transition of hillshadeEmissiveStrength. Default value: 0. Minimum value: 0.

hillshadeExaggeration

Intensity of the hillshade Default value: 0.5. Value range: 0, 1

hillshadeExaggerationTransition

Defines the transition of hillshadeExaggeration. Default value: 0.5. Value range: 0, 1

hillshadeHighlightColor

The shading color of areas that faces towards the light source. Default value: "#FFFFFF".

hillshadeHighlightColorTransition

Defines the transition of hillshadeHighlightColor. Default value: "#FFFFFF".

hillshadeIlluminationAnchor

Direction of light source when map is rotated. Default value: "viewport".

hillshadeIlluminationDirection

The direction of the light source used to generate the hillshading with 0 as the top of the viewport if hillshade-illumination-anchor is set to viewport and due north if hillshade-illumination-anchor is set to map and no 3d lights enabled. If hillshade-illumination-anchor is set to map and 3d lights enabled, the direction from 3d lights is used instead. Default value: 335. Value range: 0, 359

hillshadeShadowColor

The shading color of areas that face away from the light source. Default value: "#000000".

hillshadeShadowColorTransition

Defines the transition of hillshadeShadowColor. Default value: "#000000".

visibility

Whether this layer is displayed. Default value: "visible".

minZoom

The minimum zoom level for the layer. At zoom levels less than the minzoom, the layer will be hidden. Value range: 0, 24

maxZoom

The maximum zoom level for the layer. At zoom levels equal to or greater than the maxzoom, the layer will be hidden. Value range: 0, 24

sourceLayer

Layer to use from a vector tile source. Required for vector tile sources; prohibited for all other source types, including GeoJSON sources.

filter

An expression specifying conditions on source features. Only features that match the filter are displayed. Zoom expressions in filters are only evaluated at integer zoom levels. The ["feature-state", ...] expression is not supported in filter expressions. The ["pitch"] and ["distance-from-center"] expressions are supported only for filter expressions on the symbol layer.