summaryrefslogtreecommitdiff
path: root/platform/darwin/src/MGLMapCamera.mm
diff options
context:
space:
mode:
Diffstat (limited to 'platform/darwin/src/MGLMapCamera.mm')
-rw-r--r--platform/darwin/src/MGLMapCamera.mm8
1 files changed, 4 insertions, 4 deletions
diff --git a/platform/darwin/src/MGLMapCamera.mm b/platform/darwin/src/MGLMapCamera.mm
index 49c7e70900..1611dbf4a3 100644
--- a/platform/darwin/src/MGLMapCamera.mm
+++ b/platform/darwin/src/MGLMapCamera.mm
@@ -32,11 +32,11 @@ BOOL MGLEqualFloatWithAccuracy(CGFloat left, CGFloat right, CGFloat accuracy)
mbgl::ProjectedMeters centerMeters = mbgl::Projection::projectedMetersForLatLng(centerLatLng);
mbgl::ProjectedMeters eyeMeters = mbgl::Projection::projectedMetersForLatLng(eyeLatLng);
- heading = std::atan((centerMeters.northing - eyeMeters.northing) /
- (centerMeters.easting - eyeMeters.easting));
+ heading = std::atan((centerMeters.northing() - eyeMeters.northing()) /
+ (centerMeters.easting() - eyeMeters.easting()));
- double groundDistance = std::hypot(centerMeters.northing - eyeMeters.northing,
- centerMeters.easting - eyeMeters.easting);
+ double groundDistance = std::hypot(centerMeters.northing() - eyeMeters.northing(),
+ centerMeters.easting() - eyeMeters.easting());
pitch = std::atan(eyeAltitude / groundDistance);
}