FillExtrusionLayer

class FillExtrusionLayer(val layerId: String, val sourceId: String) : Layer, FillExtrusionLayerDsl

An extruded (3D) polygon.

See also

Parameters

layerId

the ID of the layer

sourceId

the ID of the source

Constructors

Link copied to clipboard
fun FillExtrusionLayer(layerId: String, sourceId: String)

Types

Link copied to clipboard
object Companion

Static variables and methods.

Functions

Link copied to clipboard
fun bindTo(delegate: MapboxStyleManager)

Bind the layer to the Style.

open override fun bindTo(delegate: MapboxStyleManager, position: LayerPosition?)

Bind the layer to the map controller.

open override fun fillExtrusionAmbientOcclusionGroundAttenuation(fillExtrusionAmbientOcclusionGroundAttenuation: Expression): FillExtrusionLayer
open override fun fillExtrusionAmbientOcclusionGroundAttenuation(fillExtrusionAmbientOcclusionGroundAttenuation: Double): FillExtrusionLayer

Provides a control to futher fine-tune the look of the ambient occlusion on the ground beneath the extruded buildings. Lower values give the effect a more solid look while higher values make it smoother. Default value: 0.69. Value range: 0, 1

open override fun fillExtrusionAmbientOcclusionGroundRadius(fillExtrusionAmbientOcclusionGroundRadius: Expression): FillExtrusionLayer
open override fun fillExtrusionAmbientOcclusionGroundRadius(fillExtrusionAmbientOcclusionGroundRadius: Double): FillExtrusionLayer

The extent of the ambient occlusion effect on the ground beneath the extruded buildings in meters. Default value: 3. Minimum value: 0.

Link copied to clipboard
open override fun fillExtrusionAmbientOcclusionIntensity(fillExtrusionAmbientOcclusionIntensity: Expression): FillExtrusionLayer
open override fun fillExtrusionAmbientOcclusionIntensity(fillExtrusionAmbientOcclusionIntensity: Double): FillExtrusionLayer

Controls the intensity of shading near ground and concave angles between walls. Default value 0.0 disables ambient occlusion and values around 0.3 provide the most plausible results for buildings. Default value: 0. Value range: 0, 1

Link copied to clipboard
open override fun fillExtrusionAmbientOcclusionRadius(fillExtrusionAmbientOcclusionRadius: Expression): FillExtrusionLayer
open override fun fillExtrusionAmbientOcclusionRadius(fillExtrusionAmbientOcclusionRadius: Double): FillExtrusionLayer

Shades area near ground and concave angles between walls where the radius defines only vertical impact. Default value 3.0 corresponds to height of one floor and brings the most plausible results for buildings. This property works only with legacy light. When 3D lights are enabled fill-extrusion-ambient-occlusion-wall-radius and fill-extrusion-ambient-occlusion-ground-radius are used instead. Default value: 3. Minimum value: 0.

Set the FillExtrusionAmbientOcclusionRadius property transition options

Link copied to clipboard
open override fun fillExtrusionAmbientOcclusionWallRadius(fillExtrusionAmbientOcclusionWallRadius: Expression): FillExtrusionLayer
open override fun fillExtrusionAmbientOcclusionWallRadius(fillExtrusionAmbientOcclusionWallRadius: Double): FillExtrusionLayer

Shades area near ground and concave angles between walls where the radius defines only vertical impact. Default value 3.0 corresponds to height of one floor and brings the most plausible results for buildings. Default value: 3. Minimum value: 0.

Link copied to clipboard
open override fun fillExtrusionBase(fillExtrusionBase: Expression): FillExtrusionLayer
open override fun fillExtrusionBase(fillExtrusionBase: Double): FillExtrusionLayer

The height with which to extrude the base of this layer. Must be less than or equal to fill-extrusion-height. Default value: 0. Minimum value: 0.

Link copied to clipboard

Set the FillExtrusionBase property transition options

