Classes
Type Definitions
-
Config{Object}
-
Properties:
Name Type Description namestring | undefined The name.
descriptionstring | undefined The description.
versionstring | undefined The version.
attributionstring | undefined The attribution.
templatestring | undefined The template.
legendstring | undefined The legend.
schemestring | undefined The scheme.
tilesArray.<string> The tile URL templates.
gridsArray.<string> | undefined Optional grids.
minzoomnumber | undefined Minimum zoom level.
maxzoomnumber | undefined Maximum zoom level.
boundsArray.<number> | undefined Optional bounds.
centerArray.<number> | undefined Optional center.
-
Options{Object}
-
Properties:
Name Type Description attributionsAttributionLike | undefined Attributions.
cacheSizenumber | undefined Deprecated. Use the cacheSize option on the layer instead.
crossOriginnull | string | undefined The
crossOriginattribute for loaded images. Note that you must provide acrossOriginvalue if you want to access pixel data with the Canvas renderer. See https://developer.mozilla.org/en-US/docs/Web/HTML/CORS_enabled_image for more detail.interpolateboolean
(defaults to true)Use interpolated values when resampling. By default, linear interpolation is used when resampling. Set to false to use the nearest neighbor instead.
jsonpboolean
(defaults to false)Use JSONP with callback to load the TileJSON. Useful when the server does not support CORS..
reprojectionErrorThresholdnumber
(defaults to 0.5)Maximum allowed reprojection error (in pixels). Higher values can increase reprojection performance, but decrease precision.
tileJSONConfig | undefined TileJSON configuration for this source. If not provided,
urlmust be configured.tileLoadFunctionLoadFunction | undefined Optional function to load a tile given a URL. The default is
function(imageTile, src) { imageTile.getImage().src = src; };tileSizenumber | Size
(defaults to [256, 256])The tile size used by the tile service. Note:
tileSizeand other non-standard TileJSON properties are currently ignored.urlstring | undefined URL to the TileJSON file. If not provided,
tileJSONmust be configured.wrapXboolean
(defaults to true)Whether to wrap the world horizontally.
transitionnumber | undefined Duration of the opacity transition for rendering. To disable the opacity transition, pass
transition: 0.zDirectionnumber | NearestDirectionFunction
(defaults to 0)Choose whether to use tiles with a higher or lower zoom level when between integer zoom levels. See
getZForResolution.