This repository has been archived by the owner on Aug 8, 2023. It is now read-only.
MGLMapView.camera.heading goes negative when rotating to face northwest #7723
Labels
bug
iOS
Mapbox Maps SDK for iOS
macOS
Mapbox Maps SDK for macOS
navigation
For the Mapbox Navigation SDK for Android or iOS or navigation use cases in general
Milestone
When you rotate an MGLMapView so that it faces anywhere between due north and due west, exclusive, its
direction
property is wrapped to between 0° and 360°, but itscamera
’sheading
goes negative, indicating an invalid direction according toCLLocationDirection
semantics. Therefore, if you then set thecamera
property of any map view to that MGLMapCamera, you wind up facing the wrong direction.This regression was introduced in #4790 but was not addressed by df0d118.
/cc @incanus @friedbunny
The text was updated successfully, but these errors were encountered: