From dc7b1dd34fcea40e07d1a2831efee20132fbb4ab Mon Sep 17 00:00:00 2001 From: Mikhail Pozdnyakov Date: Tue, 21 Apr 2020 18:27:58 +0300 Subject: [core] Source::setVolatile enables Resource::StoragePolicy::Volatile for tiles --- src/mbgl/renderer/tile_pyramid.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/mbgl/renderer') diff --git a/src/mbgl/renderer/tile_pyramid.cpp b/src/mbgl/renderer/tile_pyramid.cpp index 9d1c8a89b8..bd22dd81cc 100644 --- a/src/mbgl/renderer/tile_pyramid.cpp +++ b/src/mbgl/renderer/tile_pyramid.cpp @@ -93,6 +93,7 @@ void TilePyramid::update(const std::vector>& l const optional& sourcePrefetchZoomDelta = sourceImpl.getPrefetchZoomDelta(); const optional& maxParentTileOverscaleFactor = sourceImpl.getMaxOverscaleFactorForParentTiles(); const Duration minimumUpdateInterval = sourceImpl.getMinimumTileUpdateInterval(); + const bool isVolatile = sourceImpl.isVolatile(); std::vector idealTiles; std::vector panTiles; @@ -132,7 +133,7 @@ void TilePyramid::update(const std::vector>& l auto retainTileFn = [&](Tile& tile, TileNecessity necessity) -> void { if (retain.emplace(tile.id).second) { - tile.setUpdateParameters({minimumUpdateInterval}); + tile.setUpdateParameters({minimumUpdateInterval, isVolatile}); tile.setNecessity(necessity); } -- cgit v1.2.1