diff options
author | Mikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com> | 2020-03-05 17:54:03 +0200 |
---|---|---|
committer | Mikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com> | 2020-03-06 23:46:52 +0200 |
commit | 260148878cc61211473fe0bbff4b460209381b93 (patch) | |
tree | 73ca4d50891c4124bd80a4e9eaae1ede32a3aab7 | |
parent | 42068691c898faf8984bae21fea4f0cfed322d35 (diff) | |
download | qtlocation-mapboxgl-260148878cc61211473fe0bbff4b460209381b93.tar.gz |
[core] CollisionIndex::intercectsTileEdges -> intersectsTileEdges
-rw-r--r-- | src/mbgl/text/collision_index.cpp | 2 | ||||
-rw-r--r-- | src/mbgl/text/collision_index.hpp | 2 | ||||
-rw-r--r-- | src/mbgl/text/placement.cpp | 6 |
3 files changed, 5 insertions, 5 deletions
diff --git a/src/mbgl/text/collision_index.cpp b/src/mbgl/text/collision_index.cpp index a9386d0f9a..ef0358dd6b 100644 --- a/src/mbgl/text/collision_index.cpp +++ b/src/mbgl/text/collision_index.cpp @@ -96,7 +96,7 @@ inline bool CollisionIndex::overlapsTile(const CollisionBoundaries& boundaries, boundaries[1] < tileBoundaries[3] && boundaries[3] > tileBoundaries[1]; } -bool CollisionIndex::intercectsTileEdges(const CollisionBox& box, +bool CollisionIndex::intersectsTileEdges(const CollisionBox& box, Point<float> shift, const mat4& posMatrix, const float textPixelRatio, diff --git a/src/mbgl/text/collision_index.hpp b/src/mbgl/text/collision_index.hpp index 2ed3ab81bc..2effe452d9 100644 --- a/src/mbgl/text/collision_index.hpp +++ b/src/mbgl/text/collision_index.hpp @@ -21,7 +21,7 @@ public: using CollisionGrid = GridIndex<IndexedSubfeature>; explicit CollisionIndex(const TransformState&, MapMode); - bool intercectsTileEdges(const CollisionBox&, + bool intersectsTileEdges(const CollisionBox&, Point<float> shift, const mat4& posMatrix, const float textPixelRatio, diff --git a/src/mbgl/text/placement.cpp b/src/mbgl/text/placement.cpp index 0bc63c3c6a..73a6d9d228 100644 --- a/src/mbgl/text/placement.cpp +++ b/src/mbgl/text/placement.cpp @@ -354,7 +354,7 @@ void Placement::placeSymbolBucket(const BucketPlacementData& params, std::set<ui textBoxes.clear(); if (mapMode == MapMode::Tile && !isFirstAnchor && - collisionIndex.intercectsTileEdges(symbolInstance.textCollisionFeature.boxes.front(), + collisionIndex.intersectsTileEdges(symbolInstance.textCollisionFeature.boxes.front(), shift, posMatrix, pixelRatio, @@ -596,11 +596,11 @@ void Placement::placeSymbolBucket(const BucketPlacementData& params, std::set<ui auto collisionBoxIntersectsTileEdges = [&](const CollisionBox& collisionBox, Point<float> shift) -> bool { bool intersects = - collisionIndex.intercectsTileEdges(collisionBox, shift, renderTile.matrix, pixelRatio, *tileBorders); + collisionIndex.intersectsTileEdges(collisionBox, shift, renderTile.matrix, pixelRatio, *tileBorders); // Check if this symbol intersects the neighbor tile borders. If so, it also shall be placed with priority. for (const auto& neighbor : neightbors) { if (intersects) break; - intersects = collisionIndex.intercectsTileEdges( + intersects = collisionIndex.intersectsTileEdges( collisionBox, shift + neighbor.shift, neighbor.matrix, pixelRatio, neighbor.borders); } return intersects; |