Link copied to clipboard
open override fun fillExtrusionColor(fillExtrusionColor: Expression): FillExtrusionLayer
open override fun fillExtrusionColor(@ColorInt fillExtrusionColor: Int): FillExtrusionLayer
open override fun fillExtrusionColor(fillExtrusionColor: String): FillExtrusionLayer

The base color of the extruded fill. The extrusion's surfaces will be shaded differently based on this color in combination with the root light settings. If this color is specified as rgba with an alpha component, the alpha component will be ignored; use fill-extrusion-opacity to set layer opacity. Default value: "#000000".

Link copied to clipboard

Set the FillExtrusionColor property transition options

Link copied to clipboard
open override fun fillExtrusionCutoffFadeRange(fillExtrusionCutoffFadeRange: Expression): FillExtrusionLayer
open override fun fillExtrusionCutoffFadeRange(fillExtrusionCutoffFadeRange: Double): FillExtrusionLayer

This parameter defines the range for the fade-out effect before an automatic content cutoff on pitched map views. Fade out is implemented by scaling down and removing buildings in the fade range in a staggered fashion. Opacity is not changed. 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

Link copied to clipboard
open override fun fillExtrusionEdgeRadius(fillExtrusionEdgeRadius: Expression): FillExtrusionLayer
open override fun fillExtrusionEdgeRadius(fillExtrusionEdgeRadius: Double): FillExtrusionLayer

Radius of a fill extrusion edge in meters. If not zero, rounds extrusion edges for a smoother appearance. Default value: 0. Value range: 0, 1

Link copied to clipboard
open override fun fillExtrusionEmissiveStrength(fillExtrusionEmissiveStrength: Expression): FillExtrusionLayer
open override fun fillExtrusionEmissiveStrength(fillExtrusionEmissiveStrength: Double): FillExtrusionLayer

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

Link copied to clipboard

Set the FillExtrusionEmissiveStrength property transition options

Link copied to clipboard
open override fun fillExtrusionFloodLightColor(fillExtrusionFloodLightColor: Expression): FillExtrusionLayer
open override fun fillExtrusionFloodLightColor(@ColorInt fillExtrusionFloodLightColor: Int): FillExtrusionLayer
open override fun fillExtrusionFloodLightColor(fillExtrusionFloodLightColor: String): FillExtrusionLayer

The color of the flood light effect on the walls of the extruded buildings. Default value: "#ffffff".

Link copied to clipboard
open override fun fillExtrusionFloodLightGroundAttenuation(fillExtrusionFloodLightGroundAttenuation: Expression): FillExtrusionLayer
open override fun fillExtrusionFloodLightGroundAttenuation(fillExtrusionFloodLightGroundAttenuation: Double): FillExtrusionLayer

Provides a control to futher fine-tune the look of the flood light on the ground beneath the extruded buildings. Lower values give the effect a more solid look while higher values make it smoother. Default value: 0.69. Value range: 0, 1

Link copied to clipboard
open override fun fillExtrusionFloodLightGroundRadius(fillExtrusionFloodLightGroundRadius: Expression): FillExtrusionLayer
open override fun fillExtrusionFloodLightGroundRadius(fillExtrusionFloodLightGroundRadius: Double): FillExtrusionLayer

The extent of the flood light effect on the ground beneath the extruded buildings in meters. Note: this experimental property is evaluated once per tile, during tile initialization. Changing the property value could trigger tile reload. The feature-state styling is deprecated and will get removed soon. Default value: 0.

Link copied to clipboard
open override fun fillExtrusionFloodLightIntensity(fillExtrusionFloodLightIntensity: Expression): FillExtrusionLayer
open override fun fillExtrusionFloodLightIntensity(fillExtrusionFloodLightIntensity: Double): FillExtrusionLayer

The intensity of the flood light color. Default value: 0. Value range: 0, 1

Link copied to clipboard
open override fun fillExtrusionFloodLightWallRadius(fillExtrusionFloodLightWallRadius: Expression): FillExtrusionLayer
open override fun fillExtrusionFloodLightWallRadius(fillExtrusionFloodLightWallRadius: Double): FillExtrusionLayer

