|
230 | 230 | "required": true, |
231 | 231 | "type": "array", |
232 | 232 | "value": "layer", |
233 | | - "doc": "A style's `layers` property lists all the layers available in that style. The type of layer is specified by the `type` property, and must be one of `background`, `fill`, `line`, `symbol`, `raster`, `circle`, `fill-extrusion`, `heatmap`, `hillshade`.\n\nExcept for layers of the `background` type, each layer needs to refer to a source. Layers take the data that they get from a source, optionally filter features, and then define how those features are styled.", |
| 233 | + "doc": "A style's `layers` property lists all the layers available in that style. The type of layer is specified by the `type` property, and must be one of `background`, `fill`, `line`, `symbol`, `raster`, `circle`, `fill-extrusion`, `heatmap`, `hillshade`, `color-relief`.\n\nExcept for layers of the `background` type, each layer needs to refer to a source. Layers take the data that they get from a source, optionally filter features, and then define how those features are styled.", |
234 | 234 | "example": [ |
235 | 235 | { |
236 | 236 | "id": "coastline", |
|
797 | 797 | } |
798 | 798 | } |
799 | 799 | }, |
| 800 | + "color-relief": { |
| 801 | + "doc": "Client-side elevation coloring based on DEM data. The implementation supports Mapbox Terrain RGB, Mapzen Terrarium tiles and custom encodings.", |
| 802 | + "sdk-support": { |
| 803 | + "basic functionality": { |
| 804 | + "js": "https://github.com/maplibre/maplibre-gl-js/issues/5666", |
| 805 | + "android": "https://github.com/maplibre/maplibre-native/issues/3408", |
| 806 | + "ios": "https://github.com/maplibre/maplibre-native/issues/3408" |
| 807 | + } |
| 808 | + } |
| 809 | + }, |
800 | 810 | "background": { |
801 | 811 | "doc": "The background color or pattern of the map.", |
802 | 812 | "sdk-support": { |
|
860 | 870 | "layout_symbol", |
861 | 871 | "layout_raster", |
862 | 872 | "layout_hillshade", |
| 873 | + "layout_color-relief", |
863 | 874 | "layout_background" |
864 | 875 | ], |
865 | 876 | "layout_background": { |
|
2687 | 2698 | "property-type": "constant" |
2688 | 2699 | } |
2689 | 2700 | }, |
| 2701 | + "layout_color-relief": { |
| 2702 | + "visibility": { |
| 2703 | + "type": "enum", |
| 2704 | + "values": { |
| 2705 | + "visible": { |
| 2706 | + "doc": "The layer is shown." |
| 2707 | + }, |
| 2708 | + "none": { |
| 2709 | + "doc": "The layer is not shown." |
| 2710 | + } |
| 2711 | + }, |
| 2712 | + "default": "visible", |
| 2713 | + "doc": "Whether this layer is displayed.", |
| 2714 | + "sdk-support": { |
| 2715 | + "basic functionality": { |
| 2716 | + } |
| 2717 | + }, |
| 2718 | + "property-type": "constant" |
| 2719 | + } |
| 2720 | + }, |
2690 | 2721 | "filter": { |
2691 | 2722 | "type": "array", |
2692 | 2723 | "value": "*", |
|
4187 | 4218 | } |
4188 | 4219 | } |
4189 | 4220 | }, |
| 4221 | + "elevation": { |
| 4222 | + "doc": "Gets the elevation of a pixel (in meters above the vertical datum reference of the `raster-dem` tiles) from a `raster-dem` source. Can only be used in the `color-relief-color` property of a `color-relief` layer.", |
| 4223 | + "syntax": { |
| 4224 | + "overloads": [ |
| 4225 | + { |
| 4226 | + "parameters": [], |
| 4227 | + "output-type": "number" |
| 4228 | + } |
| 4229 | + ] |
| 4230 | + }, |
| 4231 | + "example": ["elevation"], |
| 4232 | + "group": "Color Relief", |
| 4233 | + "sdk-support": { |
| 4234 | + "basic functionality": { |
| 4235 | + "js": "https://github.com/maplibre/maplibre-gl-js/issues/5666", |
| 4236 | + "android": "https://github.com/maplibre/maplibre-native/issues/3408", |
| 4237 | + "ios": "https://github.com/maplibre/maplibre-native/issues/3408" |
| 4238 | + } |
| 4239 | + } |
| 4240 | + }, |
4190 | 4241 | "line-progress": { |
4191 | 4242 | "doc": "Gets the progress along a gradient line. Can only be used in the `line-gradient` property.", |
4192 | 4243 | "syntax": { |
|
5610 | 5661 | "paint_symbol", |
5611 | 5662 | "paint_raster", |
5612 | 5663 | "paint_hillshade", |
| 5664 | + "paint_color-relief", |
5613 | 5665 | "paint_background" |
5614 | 5666 | ], |
5615 | 5667 | "paint_fill": { |
|
7633 | 7685 | "property-type": "data-constant" |
7634 | 7686 | } |
7635 | 7687 | }, |
| 7688 | + "paint_color-relief": { |
| 7689 | + "color-relief-opacity": { |
| 7690 | + "type": "number", |
| 7691 | + "default": 1, |
| 7692 | + "minimum": 0, |
| 7693 | + "maximum": 1, |
| 7694 | + "doc": "The opacity at which the color-relief will be drawn.", |
| 7695 | + "transition": true, |
| 7696 | + "sdk-support": { |
| 7697 | + "basic functionality": { |
| 7698 | + "js": "https://github.com/maplibre/maplibre-gl-js/issues/5666", |
| 7699 | + "android": "https://github.com/maplibre/maplibre-native/issues/3408", |
| 7700 | + "ios": "https://github.com/maplibre/maplibre-native/issues/3408" |
| 7701 | + } |
| 7702 | + }, |
| 7703 | + "expression": { |
| 7704 | + "interpolated": true, |
| 7705 | + "parameters": [ |
| 7706 | + "zoom" |
| 7707 | + ] |
| 7708 | + }, |
| 7709 | + "property-type": "data-constant" |
| 7710 | + }, |
| 7711 | + "color-relief-color": { |
| 7712 | + "type": "color", |
| 7713 | + "doc": "Defines the color of each pixel based on its elevation. Should be an expression that uses `[\"elevation\"]` as input.", |
| 7714 | + "example": [ |
| 7715 | + "interpolate", |
| 7716 | + ["linear"], |
| 7717 | + ["elevation"], |
| 7718 | + 0, "black", |
| 7719 | + 8849, "white" |
| 7720 | + ], |
| 7721 | + "transition": false, |
| 7722 | + "sdk-support": { |
| 7723 | + "basic functionality": { |
| 7724 | + "js": "https://github.com/maplibre/maplibre-gl-js/issues/5666", |
| 7725 | + "android": "https://github.com/maplibre/maplibre-native/issues/3408", |
| 7726 | + "ios": "https://github.com/maplibre/maplibre-native/issues/3408" |
| 7727 | + }, |
| 7728 | + "data-driven styling": {} |
| 7729 | + }, |
| 7730 | + "expression": { |
| 7731 | + "interpolated": true, |
| 7732 | + "parameters": [ |
| 7733 | + "elevation" |
| 7734 | + ] |
| 7735 | + }, |
| 7736 | + "property-type": "color-ramp" |
| 7737 | + } |
| 7738 | + }, |
7636 | 7739 | "paint_background": { |
7637 | 7740 | "background-color": { |
7638 | 7741 | "type": "color", |
|
0 commit comments