MapLibre Native Core
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
layer_properties.hpp
Go to the documentation of this file.
1 #pragma once
2 #include <mbgl/style/layer_impl.hpp>
3 
4 namespace mbgl {
5 
6 namespace style {
7 
14 public:
15  virtual ~LayerProperties() = default;
17  virtual unsigned long constantsMask() const { return 0u; }
20  uint8_t renderPasses = 0u;
21 
22 protected:
24 };
25 
26 template <class Derived>
27 inline const auto& getEvaluated(const Immutable<LayerProperties>& properties) {
28  return static_cast<const Derived&>(*properties).evaluated;
29 }
30 
31 template <class Derived>
32 inline const auto& getCrossfade(const Immutable<LayerProperties>& properties) {
33  return static_cast<const Derived&>(*properties).crossfade;
34 }
35 
36 } // namespace style
37 } // namespace mbgl
An interface, wrapping evaluated layer properties.
virtual ~LayerProperties()=default
LayerProperties(Immutable< Layer::Impl > impl)
Immutable< Layer::Impl > baseImpl
uint8_t renderPasses
Contains render passes used by the renderer, see mbgl::RenderPass.
virtual unsigned long constantsMask() const
Returns constants mask for the data-driven properties.
const auto & getEvaluated(const Immutable< LayerProperties > &properties)
const auto & getCrossfade(const Immutable< LayerProperties > &properties)
Definition: actor.hpp:15
Definition: tile_id.hpp:256