The extent of the flood light effect on the walls of the extruded buildings in meters. Default value: 0. Minimum value: 0.

Link copied to clipboard
open override fun fillExtrusionHeight(fillExtrusionHeight: Expression): FillExtrusionLayer
open override fun fillExtrusionHeight(fillExtrusionHeight: Double): FillExtrusionLayer

The height with which to extrude this layer. Default value: 0. Minimum value: 0.

Link copied to clipboard

Set the FillExtrusionHeight property transition options

Link copied to clipboard
open override fun fillExtrusionLineWidth(fillExtrusionLineWidth: Expression): FillExtrusionLayer
open override fun fillExtrusionLineWidth(fillExtrusionLineWidth: Double): FillExtrusionLayer

If a non-zero value is provided, it sets the fill-extrusion layer into wall rendering mode. The value is used to render the feature with the given width over the outlines of the geometry. Note: This property is experimental and some other fill-extrusion properties might not be supported with non-zero line width. Default value: 0. Minimum value: 0.

Link copied to clipboard
Link copied to clipboard
open override fun fillExtrusionOpacity(fillExtrusionOpacity: Expression): FillExtrusionLayer
open override fun fillExtrusionOpacity(fillExtrusionOpacity: Double): FillExtrusionLayer

The opacity of the entire fill extrusion layer. This is rendered on a per-layer, not per-feature, basis, and data-driven styling is not available. Default value: 1. Value range: 0, 1

Link copied to clipboard

Set the FillExtrusionOpacity property transition options

Link copied to clipboard
open override fun fillExtrusionPattern(fillExtrusionPattern: Expression): FillExtrusionLayer
open override fun fillExtrusionPattern(fillExtrusionPattern: String): FillExtrusionLayer

Name of image in sprite to use for drawing images on extruded fills. For seamless patterns, image width and height must be a factor of two (2, 4, 8, ..., 512). Note that zoom-dependent expressions will be evaluated only at integer zoom levels.

Link copied to clipboard
open override fun fillExtrusionRoundedRoof(fillExtrusionRoundedRoof: Expression): FillExtrusionLayer
open override fun fillExtrusionRoundedRoof(fillExtrusionRoundedRoof: Boolean): FillExtrusionLayer

Indicates whether top edges should be rounded when fill-extrusion-edge-radius has a value greater than 0. If false, rounded edges are only applied to the sides. Default is true. Default value: true.

Link copied to clipboard
open override fun fillExtrusionTranslate(fillExtrusionTranslate: Expression): FillExtrusionLayer
open override fun fillExtrusionTranslate(fillExtrusionTranslate: List<Double>): FillExtrusionLayer

The geometry's offset. Values are x, y where negatives indicate left and up (on the flat plane), respectively. Default value: 0,0.

Link copied to clipboard
open override fun fillExtrusionTranslateAnchor(fillExtrusionTranslateAnchor: Expression): FillExtrusionLayer
open override fun fillExtrusionTranslateAnchor(fillExtrusionTranslateAnchor: FillExtrusionTranslateAnchor): FillExtrusionLayer

Controls the frame of reference for fill-extrusion-translate. Default value: "map".

Link copied to clipboard

Set the FillExtrusionTranslate property transition options

Link copied to clipboard
open override fun fillExtrusionVerticalGradient(fillExtrusionVerticalGradient: Expression): FillExtrusionLayer
open override fun fillExtrusionVerticalGradient(fillExtrusionVerticalGradient: Boolean): FillExtrusionLayer

Whether to apply a vertical gradient to the sides of a fill-extrusion layer. If true, sides will be shaded slightly darker farther down. Default value: true.

Link copied to clipboard
open override fun fillExtrusionVerticalScale(fillExtrusionVerticalScale: Expression): FillExtrusionLayer
open override fun fillExtrusionVerticalScale(fillExtrusionVerticalScale: Double): FillExtrusionLayer

A global multiplier that can be used to scale base, height, AO, and flood light of the fill extrusions. Default value: 1. Minimum value: 0.

