Open dnomadb opened 6 years ago
The source's resolution is converted to meters here: https://github.com/mapbox/mapnik-omnivore/blob/29ead3673df622c773f334ec555d3d749a9c673f/lib/raster.js#L162
meters
But then the resolution in native units is then used to calculate the max zoom: https://github.com/mapbox/mapnik-omnivore/blob/29ead3673df622c773f334ec555d3d749a9c673f/lib/raster.js#L173
This results in incorrect maxzoom selection for non-meter source data, as the thresholds for zoom levels are defined in mercator meters. This can be fixed by simply swapping out _this.details.pixelSize[0] for pixelSize[0] above.
_this.details.pixelSize[0]
pixelSize[0]
cc @pratikyadav
The source's resolution is converted to
meters
here: https://github.com/mapbox/mapnik-omnivore/blob/29ead3673df622c773f334ec555d3d749a9c673f/lib/raster.js#L162But then the resolution in native units is then used to calculate the max zoom: https://github.com/mapbox/mapnik-omnivore/blob/29ead3673df622c773f334ec555d3d749a9c673f/lib/raster.js#L173
This results in incorrect maxzoom selection for non-meter source data, as the thresholds for zoom levels are defined in mercator meters. This can be fixed by simply swapping out
_this.details.pixelSize[0]
forpixelSize[0]
above.cc @pratikyadav