Class: Static

ol/source/ImageStatic~Static


import Static from 'ol/source/ImageStatic';

A layer source for displaying a single, static image.

new Static(options)

source/ImageStatic.js, line 36
Name Type Description
options

ImageStatic options.

Name Type Description
attributions module:ol/source/Source~AttributionLike

Attributions.

crossOrigin null | string

The crossOrigin attribute for loaded images. Note that you must provide a crossOrigin value if you are using the WebGL renderer or 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.

imageExtent module:ol/extent~Extent

Extent of the image in map coordinates. This is the [left, bottom, right, top] map coordinates of your image.

imageLoadFunction module:ol/Image~LoadFunction

Optional function to load an image given a URL.

projection module:ol/proj~ProjectionLike

Projection.

imageSize module:ol/size~Size

Size of the image in pixels. Usually the image size is auto-detected, so this only needs to be set if auto-detection fails for some reason.

url string

Image URL.