Link copied to clipboard
open override fun filter(filter: Expression): FillExtrusionLayer

A filter is a property at the layer level that determines which features should be rendered in a style layer.

Link copied to clipboard
open override fun maxZoom(maxZoom: Double): FillExtrusionLayer

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

Link copied to clipboard
open override fun minZoom(minZoom: Double): FillExtrusionLayer

The minimum zoom level for the layer. At zoom levels less than the minzoom, the layer will be hidden.

Link copied to clipboard
open override fun slot(slot: String): FillExtrusionLayer

The slot this layer is assigned to. If specified, and a slot with that name exists, it will be placed at that position in the layer order.

Link copied to clipboard
open override fun sourceLayer(sourceLayer: String): FillExtrusionLayer

A source layer is an individual layer of data within a vector source. A vector source can have multiple source layers.

Link copied to clipboard
open override fun visibility(visibility: Expression): FillExtrusionLayer
open override fun visibility(visibility: Visibility): FillExtrusionLayer

Whether this layer is displayed.

Properties

Provides a control to futher fine-tune the look of the ambient occlusion on the ground beneath the extruded buildings. Lower values give the effect a more solid look while higher values make it smoother. Default value: 0.69. Value range: 0, 1

Provides a control to futher fine-tune the look of the ambient occlusion on the ground beneath the extruded buildings. Lower values give the effect a more solid look while higher values make it smoother. Default value: 0.69. Value range: 0, 1

Transition options for FillExtrusionAmbientOcclusionGroundAttenuation.

The extent of the ambient occlusion effect on the ground beneath the extruded buildings in meters. Default value: 3. Minimum value: 0.

The extent of the ambient occlusion effect on the ground beneath the extruded buildings in meters. Default value: 3. Minimum value: 0.

Transition options for FillExtrusionAmbientOcclusionGroundRadius.

Link copied to clipboard

Controls the intensity of shading near ground and concave angles between walls. Default value 0.0 disables ambient occlusion and values around 0.3 provide the most plausible results for buildings. Default value: 0. Value range: 0, 1

Controls the intensity of shading near ground and concave angles between walls. Default value 0.0 disables ambient occlusion and values around 0.3 provide the most plausible results for buildings. Default value: 0. Value range: 0, 1

Transition options for FillExtrusionAmbientOcclusionIntensity.

Link copied to clipboard

Shades area near ground and concave angles between walls where the radius defines only vertical impact. Default value 3.0 corresponds to height of one floor and brings the most plausible results for buildings. This property works only with legacy light. When 3D lights are enabled fill-extrusion-ambient-occlusion-wall-radius and fill-extrusion-ambient-occlusion-ground-radius are used instead. Default value: 3. Minimum value: 0.

Shades area near ground and concave angles between walls where the radius defines only vertical impact. Default value 3.0 corresponds to height of one floor and brings the most plausible results for buildings. This property works only with legacy light. When 3D lights are enabled fill-extrusion-ambient-occlusion-wall-radius and fill-extrusion-ambient-occlusion-ground-radius are used instead. Default value: 3. Minimum value: 0.

Transition options for FillExtrusionAmbientOcclusionRadius.

Link copied to clipboard

Shades area near ground and concave angles between walls where the radius defines only vertical impact. Default value 3.0 corresponds to height of one floor and brings the most plausible results for buildings. Default value: 3. Minimum value: 0.

Shades area near ground and concave angles between walls where the radius defines only vertical impact. Default value 3.0 corresponds to height of one floor and brings the most plausible results for buildings. Default value: 3. Minimum value: 0.

Transition options for FillExtrusionAmbientOcclusionWallRadius.

Link copied to clipboard

The height with which to extrude the base of this layer. Must be less than or equal to fill-extrusion-height. Default value: 0. Minimum value: 0.

Link copied to clipboard

The height with which to extrude the base of this layer. Must be less than or equal to fill-extrusion-height. Default value: 0. Minimum value: 0.

Link copied to clipboard

Transition options for FillExtrusionBase.

Link copied to clipboard

