From ef2436527c94cbab4be12736f733c1bf25be32be Mon Sep 17 00:00:00 2001 From: Asheem Mamoowala Date: Mon, 4 Dec 2017 17:43:21 -0800 Subject: [core] Use wrapped bounds check for CustomTileLoader --- src/mbgl/style/custom_tile_loader.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mbgl/style/custom_tile_loader.cpp b/src/mbgl/style/custom_tile_loader.cpp index af091be5cf..76248b84bd 100644 --- a/src/mbgl/style/custom_tile_loader.cpp +++ b/src/mbgl/style/custom_tile_loader.cpp @@ -81,7 +81,7 @@ void CustomTileLoader::invalidateTile(const CanonicalTileID& tileID) { void CustomTileLoader::invalidateRegion(const LatLngBounds& bounds, Range ) { for (auto idtuple= tileCallbackMap.begin(); idtuple != tileCallbackMap.end(); idtuple++) { const LatLngBounds tileBounds(idtuple->first); - if (tileBounds.intersects(bounds) || bounds.contains(tileBounds) || tileBounds.contains(bounds)) { + if (tileBounds.intersects(bounds, LatLng::Wrapped) || bounds.contains(tileBounds, LatLng::Wrapped) || tileBounds.contains(bounds, LatLng::Wrapped)) { for (auto iter = idtuple->second.begin(); iter != idtuple->second.end(); iter++) { auto actor = std::get<2>(*iter); actor.invoke(&CustomGeometryTile::invalidateTileData); -- cgit v1.2.1