summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThiago Marcos P. Santos <tmpsantos@gmail.com>2017-07-12 16:09:31 +0300
committerThiago Marcos P. Santos <tmpsantos@gmail.com>2017-07-12 16:10:32 +0300
commit1e904684ded9eda72c8cb34e9556074e3b6e303a (patch)
tree0ec2ac7051e10a39adcea20924433785ec139cc5
parent32bef80eec204c22a2b37bb6534bc02d24fa68c7 (diff)
downloadqtlocation-mapboxgl-upstream/tmpsantos-prefetch_vector.tar.gz
[core] Enable prefetching for vector tilesupstream/tmpsantos-prefetch_vector
Was not enabled because of label flickering.
-rw-r--r--src/mbgl/renderer/tile_pyramid.cpp13
1 files changed, 5 insertions, 8 deletions
diff --git a/src/mbgl/renderer/tile_pyramid.cpp b/src/mbgl/renderer/tile_pyramid.cpp
index 5b1e621743..670e1daa49 100644
--- a/src/mbgl/renderer/tile_pyramid.cpp
+++ b/src/mbgl/renderer/tile_pyramid.cpp
@@ -99,15 +99,12 @@ void TilePyramid::update(const std::vector<Immutable<style::Layer::Impl>>& layer
// Make sure we're not reparsing overzoomed raster tiles.
if (type == SourceType::Raster) {
tileZoom = idealZoom;
+ }
- // FIXME: Prefetching is only enabled for raster
- // tiles until we fix #7026.
-
- // Request lower zoom level tiles (if configure to do so) in an attempt
- // to show something on the screen faster at the cost of a little of bandwidth.
- if (parameters.prefetchZoomDelta) {
- panZoom = std::max<int32_t>(tileZoom - parameters.prefetchZoomDelta, zoomRange.min);
- }
+ // Request lower zoom level tiles (if configure to do so) in an attempt
+ // to show something on the screen faster at the cost of a little of bandwidth.
+ if (parameters.prefetchZoomDelta) {
+ panZoom = std::max<int32_t>(tileZoom - parameters.prefetchZoomDelta, zoomRange.min);
if (panZoom < tileZoom) {
panTiles = util::tileCover(parameters.transformState, panZoom);