The base color of the extruded fill. The extrusion's surfaces will be shaded differently based on this color in combination with the root light settings. If this color is specified as rgba with an alpha component, the alpha component will be ignored; use fill-extrusion-opacity to set layer opacity. Default value: "#000000".

Link copied to clipboard

The base color of the extruded fill. The extrusion's surfaces will be shaded differently based on this color in combination with the root light settings. If this color is specified as rgba with an alpha component, the alpha component will be ignored; use fill-extrusion-opacity to set layer opacity. Default value: "#000000".

Link copied to clipboard

The base color of the extruded fill. The extrusion's surfaces will be shaded differently based on this color in combination with the root light settings. If this color is specified as rgba with an alpha component, the alpha component will be ignored; use fill-extrusion-opacity to set layer opacity. Default value: "#000000".

Link copied to clipboard

Transition options for FillExtrusionColor.

Link copied to clipboard

This parameter defines the range for the fade-out effect before an automatic content cutoff on pitched map views. Fade out is implemented by scaling down and removing buildings in the fade range in a staggered fashion. Opacity is not changed. 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

Link copied to clipboard

This parameter defines the range for the fade-out effect before an automatic content cutoff on pitched map views. Fade out is implemented by scaling down and removing buildings in the fade range in a staggered fashion. Opacity is not changed. 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

Link copied to clipboard

Radius of a fill extrusion edge in meters. If not zero, rounds extrusion edges for a smoother appearance. Default value: 0. Value range: 0, 1

Link copied to clipboard

Radius of a fill extrusion edge in meters. If not zero, rounds extrusion edges for a smoother appearance. Default value: 0. Value range: 0, 1

Link copied to clipboard

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

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

Link copied to clipboard

Transition options for FillExtrusionEmissiveStrength.

Link copied to clipboard

The color of the flood light effect on the walls of the extruded buildings. Default value: "#ffffff".

Link copied to clipboard

The color of the flood light effect on the walls of the extruded buildings. Default value: "#ffffff".

Link copied to clipboard

The color of the flood light effect on the walls of the extruded buildings. Default value: "#ffffff".

Link copied to clipboard

Transition options for FillExtrusionFloodLightColor.

Link copied to clipboard

Provides a control to futher fine-tune the look of the flood light on the ground beneath the extruded buildings. Lower values give the effect a more solid look while higher values make it smoother. Default value: 0.69. Value range: 0, 1

Provides a control to futher fine-tune the look of the flood light on the ground beneath the extruded buildings. Lower values give the effect a more solid look while higher values make it smoother. Default value: 0.69. Value range: 0, 1

Transition options for FillExtrusionFloodLightGroundAttenuation.

Link copied to clipboard

The extent of the flood light effect on the ground beneath the extruded buildings in meters. Note: this experimental property is evaluated once per tile, during tile initialization. Changing the property value could trigger tile reload. The feature-state styling is deprecated and will get removed soon. Default value: 0.

The extent of the flood light effect on the ground beneath the extruded buildings in meters. Note: this experimental property is evaluated once per tile, during tile initialization. Changing the property value could trigger tile reload. The feature-state styling is deprecated and will get removed soon. Default value: 0.

Transition options for FillExtrusionFloodLightGroundRadius.

Link copied to clipboard

The intensity of the flood light color. Default value: 0. Value range: 0, 1

The intensity of the flood light color. Default value: 0. Value range: 0, 1

Transition options for FillExtrusionFloodLightIntensity.

Link copied to clipboard

The extent of the flood light effect on the walls of the extruded buildings in meters. Default value: 0. Minimum value: 0.

The extent of the flood light effect on the walls of the extruded buildings in meters. Default value: 0. Minimum value: 0.

Transition options for FillExtrusionFloodLightWallRadius.

Link copied to clipboard

The height with which to extrude this layer. Default value: 0. Minimum value: 0.

Link copied to clipboard

The height with which to extrude this layer. Default value: 0. Minimum value: 0.

Link copied to clipboard

Transition options for FillExtrusionHeight.

Link copied to clipboard

