summaryrefslogtreecommitdiff
path: root/src/mbgl/layer/line_layer.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mbgl/layer/line_layer.hpp')
-rw-r--r--src/mbgl/layer/line_layer.hpp64
1 files changed, 0 insertions, 64 deletions
diff --git a/src/mbgl/layer/line_layer.hpp b/src/mbgl/layer/line_layer.hpp
deleted file mode 100644
index 60bd9fad55..0000000000
--- a/src/mbgl/layer/line_layer.hpp
+++ /dev/null
@@ -1,64 +0,0 @@
-#pragma once
-
-#include <mbgl/style/style_layer.hpp>
-#include <mbgl/style/layout_property.hpp>
-#include <mbgl/style/paint_property.hpp>
-
-namespace mbgl {
-
-class LineLayoutProperties {
-public:
- LayoutProperty<LineCapType> lineCap { LineCapType::Butt };
- LayoutProperty<LineJoinType> lineJoin { LineJoinType::Miter };
- LayoutProperty<float> lineMiterLimit { 2.0f };
- LayoutProperty<float> lineRoundLimit { 1.0f };
-};
-
-class LinePaintProperties {
-public:
- PaintProperty<float> lineOpacity { 1.0f };
- PaintProperty<Color> lineColor { {{ 0, 0, 0, 1 }} };
- PaintProperty<std::array<float, 2>> lineTranslate { {{ 0, 0 }} };
- PaintProperty<TranslateAnchorType> lineTranslateAnchor { TranslateAnchorType::Map };
- PaintProperty<float> lineWidth { 1 };
- PaintProperty<float> lineGapWidth { 0 };
- PaintProperty<float> lineBlur { 0 };
- PaintProperty<float> lineOffset { 0 };
- PaintProperty<std::vector<float>, CrossFadedFunctionEvaluator> lineDasharray { {} };
- PaintProperty<std::string, CrossFadedFunctionEvaluator> linePattern { "" };
-};
-
-class LineLayer : public StyleLayer {
-public:
- LineLayer() : StyleLayer(Type::Line) {}
- std::unique_ptr<StyleLayer> clone() const override;
-
- void parseLayout(const JSValue&) override;
- void parsePaints(const JSValue&) override;
-
- void cascade(const StyleCascadeParameters&) override;
- bool recalculate(const StyleCalculationParameters&) override;
-
- std::unique_ptr<Bucket> createBucket(StyleBucketParameters&) const override;
-
- float getQueryRadius() const override;
- bool queryIntersectsGeometry(
- const GeometryCollection& queryGeometry,
- const GeometryCollection& geometry,
- const float bearing,
- const float pixelsToTileUnits) const override;
-
- LineLayoutProperties layout;
- LinePaintProperties paint;
-
- float dashLineWidth = 1;
-private:
- float getLineWidth() const;
-};
-
-template <>
-inline bool StyleLayer::is<LineLayer>() const {
- return type == Type::Line;
-}
-
-} // namespace mbgl