diff options
author | John Firebaugh <john.firebaugh@gmail.com> | 2014-08-01 10:21:43 -0700 |
---|---|---|
committer | John Firebaugh <john.firebaugh@gmail.com> | 2014-08-01 10:21:43 -0700 |
commit | 9861f40f76b0d50986c453e0e7c7ed8699bff295 (patch) | |
tree | b8f03a15bd532da683bbf0901560a5f3ed5738a4 | |
parent | d8490853b9446426d30c2510cae0f1c5b5cfefd2 (diff) | |
download | qtlocation-mapboxgl-9861f40f76b0d50986c453e0e7c7ed8699bff295.tar.gz |
Remove rounding
-rw-r--r-- | src/map/transform.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/map/transform.cpp b/src/map/transform.cpp index 8187bed3e8..6338df6a48 100644 --- a/src/map/transform.cpp +++ b/src/map/transform.cpp @@ -98,8 +98,8 @@ void Transform::setLonLat(const double lon, const double lat, const timestamp du uv::writelock lock(mtx); const double f = std::fmin(std::fmax(std::sin(D2R * lat), -0.9999), 0.9999); - double xn = -std::round(lon * Bc); - double yn = std::round(0.5 * Cc * std::log((1 + f) / (1 - f))); + double xn = -lon * Bc; + double yn = 0.5 * Cc * std::log((1 + f) / (1 - f)); _setScaleXY(current.scale, xn, yn, duration); } @@ -115,8 +115,8 @@ void Transform::setLonLatZoom(const double lon, const double lat, const double z Cc = s / (2 * M_PI); const double f = std::fmin(std::fmax(std::sin(D2R * lat), -0.9999), 0.9999); - double xn = -std::round(lon * Bc); - double yn = std::round(0.5 * Cc * log((1 + f) / (1 - f))); + double xn = -lon * Bc; + double yn = 0.5 * Cc * log((1 + f) / (1 - f)); _setScaleXY(new_scale, xn, yn, duration); } |