summaryrefslogtreecommitdiff
path: root/src/mbgl/annotation/shape_annotation_impl.cpp
diff options
context:
space:
mode:
authorKonstantin Käfer <mail@kkaefer.com>2017-12-22 16:27:31 +0100
committerKonstantin Käfer <mail@kkaefer.com>2018-01-02 20:17:15 +0100
commit498dbf27b9fc49254471f6251349bb14f25a150e (patch)
tree7a44c410c780ade45a7d1b27d82a0c87827b7bc0 /src/mbgl/annotation/shape_annotation_impl.cpp
parent33faa3811e1833ef99e7e9b5be835793c81892f7 (diff)
downloadqtlocation-mapboxgl-498dbf27b9fc49254471f6251349bb14f25a150e.tar.gz
[core] don't tie Annotation geometries to Map maxzoom
Instead, geometry generation via GeoJSONVT is now bound to the hardcoded limit of the annotation tile source.
Diffstat (limited to 'src/mbgl/annotation/shape_annotation_impl.cpp')
-rw-r--r--src/mbgl/annotation/shape_annotation_impl.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/mbgl/annotation/shape_annotation_impl.cpp b/src/mbgl/annotation/shape_annotation_impl.cpp
index 9288159b6a..715dce484e 100644
--- a/src/mbgl/annotation/shape_annotation_impl.cpp
+++ b/src/mbgl/annotation/shape_annotation_impl.cpp
@@ -13,9 +13,8 @@ namespace mbgl {
using namespace style;
namespace geojsonvt = mapbox::geojsonvt;
-ShapeAnnotationImpl::ShapeAnnotationImpl(const AnnotationID id_, const uint8_t maxZoom_)
+ShapeAnnotationImpl::ShapeAnnotationImpl(const AnnotationID id_)
: id(id_),
- maxZoom(maxZoom_),
layerID(AnnotationManager::ShapeLayerID + util::toString(id)) {
}
@@ -28,7 +27,9 @@ void ShapeAnnotationImpl::updateTileData(const CanonicalTileID& tileID, Annotati
return Feature { std::move(geom) };
}));
mapbox::geojsonvt::Options options;
- options.maxZoom = maxZoom;
+ // The annotation source is currently hard coded to maxzoom 16, so we're topping out at z16
+ // here as well.
+ options.maxZoom = 16;
options.buffer = 255u;
options.extent = util::EXTENT;
options.tolerance = baseTolerance;