summaryrefslogtreecommitdiff
path: root/src/mbgl/style/layers/line_layer_impl.hpp
blob: 8c8c7d053b96921f28b5c3a7292e85411d666f9b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#pragma once

#include <mbgl/style/layer_impl.hpp>
#include <mbgl/style/layers/line_layer.hpp>
#include <mbgl/style/layers/line_layer_properties.hpp>

namespace mbgl {
namespace style {

class LineLayer::Impl : public Layer::Impl {
public:
    std::unique_ptr<Layer> clone() const override;
    std::unique_ptr<Layer> cloneRef(const std::string& id) const override;

    void cascade(const CascadeParameters&) override;
    bool evaluate(const PropertyEvaluationParameters&) override;

    std::unique_ptr<Bucket> createBucket(BucketParameters&, const GeometryTileLayer&) const override;

    float getQueryRadius() const override;
    bool queryIntersectsGeometry(
            const GeometryCoordinates& queryGeometry,
            const GeometryCollection& geometry,
            const float bearing,
            const float pixelsToTileUnits) const override;

    LineLayoutProperties layout;
    LinePaintProperties paint;

    // Special case
    float dashLineWidth = 1;

private:
    float getLineWidth() const;
};

} // namespace style
} // namespace mbgl