StyleByZoom
open class StyleByZoom<T>(valueByZoom: Map<Double, T>, defaultValue: T, interpolationFunction: (zoom: Double, minZoom: Double, maxZoom: Double, minZoomValue: T, maxZoomValue: T) -> T)
Represents the style value to use for each zoom level.
Important: This is a Public Preview API. It may be changed or removed at any time.
Parameters
valueByZoom
A mapping of zoom levels to a generic style type.
defaultValue
The default value used when no mapping is found.
interpolationFunction
Function used to interpolate style value between zoom levels.
Constructors
Functions
Link copied to clipboard
Returns the corresponding style value. If a zoom level does not exists, the value will interpolated using the interpolationFunction and the corresponding range. If valueByZoom is empty, defaultValue will be returned.