Pass-by-const-ref is not always possible because CameraOptions gets its
members modified along the way.
Also fixes a case in Map::jumpTo where Update::Zoom should be called if
zoom is affected.
The final frame is self-destructing – it destroys the frame and finish functions – so technically we’re no longer inTransition(). Yet there still needs to be an update after that final frame.
Also, avoid a redundant change notification on the last frame. (It would come too late, after the DidChange notification, anyhow.)
Fixes#2946.
The location under your finger stays under your finger as you pan.
The location you double tap to zoom stays at the same point.
The location at the center of a pinch zoom stays at the center.
The location at the center of a rotation stays at the center.
Plumbed camera options all the way through to MGLMapView. Added a method that lets you specify a direction in addition to center point and zoom level.
Added Map::jumpTo() for parity with mapbox-gl-js. Replaced usage of Map::setLatLng() and Map::setLatLngZoom() with Map::jumpTo() or Map::easeTo() within MGLMapView. Replaced MGLMapView.pitch with MGLMapCamera for setting all supported degrees of freedom simultaneously. Simultaneously move and rotate with course.
Support customizable timing functions on iOS.
iosapp now persists an archived MGLMapCamera instead of separate viewpoint properties and also synchronizes user defaults on termination. This change implements persistence entirely in Objective-C, eliminating the use of the Objective-C++ implementation.
Fixes#1643, fixes#1834. Ref #1581.
Transform::{_moveBy,_setAngle} were returning Update::Nothing, causing
the render to not repaint. Replacing with Update::Repaint fixes the
issue.
Fixes#2036.
#1295 made #1199 a lot less common, but it was still possible for the map to do a full 180° when drift-rotating past due-south. With this change, the map is atomically rotated to a bearing in the same cycle as the final bearing.
/cc @friedbunny
This brings the easing transition code a bit closer to how easings work
in gl-js. Instead of having an array of individual transitions for scale,
rotate, and pan, there is a single transition function that does all the
required calculations. This permits us to:
* Eliminate the "timeout" transition. (Fixes#126)
* Replace start/stopPanning() et al with setGestureInProgress(). Apps or
SDKs are expected to make paired calls to setGestureInProgress(). This
state will be ORed with the active easing state to determine when to
use texture interpolation. (Fixes#79)
* Run style recalculations only when an ease transition that affects the
zoom is in progress. (Fixes#1155)