diff options
author | Langston Smith <langston.smith@mapbox.com> | 2018-01-04 11:15:50 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-01-04 11:15:50 -0800 |
commit | 2ea955d2751ba6459f99a0695e53505c0a11702b (patch) | |
tree | f54450918b634a2eea1bd2c4ebc671bf1bb06106 /src/mbgl/annotation/shape_annotation_impl.cpp | |
parent | f2ec6ae326bad79fea2b06a21151a2835522572a (diff) | |
parent | c62b0af24fc76b4bb2eb34100611dd3ee9ee5536 (diff) | |
download | qtlocation-mapboxgl-upstream/ls-android-readme-tweaks.tar.gz |
Merge branch 'master' into ls-android-readme-tweaksupstream/ls-android-readme-tweaks
Diffstat (limited to 'src/mbgl/annotation/shape_annotation_impl.cpp')
-rw-r--r-- | src/mbgl/annotation/shape_annotation_impl.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/mbgl/annotation/shape_annotation_impl.cpp b/src/mbgl/annotation/shape_annotation_impl.cpp index 0c1a631ad8..715dce484e 100644 --- a/src/mbgl/annotation/shape_annotation_impl.cpp +++ b/src/mbgl/annotation/shape_annotation_impl.cpp @@ -1,5 +1,6 @@ #include <mbgl/annotation/shape_annotation_impl.hpp> #include <mbgl/annotation/annotation_tile.hpp> +#include <mbgl/annotation/annotation_manager.hpp> #include <mbgl/tile/tile_id.hpp> #include <mbgl/math/wrap.hpp> #include <mbgl/math/clamp.hpp> @@ -12,10 +13,9 @@ 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("com.mapbox.annotations.shape." + util::toString(id)) { + layerID(AnnotationManager::ShapeLayerID + util::toString(id)) { } void ShapeAnnotationImpl::updateTileData(const CanonicalTileID& tileID, AnnotationTileData& data) { @@ -27,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; |