RelativeTargetCamera

data class RelativeTargetCamera<T : Number, Comparable<T>>(val target: Vec3<T>, val distance: T, val longitude: Angle<T>, val latitude: Angle<T>, val upVector: Vec3<T> = Vec3.unitZ(target.type)) : Camera<T>

A camera pointed at the given target, and located at the given distance from it, with the given longitude and latitude angles, while preserving the defined upVector.

Constructors

Link copied to clipboard
constructor(target: Vec3<T>, distance: T, longitude: Angle<T>, latitude: Angle<T>, upVector: Vec3<T> = Vec3.unitZ(target.type))

Properties

Link copied to clipboard
val distance: T

Distance from the target.

Link copied to clipboard
open override val eye: Vec3<T>

Position of the camera eye.

Link copied to clipboard

Camera latitude relative to the target.

Link copied to clipboard

Camera longitude relative to the target.

Link copied to clipboard
val target: Vec3<T>

Position of the camera target.

Link copied to clipboard

Up-vector preserved for the camera.

Link copied to clipboard
open override val viewMatrix: Mat4<T>

View matrix defined by the camera.