diff options
author | Ivo van Dongen <info@ivovandongen.nl> | 2017-04-21 09:19:47 -0700 |
---|---|---|
committer | Ivo van Dongen <ivovandongen@users.noreply.github.com> | 2017-04-25 17:23:54 -0700 |
commit | 3c175adf30546fe58713b8fed29ac35a85e150be (patch) | |
tree | 5666e9bcf311ed1b86a13444e50dc7a030c10da9 /src/mbgl/layout | |
parent | ea8ec38df156c6683c886253dbb1f6bc828686ff (diff) | |
download | qtlocation-mapboxgl-3c175adf30546fe58713b8fed29ac35a85e150be.tar.gz |
[core] split off render layers
Diffstat (limited to 'src/mbgl/layout')
-rw-r--r-- | src/mbgl/layout/symbol_layout.cpp | 17 | ||||
-rw-r--r-- | src/mbgl/layout/symbol_layout.hpp | 9 |
2 files changed, 13 insertions, 13 deletions
diff --git a/src/mbgl/layout/symbol_layout.cpp b/src/mbgl/layout/symbol_layout.cpp index 0b05d4f5e1..9aca316a00 100644 --- a/src/mbgl/layout/symbol_layout.cpp +++ b/src/mbgl/layout/symbol_layout.cpp @@ -3,8 +3,8 @@ #include <mbgl/layout/clip_lines.hpp> #include <mbgl/renderer/symbol_bucket.hpp> #include <mbgl/style/filter_evaluator.hpp> -#include <mbgl/style/bucket_parameters.hpp> -#include <mbgl/style/layers/symbol_layer.hpp> +#include <mbgl/renderer/bucket_parameters.hpp> +#include <mbgl/renderer/render_symbol_layer.hpp> #include <mbgl/style/layers/symbol_layer_impl.hpp> #include <mbgl/sprite/sprite_atlas.hpp> #include <mbgl/text/get_anchors.hpp> @@ -22,6 +22,7 @@ #include <mbgl/math/log2.hpp> #include <mbgl/util/platform.hpp> #include <mbgl/util/logging.hpp> +#include <mbgl/tile/geometry_tile_data.hpp> #include <mapbox/polylabel.hpp> @@ -38,7 +39,7 @@ static bool has(const style::SymbolLayoutProperties::PossiblyEvaluated& layout) } SymbolLayout::SymbolLayout(const BucketParameters& parameters, - const std::vector<const Layer*>& layers, + const std::vector<const RenderLayer*>& layers, const GeometryTileLayer& sourceLayer, IconDependencies& iconDependencies, uintptr_t _spriteAtlasMapIndex, @@ -51,11 +52,11 @@ SymbolLayout::SymbolLayout(const BucketParameters& parameters, spriteAtlasMapIndex(_spriteAtlasMapIndex), tileSize(util::tileSize * overscaling), tilePixelRatio(float(util::EXTENT) / tileSize), - textSize(layers.at(0)->as<SymbolLayer>()->impl->layout.unevaluated.get<TextSize>()), - iconSize(layers.at(0)->as<SymbolLayer>()->impl->layout.unevaluated.get<IconSize>()) + textSize(layers.at(0)->as<RenderSymbolLayer>()->impl->layout.unevaluated.get<TextSize>()), + iconSize(layers.at(0)->as<RenderSymbolLayer>()->impl->layout.unevaluated.get<IconSize>()) { - const SymbolLayer::Impl& leader = *layers.at(0)->as<SymbolLayer>()->impl; + const SymbolLayer::Impl& leader = *layers.at(0)->as<RenderSymbolLayer>()->impl; layout = leader.layout.evaluate(PropertyEvaluationParameters(zoom)); @@ -89,8 +90,8 @@ SymbolLayout::SymbolLayout(const BucketParameters& parameters, for (const auto& layer : layers) { layerPaintProperties.emplace(layer->getID(), std::make_pair( - layer->as<SymbolLayer>()->impl->iconPaintProperties(), - layer->as<SymbolLayer>()->impl->textPaintProperties() + layer->as<RenderSymbolLayer>()->iconPaintProperties(), + layer->as<RenderSymbolLayer>()->textPaintProperties() )); } diff --git a/src/mbgl/layout/symbol_layout.hpp b/src/mbgl/layout/symbol_layout.hpp index f49f93eaf1..55e4098451 100644 --- a/src/mbgl/layout/symbol_layout.hpp +++ b/src/mbgl/layout/symbol_layout.hpp @@ -15,21 +15,20 @@ namespace mbgl { -class GeometryTileLayer; +class BucketParameters; class CollisionTile; class SymbolBucket; class Anchor; +class RenderLayer; namespace style { -class BucketParameters; class Filter; -class Layer; } // namespace style class SymbolLayout { public: - SymbolLayout(const style::BucketParameters&, - const std::vector<const style::Layer*>&, + SymbolLayout(const BucketParameters&, + const std::vector<const RenderLayer*>&, const GeometryTileLayer&, IconDependencies&, uintptr_t, |