CameraOptions

Determines options for the new configuration of the camera. For example the location, zoom level, tilt angle.

All the options are optional. Setting any of these to null keeps the current camera property unmodified.

Important: This is a Public Preview API. It may be changed or removed at any time.

See also

to check convenient factory methods that can create various CameraOptions.

Parameters

position

GeoPoint of the new camera position.

zoom

Zoom value for the camera. The value shall be clamped by the CameraController.minZoom and the CameraController.maxZoom values. Values go from 0 (no zoom) to 22 (fully zoomed in). For example, 15 is building-level zoom.

tilt

Sets the tilt to the specified angle. The tilt is measured from the nadir, meaning that a value of 0 indicates the camera looking straight down, and 90 means straight ahead towards the horizon.

rotation

Sets the camera heading. Heading is measured starting at due north and continues clockwise around the compass. Thus, north is 0 degrees, east is 90 degrees, south is 180 degrees, and so on.

isSequentialUpdate

Whether this camera update is part of a sequence of camera updates (true), or is a one-shot update (otherwise).

Constructors

Link copied to clipboard
fun CameraOptions(position: GeoPoint? = null, @FloatRange(from = 0.0, to = 22.0) zoom: Double? = null, @FloatRange(from = 0.0, to = 90.0) tilt: Double? = null, @FloatRange(from = 0.0, to = 360.0) rotation: Double? = null)

Functions

Link copied to clipboard
fun deepCopy(position: GeoPoint? = null, @FloatRange(from = 0.0, to = 22.0) zoom: Double? = null, @FloatRange(from = 0.0, to = 90.0) tilt: Double? = null, @FloatRange(from = 0.0, to = 360.0) rotation: Double? = null): CameraOptions

Performs a deep copy of the current CameraOptions including all the properties which are not accessible via the constructor parameters.

Link copied to clipboard
abstract fun describeContents(): Int
Link copied to clipboard
abstract fun writeToParcel(p0: Parcel, p1: Int)

Properties

Link copied to clipboard
val position: GeoPoint? = null
Link copied to clipboard
val rotation: Double? = null
Link copied to clipboard
val tilt: Double? = null
Link copied to clipboard
val zoom: Double? = null