FreeCameraOptions

Various options for accessing physical properties of the underlying camera entity. A direct access to these properties allows more flexible and precise controlling of the camera while also being fully compatible and interchangeable with CameraOptions. All fields are optional.

Functions

Link copied to clipboard
@Nullable
@MainThread
open fun getAltitude(): Double
Helper function for getting current altitude in meters
Link copied to clipboard
@Nullable
@MainThread
open fun getLocation(): Point
Helper function for getting current mercator position as Lat&Lng coordinate.
Link copied to clipboard
@Nullable
@MainThread
open fun getOrientation(): Vec4
Get the orientation of the camera represented as a unit quaternion [x, y, z, w].
Link copied to clipboard
@Nullable
@MainThread
open fun getPosition(): Vec3
Get the position of the camera in slightly modified web mercator coordinates - The size of 1 unit is the width of the projected world instead of the "mercator meter".
Link copied to clipboard
@MainThread
open fun lookAtPoint(@NonNull location: Point)
@MainThread
open fun lookAtPoint(@NonNull location: Point, altitude: Double)
@MainThread
open fun lookAtPoint(@NonNull location: Point, altitude: Double, @NonNull upVector: Vec3)
Helper function for setting orientation of the camera by defining a focus point.
Link copied to clipboard
@MainThread
open fun setAltitude(altitude: Double)
Helper function for setting the altitude in meters.
Link copied to clipboard
@MainThread
open fun setLocation(@NonNull location: Point)
Helper function for setting the mercator position as Lat&Lng coordinate.
@MainThread
open fun setLocation(@NonNull location: Point, altitude: Double)
Helper function for setting the mercator position as Lat&Lng and altitude in meters.
Link copied to clipboard
@MainThread
open fun setOrientation(@Nullable orientation: Vec4)
Set the orientation of the camera represented as a unit quaternion [x, y, z, w].
Link copied to clipboard
@MainThread
open fun setPitchBearing(pitch: Double, bearing: Double)
Helper function for setting the orientation of the camera as a pitch and a bearing.
Link copied to clipboard
@MainThread
open fun setPosition(@Nullable position: Vec3)
Set the position of the camera in slightly modified web mercator coordinates - The size of 1 unit is the width of the projected world instead of the "mercator meter".