mapbox / tile-cover

Generate the minimum number of tiles to cover a geojson geometry
MIT License
189 stars 40 forks source link

Features that cross the dateline #65

Closed rclark closed 9 years ago

rclark commented 9 years ago

If you calculate the tile-cover for a feature that with X coordinates > 180, you can end up with bogus tile coordinates, for example [260,52,8]. Would it be worth a PR that tries to coerce to coordinates within the right limits (in this example, [4,52,8])? Or is it better to handle this outcome in the downstream app?

cc @morganherlocker

mourner commented 9 years ago

I would expect this to be handled on the downstream app, since the wrapping is lossy (e.g. you can end up with coordinates you don't know what to do with).

rclark commented 9 years ago

:+1: to managing this downstream.