Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

Commit

Permalink
[core] Fix issues from rebase
Browse files Browse the repository at this point in the history
  • Loading branch information
ahk committed Mar 10, 2020
1 parent 2e1e476 commit 2bf701b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
12 changes: 7 additions & 5 deletions src/mbgl/layout/circle_layout.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -68,19 +68,20 @@ class CircleLayout : public Layout {

bool hasDependencies() const override { return hasPattern; }

void createBucket(const ImagePositions&,
virtual void createBucket(const ImagePositions&,
std::unique_ptr<FeatureIndex>& featureIndex,
std::unordered_map<std::string, LayerRenderData>& renderData,
const bool,
const bool) override {
const bool,
const CanonicalTileID& canonical) override {
auto bucket = std::make_shared<CircleBucket>(layerPropertiesMap, mode, zoom);

for (auto& circleFeature : features) {
const auto i = circleFeature.i;
std::unique_ptr<GeometryTileFeature> feature = std::move(circleFeature.feature);
const GeometryCollection& geometries = feature->getGeometries();

addCircle(*bucket, *feature, geometries, i, circleFeature.sortKey);
addCircle(*bucket, *feature, geometries, i, circleFeature.sortKey, canonical);
featureIndex->insert(geometries, i, sourceLayerID, bucketLeaderID);
}
if (bucket->hasData()) {
Expand All @@ -95,7 +96,8 @@ class CircleLayout : public Layout {
const GeometryTileFeature& feature,
const GeometryCollection& geometry,
std::size_t featureIndex,
float sortKey) {
float sortKey,
const CanonicalTileID& canonical) {
constexpr const uint16_t vertexLength = 4;

auto& segments = bucket.segments;
Expand Down Expand Up @@ -148,7 +150,7 @@ class CircleLayout : public Layout {
}

for (auto& pair : bucket.paintPropertyBinders) {
pair.second.populateVertexVectors(feature, vertices.elements(), featureIndex, {}, {});
pair.second.populateVertexVectors(feature, vertices.elements(), featureIndex, {}, {}, canonical);
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/mbgl/renderer/layers/render_circle_layer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ void RenderCircleLayer::render(PaintParameters& parameters) {
return;
}

const bool sortFeaturesByKey = !impl(baseImpl).layout.get<CircleSortKey>().isUndefined();
const bool sortFeaturesByKey = !impl_cast(baseImpl).layout.get<CircleSortKey>().isUndefined();
std::multiset<RenderableSegment> renderableSegments{};

for (const RenderTile& tile : *renderTiles) {
Expand Down

0 comments on commit 2bf701b

Please sign in to comment.