summaryrefslogtreecommitdiff
path: root/src/mbgl/renderer/tile_pyramid.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mbgl/renderer/tile_pyramid.cpp')
-rw-r--r--src/mbgl/renderer/tile_pyramid.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/mbgl/renderer/tile_pyramid.cpp b/src/mbgl/renderer/tile_pyramid.cpp
index 57e7f6d375..5b1e621743 100644
--- a/src/mbgl/renderer/tile_pyramid.cpp
+++ b/src/mbgl/renderer/tile_pyramid.cpp
@@ -176,15 +176,12 @@ void TilePyramid::update(const std::vector<Immutable<style::Layer::Impl>>& layer
removeStaleTiles(retain);
for (auto& pair : tiles) {
- // TODO: Calculating yStretch based on tile distance means we can no longer use the same collision tile for two wrapped
- // copies of the same data tile. For now the assumption that we're always at "wrap = 0" means collision detection is broken
- // for wrapped tiles.
const PlacementConfig config { parameters.transformState.getAngle(),
parameters.transformState.getPitch(),
parameters.transformState.getCameraToCenterDistance(),
- parameters.transformState.getCameraToTileDistance(pair.first.unwrapTo(0)),
+ parameters.transformState.getCameraToTileDistance(pair.first.toUnwrapped()),
parameters.debugOptions & MapDebugOptions::Collision };
-
+
pair.second->setPlacementConfig(config);
}
}