summaryrefslogtreecommitdiff
path: root/src/mbgl/text/placement.hpp
diff options
context:
space:
mode:
authorMikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com>2019-09-13 18:30:48 +0300
committerMikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com>2019-09-19 14:51:32 +0300
commit870f306f680a26d2a4994d46cadb1fd664696396 (patch)
tree89473e1b774365a10103283f13ede7b27a665205 /src/mbgl/text/placement.hpp
parentf997ae00ae960f38d6920a625fcb7237e5909f9c (diff)
downloadqtlocation-mapboxgl-870f306f680a26d2a4994d46cadb1fd664696396.tar.gz
[core] Update buckets in Renderer
Diffstat (limited to 'src/mbgl/text/placement.hpp')
-rw-r--r--src/mbgl/text/placement.hpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mbgl/text/placement.hpp b/src/mbgl/text/placement.hpp
index 1cefaf978c..917cf8bded 100644
--- a/src/mbgl/text/placement.hpp
+++ b/src/mbgl/text/placement.hpp
@@ -100,10 +100,10 @@ public:
class Placement {
public:
- Placement(const TransformState&, MapMode, style::TransitionOptions, const bool crossSourceCollisions, std::unique_ptr<Placement> prevPlacementOrNull = nullptr);
+ Placement(const TransformState&, MapMode, style::TransitionOptions, const bool crossSourceCollisions, std::shared_ptr<const Placement> prevPlacement = nullptr);
void placeLayer(const RenderLayer&, const mat4&, bool showCollisionBoxes);
void commit(TimePoint, const double zoom);
- void updateLayerBuckets(const RenderLayer&, const TransformState&, bool updateOpacities);
+ void updateLayerBuckets(const RenderLayer&, const TransformState&, bool updateOpacities) const;
float symbolFadeChange(TimePoint now) const;
bool hasTransitions(TimePoint now) const;
@@ -147,7 +147,7 @@ private:
std::unordered_map<uint32_t, RetainedQueryData> retainedQueryData;
CollisionGroups collisionGroups;
- std::unique_ptr<Placement> prevPlacement;
+ mutable std::shared_ptr<const Placement> prevPlacement;
optional<Duration> maximumUpdatePeriod;
// Used for debug purposes.