diff options
author | John Firebaugh <john.firebaugh@gmail.com> | 2017-04-27 14:33:00 -0700 |
---|---|---|
committer | John Firebaugh <john.firebaugh@gmail.com> | 2017-05-03 08:30:17 -0700 |
commit | d5f4d0f05fcb8490984649d78d6c026f87a77f4e (patch) | |
tree | dea3b08a7c1d6f29a0f75d37cb2ee54a2429e6b4 /src/mbgl/style/light_impl.hpp | |
parent | 6c7730ee7c2d9e63df526965bb511b2f43ee82b7 (diff) | |
download | qtlocation-mapboxgl-d5f4d0f05fcb8490984649d78d6c026f87a77f4e.tar.gz |
[core] Move render-related sources out of style directory/namespace
Moves the following to the renderer directory and out of the style namespace:
* CascadeParameters
* PropertyEvaluationParameters
* UpdateParameters
* PropertyEvaluator
* DataDrivenPropertyEvaluator
* CrossFadedPropertyEvaluator
* PaintPropertyBinder
* PaintProperyStatistics
* PossiblyEvaluatedPropertyValue
* TransitioningLight
* EvaluatedLight
Diffstat (limited to 'src/mbgl/style/light_impl.hpp')
-rw-r--r-- | src/mbgl/style/light_impl.hpp | 74 |
1 files changed, 0 insertions, 74 deletions
diff --git a/src/mbgl/style/light_impl.hpp b/src/mbgl/style/light_impl.hpp deleted file mode 100644 index d1825090fc..0000000000 --- a/src/mbgl/style/light_impl.hpp +++ /dev/null @@ -1,74 +0,0 @@ -#pragma once - -#include <mbgl/style/light.hpp> -#include <mbgl/style/transitioning_property.hpp> -#include <mbgl/style/cascade_parameters.hpp> -#include <mbgl/style/property_evaluator.hpp> -#include <mbgl/style/property_evaluation_parameters.hpp> -#include <mbgl/util/ignore.hpp> - -namespace mbgl { -namespace style { - -template <class TypeList> -class Transitioning; - -template <class... Ps> -class Transitioning<TypeList<Ps...>> : public IndexedTuple< - TypeList<Ps...>, - TypeList<TransitioningProperty<typename Ps::ValueType>...>> -{ -private: - using Properties = TypeList<Ps...>; - using Raw = IndexedTuple<Properties, Properties>; - using Super = IndexedTuple< - TypeList<Ps...>, - TypeList<TransitioningProperty<typename Ps::ValueType>...>>; - -public: - Transitioning() = default; - Transitioning(const Raw& raw, Transitioning&& prior, const CascadeParameters& params) - : Super { - TransitioningProperty<typename Ps::ValueType>( - raw.template get<Ps>().value, - std::move(prior.template get<Ps>()), - raw.template get<Ps>().transition.reverseMerge(params.transition), - params.now)... - } {} - - bool hasTransition() const { - bool result = false; - util::ignore({ result |= this->template get<Ps>().hasTransition()... }); - return result; - } -}; - -template <class TypeList> -class Evaluated; - -template <class... Ps> -class Evaluated<TypeList<Ps...>> : public IndexedTuple< - TypeList<Ps...>, - TypeList<typename Ps::Type...>> -{ -private: - using Properties = TypeList<Ps...>; - using TransitioningPs = Transitioning<Properties>; - using Super = IndexedTuple< - TypeList<Ps...>, - TypeList<typename Ps::Type...>>; - -public: - Evaluated() = default; - Evaluated(TransitioningPs& transitioning, const PropertyEvaluationParameters& params) - : Super { - transitioning.template get<Ps>() - .evaluate(PropertyEvaluator<typename Ps::Type>(params, Ps::defaultValue()), params.now)... - } {} -}; - -using TransitioningLight = Transitioning<LightProperties>; -using EvaluatedLight = Evaluated<LightProperties>; - -} // namespace style -} // namespace mbgl |