summaryrefslogtreecommitdiff
path: root/src/mbgl/renderer/render_light.hpp
blob: f13f925318d47793914b0719ea1477d4f32998c0 (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
#pragma once

#include <mbgl/style/light_impl.hpp>
#include <mbgl/util/immutable.hpp>

namespace mbgl {

class TransitionParameters;
class PropertyEvaluationParameters;

using TransitioningLight = style::LightProperties::Unevaluated;
using EvaluatedLight     = style::LightProperties::PossiblyEvaluated;

class RenderLight {
public:
    RenderLight(Immutable<style::Light::Impl>);

    void transition(const TransitionParameters&);
    void evaluate(const PropertyEvaluationParameters&);
    bool hasTransition() const;

    const EvaluatedLight& getEvaluated() const;

    Immutable<style::Light::Impl> impl;

private:
    TransitioningLight transitioning;
    EvaluatedLight evaluated;
};

} // namespace mbgl