MapUtils

Type module

Sources

Items from MapUtils can be imported/included and used via following ways.

/**
 * --------------------------------------------------------
 * Import via: MapUtils.ts
 * Access items like: $maputils.myVariable
 *                    $maputils.myFunction()
 * --------------------------------------------------------
 */
import * as $maputils from "@amcharts/amcharts4/MapUtils";

Variables

MapUtils does not have any variables.

Functions

pointToGeo(

point: number[]

)

#

Returns IGeoPoint

Converts X/Y point into a lat/long geo-point.

multiPolygonToGeo(

multiPolygon: number[]

)

#

Returns IGeoPoint[]

Converts a multi-part polygon in X/Y coordinates to a geo-multipolygon in geo-points (lat/long).

multiPointToGeo(

points: number[]

)

#

Returns IGeoPoint[]

Converts multiple X/Y points into a lat/long geo-points.

multiLineToGeo(

multiLine: number[]

)

#

Returns IGeoPoint[]

Converts a multiline in X/Y coordinates to a geo-multiline in geo-points (lat/long).

multiGeoToPoint(

geoPoints: IGeoPoint[]

)

#

Returns number[]

Converts multiple X/Y points into a lat/long geo-points.

multiGeoPolygonToMultipolygon(

multiGeoPolygon: IGeoPoint[]

)

#

Returns number[]

Converts a geo polygon (collection of lat/long coordinates) to screen polygon (x/y).

multiGeoLineToMultiLine(

multiGeoLine: IGeoPoint[]

)

#

Returns number[]

Converts geo line (collection of lat/long coordinates) to screen line (x/y).

getCircle(

longitude: number,
latitude: number,
radius: number

)

#

Returns number[]

Returns a set of geographical coordinates for the circle with a center at specific lat/long coordinates and radius (in degrees).

@since 4.3.0

getBackground(

north: number,
east: number,
south: number,
west: number

)

#

Returns number[]

Returns a set of screen coordinates that represents a "background" area between provided extremities.

@since 4.3.0