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

[core] [tile mode] placement algorithm must consider icons bounding boxes #16277

Merged
merged 6 commits into from
Mar 6, 2020

Conversation

pozdnyakov
Copy link
Contributor

Tile mode placement algorithm now checks if bounding boxes for both label text and icon are intersecting the edges of the tiles.

Before, it checked only text bounding boxes and thus label icons might have got cut off.

Fixes https://github.com/mapbox/mapbox-gl-native-team/issues/200

@pozdnyakov pozdnyakov added the Core The cross-platform C++ core, aka mbgl label Mar 5, 2020
@pozdnyakov pozdnyakov self-assigned this Mar 5, 2020
@pozdnyakov pozdnyakov marked this pull request as ready for review March 5, 2020 15:54
@pozdnyakov
Copy link
Contributor Author

Link to the render test PR: mapbox/mapbox-gl-js#9382

alexshalamov
alexshalamov previously approved these changes Mar 5, 2020
Copy link
Contributor

@alexshalamov alexshalamov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm, render tests passes locally, right?

src/mbgl/text/placement.cpp Show resolved Hide resolved
@alexshalamov alexshalamov self-requested a review March 5, 2020 18:40
@alexshalamov alexshalamov dismissed their stale review March 5, 2020 19:15

need to check icon-text-fit

Tile mode placement algorithm now checks if bounding boxes for both label text and icon are intersecting the edges of the tiles.

Before, it checked only text bounding boxes and thus label icons might have got cut off.
@pozdnyakov pozdnyakov force-pushed the mikhail_tile_mode_icons_placement branch 2 times, most recently from 0eefa30 to 49b55de Compare March 6, 2020 15:25
so that it includes `tile-mode/streets-v11` test
@pozdnyakov pozdnyakov force-pushed the mikhail_tile_mode_icons_placement branch from 49b55de to fdaaa17 Compare March 6, 2020 15:48
@pozdnyakov pozdnyakov force-pushed the mikhail_tile_mode_icons_placement branch 2 times, most recently from e3d32d0 to b0fa6d7 Compare March 6, 2020 20:34
@pozdnyakov pozdnyakov merged commit 35fc402 into master Mar 6, 2020
@pozdnyakov pozdnyakov deleted the mikhail_tile_mode_icons_placement branch March 6, 2020 21:46
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Core The cross-platform C++ core, aka mbgl
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants