Projection

A style's projection property sets which projection a map is rendered in. Mercator and Globe projections are supported.

Globe projection is a custom map projection mode for rendering the map wrapped around a full 3D globe. Conceptually it is the undistorted and unskewed “ground truth” view of the map that preserves true proportions between different areas of the map.

Some layers are not supported when map is in globe projection:

  • custom

  • location indicator

Using ProjectionName.GLOBE requires OpenGL GLES20.GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS be more than zero. If GLES20.GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS is zero (which may happen for low-end devices and old Android versions) - ProjectionName.GLOBE will fallback to ProjectionName.MERCATOR with the log warning.

See also

Parameters

name

from ProjectionName enum

Constructors

Projection
Link copied to clipboard
fun Projection(name: ProjectionName)

Functions

bindTo
Link copied to clipboard
open override fun bindTo(delegate: StyleInterface)

Bind projection to the map controller.

Properties

name
Link copied to clipboard
val name: ProjectionName