MapCameraManagerDelegate

Definition of a camera delegate. Any invocation will interact with the map's actual camera.

Functions

Link copied to clipboard
abstract fun cameraForCoordinateBounds(bounds: CoordinateBounds, padding: EdgeInsets? = null, bearing: Double? = null, pitch: Double? = null, maxZoom: Double? = null, offset: ScreenCoordinate? = null): CameraOptions

Convenience method that returns the CameraOptions object for given parameters.

Link copied to clipboard
abstract fun cameraForCoordinates(coordinates: List<Point>, camera: CameraOptions, box: ScreenBox): CameraOptions

Convenience method that adjusts the provided camera options object for given arguments

abstract fun cameraForCoordinates(coordinates: List<Point>, padding: EdgeInsets? = null, bearing: Double? = null, pitch: Double? = null): CameraOptions

Convenience method that returns the camera options object for given arguments

Link copied to clipboard
abstract fun cameraForGeometry(geometry: Geometry, padding: EdgeInsets? = null, bearing: Double? = null, pitch: Double? = null): CameraOptions

Convenience method that returns the camera options object for given arguments

Link copied to clipboard

Returns the CoordinateBounds for a given camera.

Link copied to clipboard

Returns the CoordinateBounds for a given camera.

Link copied to clipboard

Returns the CoordinateBounds for given RectF defined in screen points.

Link copied to clipboard

Returns the coordinate bounds and zoom for a given camera.

Link copied to clipboard

Returns the unwrapped coordinate bounds and zoom for a given camera.

Link copied to clipboard
abstract fun coordinateForPixel(pixel: ScreenCoordinate): Point

Calculates a geographical coordinate(i.e., longitude-latitude pair) that corresponds to a screen coordinate.

Link copied to clipboard

Calculates the geographical coordinate information that corresponds to a given screen coordinate.

Link copied to clipboard
abstract fun coordinatesForPixels(pixels: List<ScreenCoordinate>): List<Point>

Calculates geographical coordinates(i.e., longitude-latitude pair) that corresponds to screen coordinates.

Link copied to clipboard

Calculates the geographical coordinates information that corresponds to the given screen coordinates.

Link copied to clipboard
abstract fun dragEnd()

Ends the ongoing drag gesture. This function should be called always after the user has ended a drag gesture initiated by dragStart.

Link copied to clipboard
abstract fun dragStart(point: ScreenCoordinate)

Prepares the drag gesture to use the provided screen coordinate as a pivot point. This function should be called each time when user starts a dragging action (e.g. by clicking on the map). The following dragging will be relative to the pivot.

Link copied to clipboard
abstract fun getBounds(): CameraBounds

Returns the bounds of the map.

Link copied to clipboard

Calculates target point where camera should move after drag. The method should be called after dragStart and before dragEnd.

Link copied to clipboard

Gets the map's current free camera options. After mutation, it should be set back to the map.

Link copied to clipboard
abstract fun pixelForCoordinate(coordinate: Point): ScreenCoordinate

Calculates a screen coordinate that corresponds to a geographical coordinate (i.e., longitude-latitude pair).

Link copied to clipboard
abstract fun pixelsForCoordinates(coordinates: List<Point>): List<ScreenCoordinate>

Calculates screen coordinates that corresponds to geographical coordinates (i.e., longitude-latitude pair).

Link copied to clipboard

Sets the bounds of the map.

Link copied to clipboard
abstract fun setCamera(cameraOptions: CameraOptions)

Changes the map view by any combination of center, zoom, bearing, and pitch, without an animated transition. The map will retain its current values for any details not passed via the camera options argument. It is not guaranteed that the provided CameraOptions will be set, the map may apply constraints resulting in a different CameraState.

abstract fun setCamera(freeCameraOptions: FreeCameraOptions)

Sets the map view with the free camera options.

Properties

Link copied to clipboard
abstract val cameraState: CameraState

Represents current camera state.

Inheritors

Link copied to clipboard