Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement SymbolStyleLayer#queryRadius() (queryRenderedFeatures fix) #6298

Closed
ChrisLoer opened this issue Mar 7, 2018 · 2 comments
Closed
Labels

Comments

@ChrisLoer
Copy link
Contributor

The current implementation just returns "0":

queryRadius(): number {
return 0;
}

This means that symbols that "bleed over" into the tile next to them won't show up in a queryRenderedFeatures query that intersects their geometry but doesn't intersect their original tile. This wasn't much of an issue before #5150 because the symbol would generally be included in both tile's collision indices.

Once #6036 goes in, we'll have an upper bound on the amount of "pitch scaling" that can apply to text. We can implement queryRadius here by going through all the symbols in the bucket and keeping the max dimensions.

/cc @ansis

@ChrisLoer
Copy link
Contributor Author

Actually, I think I'd rather fix this with #5475

ChrisLoer added a commit that referenced this issue Apr 11, 2018
This fixes issue #5475/#6298, so that symbols that bleed over tile boundaries don't get missed.
Under the hood, there are (I hope) some good simplifications:
 - No round-tripping of viewport query coordinates through tile space
 - No more need to merge duplicate results from the same symbol showing up in multiple tiles
 - All querying-related data can now be indexed with a bucket instance id and a feature index.
 - CrossTileSymbolIndex manages lifetime of data needed for querying symbols, Tile is now only responsible for "latest" data
 - CollisionBoxArray no longer involved in querying at all
ChrisLoer added a commit that referenced this issue Apr 11, 2018
This fixes issue #5475/#6298, so that symbols that bleed over tile boundaries don't get missed.
Under the hood, there are (I hope) some good simplifications:
 - No round-tripping of viewport query coordinates through tile space
 - No more need to merge duplicate results from the same symbol showing up in multiple tiles
 - All querying-related data can now be indexed with a bucket instance id and a feature index.
 - CrossTileSymbolIndex manages lifetime of data needed for querying symbols, Tile is now only responsible for "latest" data
 - CollisionBoxArray no longer involved in querying at all
@ChrisLoer ChrisLoer mentioned this issue Apr 11, 2018
5 tasks
ChrisLoer added a commit that referenced this issue Apr 11, 2018
This fixes issue #5475/#6298, so that symbols that bleed over tile boundaries don't get missed.
Under the hood, there are (I hope) some good simplifications:
 - No round-tripping of viewport query coordinates through tile space
 - No more need to merge duplicate results from the same symbol showing up in multiple tiles
 - All querying-related data can now be indexed with a bucket instance id and a feature index.
 - CrossTileSymbolIndex manages lifetime of data needed for querying symbols, Tile is now only responsible for "latest" data
 - CollisionBoxArray no longer involved in querying at all
ChrisLoer added a commit that referenced this issue Apr 12, 2018
Addresses hover flicker from issues #5887 and #5506.
Also fixes issue #5475/#6298, so that symbols that bleed over tile boundaries don't get missed. Under the hood, there are some good simplifications:
 - No round-tripping of viewport query coordinates through tile space
 - No more need to merge duplicate results from the same symbol showing up in multiple tiles
 - All querying-related data can now be indexed with a bucket instance id and a feature index
 - `Placement` now manages lifetime of any data needed to query against its CollisionIndex
 - CollisionBoxArray no longer involved in querying at all
ChrisLoer added a commit that referenced this issue Apr 12, 2018
Addresses hover flicker from issues #5887 and #5506.
Also fixes issue #5475/#6298, so that symbols that bleed over tile boundaries don't get missed. Under the hood, there are some good simplifications:
 - No round-tripping of viewport query coordinates through tile space
 - No more need to merge duplicate results from the same symbol showing up in multiple tiles
 - All querying-related data can now be indexed with a bucket instance id and a feature index
 - `Placement` now manages lifetime of any data needed to query against its CollisionIndex
 - CollisionBoxArray no longer involved in querying at all
ChrisLoer added a commit that referenced this issue Apr 13, 2018
Addresses hover flicker from issues #5887 and #5506.
Also fixes issue #5475/#6298, so that symbols that bleed over tile boundaries don't get missed. Under the hood, there are some good simplifications:
 - No round-tripping of viewport query coordinates through tile space
 - No more need to merge duplicate results from the same symbol showing up in multiple tiles
 - All querying-related data can now be indexed with a bucket instance id and a feature index
 - `Placement` now manages lifetime of any data needed to query against its CollisionIndex
 - CollisionBoxArray no longer involved in querying at all
ChrisLoer added a commit that referenced this issue Apr 13, 2018
Addresses hover flicker from issues #5887 and #5506.
Also fixes issue #5475/#6298, so that symbols that bleed over tile boundaries don't get missed. Under the hood, there are some good simplifications:
 - No round-tripping of viewport query coordinates through tile space
 - No more need to merge duplicate results from the same symbol showing up in multiple tiles
 - All querying-related data can now be indexed with a bucket instance id and a feature index
 - `Placement` now manages lifetime of any data needed to query against its CollisionIndex
 - CollisionBoxArray no longer involved in querying at all
@ChrisLoer
Copy link
Contributor Author

Fixed in #6497: queryRadius == 0 is now correct.

ChrisLoer added a commit that referenced this issue May 18, 2018
Addresses hover flicker from issues #5887 and #5506.
Also fixes issue #5475/#6298, so that symbols that bleed over tile boundaries don't get missed. Under the hood, there are some good simplifications:
 - No round-tripping of viewport query coordinates through tile space
 - No more need to merge duplicate results from the same symbol showing up in multiple tiles
 - All querying-related data can now be indexed with a bucket instance id and a feature index
 - `Placement` now manages lifetime of any data needed to query against its CollisionIndex
 - CollisionBoxArray no longer involved in querying at all
ChrisLoer added a commit that referenced this issue May 18, 2018
Addresses hover flicker from issues #5887 and #5506.
Also fixes issue #5475/#6298, so that symbols that bleed over tile boundaries don't get missed. Under the hood, there are some good simplifications:
 - No round-tripping of viewport query coordinates through tile space
 - No more need to merge duplicate results from the same symbol showing up in multiple tiles
 - All querying-related data can now be indexed with a bucket instance id and a feature index
 - `Placement` now manages lifetime of any data needed to query against its CollisionIndex
 - CollisionBoxArray no longer involved in querying at all
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant