#include #include #include #include namespace mbgl { using namespace style; FillAnnotationImpl::FillAnnotationImpl(AnnotationID id_, FillAnnotation annotation_, uint8_t maxZoom_) : ShapeAnnotationImpl(id_, maxZoom_), annotation(std::move(annotation_)) { } void FillAnnotationImpl::updateStyle(Style& style) const { if (style.getLayer(layerID)) return; std::unique_ptr layer = std::make_unique(layerID, AnnotationManager::SourceID); layer->setSourceLayer(layerID); layer->setFillOpacity(annotation.opacity); layer->setFillColor(annotation.color); layer->setFillOutlineColor(annotation.outlineColor); style.addLayer(std::move(layer), AnnotationManager::PointLayerID); } const ShapeAnnotationGeometry& FillAnnotationImpl::geometry() const { return annotation.geometry; } } // namespace mbgl