Module: ol/format/KML

ol/format/KML


Classes

KML

Type Definitions

GxTrackObject{Object}

Properties:
Name Type Description
coordinates Array.<Array.<number>>

Coordinates.

whens Array.<number>

Whens.

IconUrlFunction()

A function that takes a url {string} and returns a url {string}. Might be used to change an icon path or to substitute a data url obtained from a KMZ array buffer.

KMLCamera{Object}

Specifies the observer's viewpoint and associated view parameters.

Properties:
Name Type Description
Latitude number | undefined

Latitude of the camera.

Longitude number | undefined

Longitude of the camera.

Altitude number | undefined

Altitude of the camera.

AltitudeMode string | undefined

Floor-related altitude mode.

Heading number | undefined

Horizontal camera rotation.

Tilt number | undefined

Lateral camera rotation.

Roll number | undefined

Vertical camera rotation.

Options{Object}

Properties:
Name Type Description
extractStyles boolean
(defaults to true)

Extract styles from the KML.

showPointNames boolean
(defaults to true)

Show names as labels for placemarks which contain points.

defaultStyle Array<Style> | undefined

Default style. The default default style is the same as Google Earth.

writeStyles boolean
(defaults to true)

Write styles into KML.

crossOrigin null | string
(defaults to 'anonymous')

The crossOrigin attribute for loaded images. Note that you must provide a crossOrigin value if you want to access pixel data with the Canvas renderer.

iconUrlFunction IconUrlFunction | undefined

Function that takes a url string and returns a url string. Might be used to change an icon path or to substitute a data url obtained from a KMZ array buffer.

Vec2{Object}

Properties:
Name Type Description
x number

X coordinate.

xunits IconAnchorUnits

Units of x.

y number

Y coordinate.

yunits IconAnchorUnits

Units of Y.

origin IconOrigin | undefined

Origin.