Model Layer State
The state holder for ModelLayer's layer properties.
See also
Constructors
Construct an default ModelLayerState.
Properties
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.
Defines the transition of modelAmbientOcclusionIntensity. Default value: 1. Value range: 0, 1
Defines the transition of modelColorMixIntensity. Default value: 0. Value range: 0, 1
Defines the transition of modelColor. Default value: "#ffffff".
This parameter defines the range for the fade-out effect before an automatic content cutoff on pitched map views. The automatic cutoff range is calculated according to the minimum required zoom level of the source and layer. The fade range is expressed in relation to the height of the map view. A value of 1.0 indicates that the content is faded to the same extent as the map's height in pixels, while a value close to zero represents a sharp cutoff. When the value is set to 0.0, the cutoff is completely disabled. Note: The property has no effect on the map if terrain is enabled. Default value: 0. Value range: 0, 1
Strength of the emission. There is no emission for value 0. For value 1.0, only emissive component (no shading) is displayed and values above 1.0 produce light contribution to surrounding area, for some of the parts (e.g. doors). Expressions that depend on measure-light are not supported when using GeoJSON or vector tile as the model layer source. Default value: 0. Value range: 0, 5
Defines the transition of modelEmissiveStrength. Default value: 0. Value range: 0, 5
An array for configuring the fade-out effect for the front cutoff of content on pitched map views. It contains three values: start, range and final opacity. The start parameter defines the point at which the fade-out effect begins, with smaller values causing the effect to start earlier. The range parameter specifies how long the fade-out effect will last. A value of 0.0 for range makes content disappear immediately without a fade-out effect. The final opacity determines content opacity at the end of the fade-out effect. A value of 1.0 for final opacity means that the cutoff is completely disabled. Default value: 0,0,1. Minimum value: 0,0,0. Maximum value: 1,1,1.
Defines the transition of modelHeightBasedEmissiveStrengthMultiplier. Default value: 1,1,1,1,0.
Defines the transition of modelOpacity. Default value: 1. Value range: 0, 1
Defines the transition of modelRotation. Default value: 0,0,0.
Defines the transition of modelRoughness. Default value: 1. Value range: 0, 1
Defines the transition of modelScale. Default value: 1,1,1.
Defines the transition of modelTranslation. Default value: 0,0,0.