google maps api zoom level scale
Available Zoom Levels
Zoom level 0 is the most zoomed out zoom level available and each integer
step in zoom level halves the X and Y extents of the view and
doubles the linear resolution.
Google Maps was built on a 256x256 pixel tile system where zoom level 0
was a 256x256 pixel image of the whole earth. A 256x256 tile for zoom level 1
enlarges a 128x128 pixel region from zoom level 0.
The available zoom range depends on where you are looking and the kind of map
you are using:
Road maps - seem to go up to zoom level 22 everywhere
Hybrid and satellite maps - the max available zoom levels depend on location.
Here are some examples:
Remote regions of Antarctica: 13
Gobi Desert: 17
Much of the U.S. and Europe: 21
"Deep zoom" locations: 22-23 (see bkaid's link)
Note that these values are for the Google Static Maps API which seems to give
one more zoom level than the Javascript API. It appears that the
extra zoom level available for Static Maps is just an upsampled version
of the max-resolution image from the Javascript API.
Map Scale at Various Zoom Levels
Google Maps uses a Mercator projection so the scale varies substantially
with latitude.
A formula for calculating the correct scale based on latitude is:
meters_per_pixel = 156543.03392 * Math.cos(latLng.lat() * Math.PI / 180) / Math.pow(2, zoom)
Are there any code examples left?
New code examples in category Other
-
Other 2023-03-27 22:50:10 how to select the whole line in vscode with keyboard shortcut
-
Other 2022-03-27 22:45:24 income of a web developer
-
Other 2022-03-27 22:35:01 \pyrcc_main.py: File does not exist 'resources.qrc'
-
Other 2022-03-27 22:30:45 rick roll embed code
-
Other 2022-03-27 22:20:08 Circuit_04_Potentiometer
-
Other 2022-03-27 22:20:05 iterative power
-
Other 2022-03-27 22:15:11 flutter run all
-
Other 2022-03-27 22:10:05 when is karlson release
-
Other 2022-03-27 22:10:02 wp .htaccess example
-
Other 2022-03-27 22:00:08 bash pause in file read line by line