diff options
author | Bruno de Oliveira Abinader <bruno@mapbox.com> | 2017-11-29 20:28:50 +0200 |
---|---|---|
committer | Bruno de Oliveira Abinader <bruno@mapbox.com> | 2017-11-29 20:38:56 +0200 |
commit | 8c1be4ec01ef46bf453856531ebf53b48ce3dbe7 (patch) | |
tree | bf61fe31183b8e8d507b4f90bfe6733aa3b312e5 /src | |
parent | fdfa292676f3c7419b98a524f3a99b16b36099f9 (diff) | |
download | qtlocation-mapboxgl-8c1be4ec01ef46bf453856531ebf53b48ce3dbe7.tar.gz |
Bump Mapbox GL Native
mapbox-gl-native @ 8757164ac8f2b033b2b12d4baf075ed18cfeb2b4
Diffstat (limited to 'src')
-rw-r--r-- | src/mbgl/layout/symbol_projection.hpp | 8 | ||||
-rw-r--r-- | src/mbgl/renderer/renderer_backend.cpp | 2 | ||||
-rw-r--r-- | src/parsedate/parsedate.c | 18 |
3 files changed, 18 insertions, 10 deletions
diff --git a/src/mbgl/layout/symbol_projection.hpp b/src/mbgl/layout/symbol_projection.hpp index 8535014f22..3e57d162fd 100644 --- a/src/mbgl/layout/symbol_projection.hpp +++ b/src/mbgl/layout/symbol_projection.hpp @@ -23,9 +23,17 @@ namespace mbgl { }; struct PlacedGlyph { + PlacedGlyph() = default; + PlacedGlyph(Point<float> point_, float angle_, optional<TileDistance> tileDistance_) : point(point_), angle(angle_), tileDistance(std::move(tileDistance_)) {} + PlacedGlyph(PlacedGlyph&& other) noexcept + : point(std::move(other.point)), angle(other.angle), tileDistance(std::move(other.tileDistance)) + {} + PlacedGlyph(const PlacedGlyph& other) + : point(std::move(other.point)), angle(other.angle), tileDistance(std::move(other.tileDistance)) + {} Point<float> point; float angle; optional<TileDistance> tileDistance; diff --git a/src/mbgl/renderer/renderer_backend.cpp b/src/mbgl/renderer/renderer_backend.cpp index 159ef432b3..22d263313c 100644 --- a/src/mbgl/renderer/renderer_backend.cpp +++ b/src/mbgl/renderer/renderer_backend.cpp @@ -16,7 +16,7 @@ gl::Context& RendererBackend::getContext() { context = std::make_unique<gl::Context>(); context->enableDebugging(); context->initializeExtensions( - std::bind(&RendererBackend::initializeExtension, this, std::placeholders::_1)); + std::bind(&RendererBackend::getExtensionFunctionPointer, this, std::placeholders::_1)); }); return *context; } diff --git a/src/parsedate/parsedate.c b/src/parsedate/parsedate.c index 46acceed75..7228c4edbc 100644 --- a/src/parsedate/parsedate.c +++ b/src/parsedate/parsedate.c @@ -418,7 +418,7 @@ static time_t my_timegm(struct my_tm *tm) { static const int month_days_cumulative [12] = { 0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334 }; - int month, year, leap_days; + int month_, year, leap_days; if(tm->tm_year < 70) /* we don't support years before 1970 as they will cause this function @@ -426,14 +426,14 @@ static time_t my_timegm(struct my_tm *tm) return -1; year = tm->tm_year + 1900; - month = tm->tm_mon; - if(month < 0) { - year += (11 - month) / 12; - month = 11 - (11 - month) % 12; + month_ = tm->tm_mon; + if(month_ < 0) { + year += (11 - month_) / 12; + month_ = 11 - (11 - month_) % 12; } - else if(month >= 12) { - year -= month / 12; - month = month % 12; + else if(month_ >= 12) { + year -= month_ / 12; + month_ = month_ % 12; } leap_days = year - (tm->tm_mon <= 1); @@ -441,7 +441,7 @@ static time_t my_timegm(struct my_tm *tm) - (1969 / 4) + (1969 / 100) - (1969 / 400)); return ((((time_t) (year - 1970) * 365 - + leap_days + month_days_cumulative [month] + tm->tm_mday - 1) * 24 + + leap_days + month_days_cumulative [month_] + tm->tm_mday - 1) * 24 + tm->tm_hour) * 60 + tm->tm_min) * 60 + tm->tm_sec; } |