{"action":"created","issue":{"url":"https://api.github.com/repos/mapbox/mapbox-gl-js/issues/5658","repository_url":"https://api.github.com/repos/mapbox/mapbox-gl-js","labels_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/issues/5658/labels{/name}","comments_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/issues/5658/comments","events_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/issues/5658/events","html_url":"https://github.com/mapbox/mapbox-gl-js/issues/5658","id":273143457,"number":5658,"title":"Map-scale to zoom-level mapping","user":{"login":"mnboos","id":22575883,"avatar_url":"https://avatars1.githubusercontent.com/u/22575883?v=4","gravatar_id":"","url":"https://api.github.com/users/mnboos","html_url":"https://github.com/mnboos","followers_url":"https://api.github.com/users/mnboos/followers","following_url":"https://api.github.com/users/mnboos/following{/other_user}","gists_url":"https://api.github.com/users/mnboos/gists{/gist_id}","starred_url":"https://api.github.com/users/mnboos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mnboos/subscriptions","organizations_url":"https://api.github.com/users/mnboos/orgs","repos_url":"https://api.github.com/users/mnboos/repos","events_url":"https://api.github.com/users/mnboos/events{/privacy}","received_events_url":"https://api.github.com/users/mnboos/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2017-11-11T12:52:02Z","updated_at":"2017-11-13T16:50:14Z","closed_at":"2017-11-13T16:50:14Z","author_association":"NONE","body":"Hi all\r\n\r\nI wonder where/how you get a corresponding zoom-level for a specific map-scale. Like this, but the other way round:\r\n\r\n```python\r\nzoom_level_by_lower_scale_bound = {\r\n    1000000000: 0,\r\n    500000000: 1,\r\n    200000000: 2,\r\n    50000000: 3,\r\n    25000000: 4,\r\n    12500000: 5,\r\n    6500000: 6,\r\n    3000000: 7,\r\n    1500000: 8,\r\n    750000: 9,\r\n    400000: 10,\r\n    200000: 11,\r\n    100000: 12,\r\n    50000: 13,\r\n    25000: 14,\r\n    12500: 15,\r\n    5000: 16,\r\n    2500: 17,\r\n    1500: 18,\r\n    750: 19,\r\n    500: 20,\r\n    250: 21,\r\n    100: 22,\r\n    0: 23\r\n}\r\n```\r\n\r\nThanks for helping"},"comment":{"url":"https://api.github.com/repos/mapbox/mapbox-gl-js/issues/comments/343981995","html_url":"https://github.com/mapbox/mapbox-gl-js/issues/5658#issuecomment-343981995","issue_url":"https://api.github.com/repos/mapbox/mapbox-gl-js/issues/5658","id":343981995,"user":{"login":"jfirebaugh","id":98601,"avatar_url":"https://avatars2.githubusercontent.com/u/98601?v=4","gravatar_id":"","url":"https://api.github.com/users/jfirebaugh","html_url":"https://github.com/jfirebaugh","followers_url":"https://api.github.com/users/jfirebaugh/followers","following_url":"https://api.github.com/users/jfirebaugh/following{/other_user}","gists_url":"https://api.github.com/users/jfirebaugh/gists{/gist_id}","starred_url":"https://api.github.com/users/jfirebaugh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jfirebaugh/subscriptions","organizations_url":"https://api.github.com/users/jfirebaugh/orgs","repos_url":"https://api.github.com/users/jfirebaugh/repos","events_url":"https://api.github.com/users/jfirebaugh/events{/privacy}","received_events_url":"https://api.github.com/users/jfirebaugh/received_events","type":"User","site_admin":false},"created_at":"2017-11-13T16:50:14Z","updated_at":"2017-11-13T16:50:14Z","author_association":"MEMBER","body":"Hi @mnboos -- take a look at the [scale control](https://github.com/mapbox/mapbox-gl-js/blob/5bebe1cd725e9af0c6be25928bdbde468bebdf61/src/ui/control/scale_control.js#L61-L127) for some example code."}}
{"actor":{"display_login":"jfirebaugh"}}