diff options
author | Alexander Shalamov <alexander.shalamov@mapbox.com> | 2020-03-21 21:55:22 +0200 |
---|---|---|
committer | Alexander Shalamov <alexander.shalamov@mapbox.com> | 2020-04-01 16:18:55 -0400 |
commit | 15f73a06f2048d4b5f0481d54a79f3f349187b11 (patch) | |
tree | 5166ba99751b11d6a994d0f3825332caf04ccd64 /include/mbgl/style | |
parent | 09f7bbcf7c07cc360c933ab1637662397b7db674 (diff) | |
download | qtlocation-mapboxgl-15f73a06f2048d4b5f0481d54a79f3f349187b11.tar.gz |
[core] Add setMaxOverscaleFactorForParentTiles
Diffstat (limited to 'include/mbgl/style')
-rw-r--r-- | include/mbgl/style/source.hpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/include/mbgl/style/source.hpp b/include/mbgl/style/source.hpp index 622c2e42ff..32b15bdf47 100644 --- a/include/mbgl/style/source.hpp +++ b/include/mbgl/style/source.hpp @@ -75,6 +75,20 @@ public: virtual void loadDescription(FileSource&) = 0; void setPrefetchZoomDelta(optional<uint8_t> delta) noexcept; optional<uint8_t> getPrefetchZoomDelta() const noexcept; + + // Sets a limit for how much a parent tile can be overscaled. + // + // When a set of tiles for a current zoom level is being rendered and some of the + // ideal tiles that cover the screen are not yet loaded, parent tile could be + // used instead. This might introduce unwanted rendering side-effects, especially + // for raster tiles that are overscaled multiple times. + // + // For example, an overscale factor of 3 would mean that on zoom level 3, the + // minimum zoom level of a parent tile that could be used in place of an ideal + // tile during rendering would be zoom 0. By default, no limit is set, so any + // parent tile may be used. + void setMaxOverscaleFactorForParentTiles(optional<uint8_t> overscaleFactor) noexcept; + optional<uint8_t> getMaxOverscaleFactorForParentTiles() const noexcept; void dumpDebugLogs() const; virtual bool supportsLayerType(const mbgl::style::LayerTypeInfo*) const = 0; |