Layer
maplibre.Layer
Bases: MapLibreBaseModel
Layer properties
Notes
See layers for more details on the
paint and layout properties of the layers.
Attributes:
| Name | Type | Description |
|---|---|---|
id |
str
|
Required. The unique ID of the layer. Defaults to |
type |
str | LayerType
|
Required. The type of the layer. |
filter |
list
|
A filter expression that is applied to the source of the layer. |
layout |
dict
|
The layout properties for the layer. |
max_zoom |
int
|
The maximum zoom level for the layer. |
min_zoom |
int
|
The minimum zoom level for the layer. |
paint |
dict
|
The paint properties for the layer. |
source |
str | Source | GeoDataFrame
|
The name (unique ID) of a source, a source object or a GeoDataFrame to be used for the layer. |
source_layer |
str
|
The layer to use from a vector tile source. |
Examples:
Source code in maplibre/layer.py
maplibre.LayerType
Bases: Enum
Rendering type of layer
Attributes:
-
CIRCLE–A filled circle.
-
FILL–A filled polygon with an optional stroked border.
-
FILL_EXTRUSION–An extruded polygon.
-
LINE–A stroked line.
-
SYMBOL–An icon or a text label.
-
RASTER–Raster map textures such as satellite imagery.
-
HEATMAP–A heatmap.
-
HILLSHADE–A Client-side hillshading visualization based on DEM data.
-
BACKGROUND–A background color or pattern.