If a non-zero value is provided, it sets the fill-extrusion layer into wall rendering mode. The value is used to render the feature with the given width over the outlines of the geometry. Note: This property is experimental and some other fill-extrusion properties might not be supported with non-zero line width. Default value: 0. Minimum value: 0.

Link copied to clipboard

If a non-zero value is provided, it sets the fill-extrusion layer into wall rendering mode. The value is used to render the feature with the given width over the outlines of the geometry. Note: This property is experimental and some other fill-extrusion properties might not be supported with non-zero line width. Default value: 0. Minimum value: 0.

Link copied to clipboard

Transition options for FillExtrusionLineWidth.

Link copied to clipboard

The opacity of the entire fill extrusion layer. This is rendered on a per-layer, not per-feature, basis, and data-driven styling is not available. Default value: 1. Value range: 0, 1

Link copied to clipboard

The opacity of the entire fill extrusion layer. This is rendered on a per-layer, not per-feature, basis, and data-driven styling is not available. Default value: 1. Value range: 0, 1

Link copied to clipboard

Transition options for FillExtrusionOpacity.

Link copied to clipboard

Name of image in sprite to use for drawing images on extruded fills. For seamless patterns, image width and height must be a factor of two (2, 4, 8, ..., 512). Note that zoom-dependent expressions will be evaluated only at integer zoom levels.

Link copied to clipboard

Name of image in sprite to use for drawing images on extruded fills. For seamless patterns, image width and height must be a factor of two (2, 4, 8, ..., 512). Note that zoom-dependent expressions will be evaluated only at integer zoom levels.

Link copied to clipboard

Indicates whether top edges should be rounded when fill-extrusion-edge-radius has a value greater than 0. If false, rounded edges are only applied to the sides. Default is true. Default value: true.

Link copied to clipboard

Indicates whether top edges should be rounded when fill-extrusion-edge-radius has a value greater than 0. If false, rounded edges are only applied to the sides. Default is true. Default value: true.

Link copied to clipboard

The geometry's offset. Values are x, y where negatives indicate left and up (on the flat plane), respectively. Default value: 0,0.

Link copied to clipboard

Controls the frame of reference for fill-extrusion-translate. Default value: "map".

Link copied to clipboard

Controls the frame of reference for fill-extrusion-translate. Default value: "map".

Link copied to clipboard

The geometry's offset. Values are x, y where negatives indicate left and up (on the flat plane), respectively. Default value: 0,0.

Link copied to clipboard

Transition options for FillExtrusionTranslate.

Link copied to clipboard

Whether to apply a vertical gradient to the sides of a fill-extrusion layer. If true, sides will be shaded slightly darker farther down. Default value: true.

Whether to apply a vertical gradient to the sides of a fill-extrusion layer. If true, sides will be shaded slightly darker farther down. Default value: true.

Link copied to clipboard

A global multiplier that can be used to scale base, height, AO, and flood light of the fill extrusions. Default value: 1. Minimum value: 0.

Link copied to clipboard

A global multiplier that can be used to scale base, height, AO, and flood light of the fill extrusions. Default value: 1. Minimum value: 0.

Link copied to clipboard

Transition options for FillExtrusionVerticalScale.

Link copied to clipboard

A filter is a property at the layer level that determines which features should be rendered in a style layer.

Link copied to clipboard
open override val layerId: String
Link copied to clipboard
open override val maxZoom: Double?

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

Link copied to clipboard
open override val minZoom: Double?

The minimum zoom level for the layer. At zoom levels less than the minzoom, the layer will be hidden.

Link copied to clipboard
open override val slot: String?

The slot this layer is assigned to. If specified, and a slot with that name exists, it will be placed at that position in the layer order.

Link copied to clipboard
Link copied to clipboard

A source layer is an individual layer of data within a vector source. A vector source can have multiple source layers.

Link copied to clipboard
open override val visibility: Visibility?

Whether this layer is displayed.

Link copied to clipboard

Whether this layer is displayed.

Extensions

Link copied to clipboard

Get the persistent property as Boolean.