MapCameraManagerDelegate

interface MapCameraManagerDelegate

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

Functions

cameraForCoordinateBounds
Link copied to clipboard
abstract fun cameraForCoordinateBounds(bounds: CoordinateBounds, padding: EdgeInsets = EdgeInsets(0.0, 0.0, 0.0, 0.0), bearing: Double? = null, pitch: Double? = null): CameraOptions
Convenience method that returns the camera options object for given arguments
cameraForCoordinates
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 argumentsReturns the provided \p camera with zoom adjusted to fit \p coordinates into \p box, so that coordinates on the left, top and right of the effective camera center at the principal point of the projection (defined by padding) fit into \p box.
abstract fun cameraForCoordinates(coordinates: List<Point>, padding: EdgeInsets = EdgeInsets(0.0, 0.0, 0.0, 0.0), bearing: Double? = null, pitch: Double? = null): CameraOptions
Convenience method that returns the camera options object for given arguments
cameraForGeometry
Link copied to clipboard
abstract fun cameraForGeometry(geometry: Geometry, padding: EdgeInsets = EdgeInsets(0.0, 0.0, 0.0, 0.0), bearing: Double? = null, pitch: Double? = null): CameraOptions
Convenience method that returns the camera options object for given arguments
coordinateBoundsForCamera
Link copied to clipboard
abstract fun coordinateBoundsForCamera(camera: CameraOptions): CoordinateBounds
Returns the CoordinateBounds for a given camera.
coordinateBoundsForCameraUnwrapped
Link copied to clipboard
abstract fun coordinateBoundsForCameraUnwrapped(camera: CameraOptions): CoordinateBounds
Returns the CoordinateBounds for a given camera.
coordinateBoundsZoomForCamera
Link copied to clipboard
abstract fun coordinateBoundsZoomForCamera(camera: CameraOptions): CoordinateBoundsZoom
Returns the coordinate bounds and zoom for a given camera.
coordinateBoundsZoomForCameraUnwrapped
Link copied to clipboard
abstract fun coordinateBoundsZoomForCameraUnwrapped(camera: CameraOptions): CoordinateBoundsZoom
Returns the unwrapped coordinate bounds and zoom for a given camera.
coordinateForPixel
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.
coordinatesForPixels
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.
dragEnd
Link copied to clipboard
abstract fun dragEnd()
Ends the ongoing drag gesture.
dragStart
Link copied to clipboard
abstract fun dragStart(point: ScreenCoordinate)
Prepares the drag gesture to use the provided screen coordinate as a pivot point.
equals
Link copied to clipboard
open operator fun equals(other: Any?): Boolean
getBounds
Link copied to clipboard
abstract fun getBounds(): CameraBounds
Returns the bounds of the map.
getDragCameraOptions
Link copied to clipboard
abstract fun getDragCameraOptions(fromPoint: ScreenCoordinate, toPoint: ScreenCoordinate): CameraOptions
Calculates target point where camera should move after drag.
getFreeCameraOptions
Link copied to clipboard
abstract fun getFreeCameraOptions(): FreeCameraOptions
Gets the map's current free camera options.
hashCode
Link copied to clipboard
open fun hashCode(): Int
pixelForCoordinate
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).
pixelsForCoordinates
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).
setBounds
Link copied to clipboard
abstract fun setBounds(options: CameraBoundsOptions): Expected<String, None>
Sets the bounds of the map.
setCamera
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.
abstract fun setCamera(freeCameraOptions: FreeCameraOptions)
Sets the map view with the free camera options.
toString
Link copied to clipboard
open fun toString(): String

Properties

cameraState
Link copied to clipboard
abstract val cameraState: CameraState
Represents current camera state.

Inheritors

MapboxMap
Link copied to clipboard