init(lookingAtCenter:fromEyeCoordinate:eyeAltitude:)
Returns a new camera object using the specified viewing angle information.
Declaration
convenience init(lookingAtCenter centerCoordinate: CLLocationCoordinate2D, fromEyeCoordinate eyeCoordinate: CLLocationCoordinate2D, eyeAltitude: CLLocationDistance)Parameters
- centerCoordinate:
The coordinate point on which the framework centers the map.
- eyeCoordinate:
The coordinate point at which to place the camera. If the value for this parameter is equal to the value in the
centerCoordinateparameter, the framework displays the map as if the camera is looking straight down. If this point is offset from thecenterCoordinatevalue, the framework displays the map with an appropriate heading and pitch angle. - eyeAltitude:
The altitude (in meters) above the ground at which to place the camera.
Return Value
A new camera object that initializes with the specified information.
Discussion
This method calculates the required pitch and heading angles to accommodate the specified eye position and altitude.