Skip to content

Only run placement for first layer per SymbolBucket. - #6550

Merged
ChrisLoer merged 1 commit into
masterfrom
cloer-6548
Apr 23, 2018
Merged

ChrisLoer merged 1 commit into
masterfrom
cloer-6548

Conversation

@ChrisLoer

@ChrisLoer ChrisLoer commented Apr 20, 2018 •

Copy link
Copy Markdown
Contributor

Fixes issue #6548.
Restores behavior from before PR #5150 -- all layers that share the same bucket (and thus same layout properties) share the same placement.
Before this fix, two layers with the same layout properties could collide against each other, and because they shared CrossTileIDs, both layers could end up hidden.

This will also need porting to native.

Launch Checklist

  • briefly describe the changes in this PR
  • write tests for all new functionality
  • post benchmark scores -- nothing stood out in the benchmarks
  • manually test the debug page

/cc @ansis @ryanbaumann

Fixes issue #6548.
Restores behavior from before PR #5150 -- all layers that share the same bucket (and thus same layout properties) share the same placement.
Before this fix, two layers with the same layout properties could collide against each other, and because they shared CrossTileIDs, _both_ layers could end up hidden.
@ChrisLoer
ChrisLoer requested a review from ansis April 20, 2018 23:09

@ansis ansis left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This looks good to me! I put together an alternative pr that at first seemed like a better approach #6556

But now I'm leaning towards this one being better! If you like this approach, merge and close my pr

@ChrisLoer
ChrisLoer merged commit 5f3bdb9 into master Apr 23, 2018
@ChrisLoer
ChrisLoer deleted the cloer-6548 branch April 23, 2018 18:05
ChrisLoer added a commit to mapbox/mapbox-gl-native that referenced this pull request Apr 28, 2018
Native version of mapbox/mapbox-gl-js#6548.
Port of mapbox/mapbox-gl-js#6550.
Prevents symbols that share the same layout properties from colliding against each other.

Bump GL JS pin to get regression test.
Rename "bucketName" -> "bucketLeaderID" to make it clearer what it represents.
ChrisLoer added a commit to mapbox/mapbox-gl-native that referenced this pull request May 3, 2018
Native version of mapbox/mapbox-gl-js#6548.
Port of mapbox/mapbox-gl-js#6550.
Prevents symbols that share the same layout properties from colliding against each other.

Bump GL JS pin to get regression test.
Rename "bucketName" -> "bucketLeaderID" to make it clearer what it represents.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants