Changes the map's camera distance with an animated transition.
SDK
- MapKit JS 5.23+
Framework
- Map
Kit JS
Declaration
mapkit.Map setCameraDistanceAnimated(Number distance, optional Boolean animate);
Parameters
cameraDistance
Altitude of the camera from the center of the map. Must be greater than or equal to 0.
animate
A Boolean value that determines whether the visible area change should be animated. The default value is
true
.
Return Value
Returns the parent map instance object so calls can be chained.
Discussion
By default, the change of distance animates.