Bounds where left > right
Nobody has claimed this yet.
- Dominant language
- No language data
- Stars
- 296
- Forks
- 51
- PR merge metrics
- No merged PRs in 30d
Description
If I have a tile source that goes from west of Australia to ~east~ right of New Zealand, I would expect to be able to write the `bounds` as:
```
[90, -70, -170, 70] // left, bottom, right, top
```
Unfortunately this doesn't seem to produce a valid tilejson (in Mapbox GL JS no tiles are requested for this source).
It's not possible to workaround this by just switching the left/right longitudes, because that represents all the negative space where there is no data. Leaving the only possible workaround to specify the entire -180°/180° range:
```
[-180, -70, 180, 70],
```
This results in a lot of unnecessary requests to the server that just result in 404 responses, and also prevents the ability to draw a border around the bounds. However it works from a user perspective because all data is shown.
Extending the bounds beyond 180° to 190° (below) results in appropriate requests, but nothing between 180° and 190°(with Mapbox GL JS as the implementation).
```
[90, -70, 190, 70]
```
Should the spec be able to support bounds where the left longitude is greater than the right longitude?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Review the TileJSON bounds definition and the Mapbox GL JS behavior described in this issue, comparing the examples that cross the antimeridian. Done means the specification explicitly resolves whether left > right is valid and documents the resulting behavior or workaround.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, json
- Domain
- documentation
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100