diff options
author | Bruno de Oliveira Abinader <bruno@mapbox.com> | 2016-02-09 18:01:30 +0200 |
---|---|---|
committer | Bruno de Oliveira Abinader <bruno@mapbox.com> | 2016-03-01 20:58:54 +0000 |
commit | 9955087767d226c09816d562be39be1f1a1e84c5 (patch) | |
tree | fe5ecccddd316be5e01fa69ec35ef0411536178c /src | |
parent | 5ac6fc523dea6374da7ba15a7c0433b115987ed2 (diff) | |
download | qtlocation-mapboxgl-9955087767d226c09816d562be39be1f1a1e84c5.tar.gz |
[core] Fix potential precision data loss
Diffstat (limited to 'src')
-rw-r--r-- | src/mbgl/source/source_info.hpp | 4 | ||||
-rw-r--r-- | src/mbgl/style/style_parser.cpp | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/mbgl/source/source_info.hpp b/src/mbgl/source/source_info.hpp index 2fb5c2466d..ea134c0210 100644 --- a/src/mbgl/source/source_info.hpp +++ b/src/mbgl/source/source_info.hpp @@ -19,8 +19,8 @@ public: uint16_t minZoom = 0; uint16_t maxZoom = 22; std::string attribution; - std::array<float, 3> center = { { 0, 0, 0 } }; - std::array<float, 4> bounds = { { -180, -90, 180, 90 } }; + std::array<double, 3> center = { { 0, 0, 0 } }; + std::array<double, 4> bounds = { { -180, -90, 180, 90 } }; }; } // namespace mbgl diff --git a/src/mbgl/style/style_parser.cpp b/src/mbgl/style/style_parser.cpp index 7c2a94b206..767bee095d 100644 --- a/src/mbgl/style/style_parser.cpp +++ b/src/mbgl/style/style_parser.cpp @@ -78,7 +78,7 @@ void parseTileJSONMember(const JSValue& value, uint16_t& target, const char* nam } template <size_t N> -void parseTileJSONMember(const JSValue& value, std::array<float, N>& target, const char* name) { +void parseTileJSONMember(const JSValue& value, std::array<double, N>& target, const char* name) { if (!value.HasMember(name)) { return; } |