[openstreetmap/openstreetmap-website] Change zoom precision function (PR #5084)

Anton Khorev notifications at github.com
Sat Aug 17 08:52:04 UTC 2024


If you don't mind raising something to a variable power* and taking a logarithm of the result, here's a more readable version.

\* could have used `pixels = 1 << (8 + zoom)`, not sure if it's more clear

-- 
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/5084#issuecomment-2294798344
You are receiving this because you are subscribed to this thread.

Message ID: <openstreetmap/openstreetmap-website/pull/5084/c2294798344 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20240817/9e8a65f7/attachment.htm>


More information about the rails-dev mailing list