Google api scaling range

I use google map-3 API, I tried with a different scaling value, I accidentally made for some numbers starting from 1 to 100, the map gets an increase to increase the number, but some level gives the same result, I mean I I get the same scale for 30 and 100.

I like to know what exact range to scale?

+43
google-maps
Feb 20 2018-12-12T00:
source share
4 answers

Available Scale Levels

Scale level 0 is the most scalable zoom level, and each integer step in the zoom level reduces the X and Y extents of the view and doubles the linear resolution.

Google maps were built on a system with 256x256 pixel tiles, where the zoom level 0 was a 256x256 pixel image of the whole earth. The 256x256 tile for zoom level 1 enlarges the 128x128 pixel area from zoom level 0.

As bkaid correctly pointed out, the available zoom range depends on where you are looking and the type of map you are using:

  • Roadmaps appear to be approaching level 22 everywhere.
  • Hybrid and Satellite Maps — The maximum zoom level varies by location. Here are some examples:
    • Remote Antarctica: 13
    • Gobi Desert: 17
    • Most of the USA and Europe: 21
    • Deep Zoom: 22-23 (see bkaid link )

Note that these values ​​apply to the Google Static Maps API , which seems to provide another level of scaling than the Javascript API. It seems that the extra zoom level available for static maps is just an extended version of the maximum resolution image from the Javascript API.

Map scale at various zoom levels

Google Maps uses the Mercator projection, so the scale changes significantly with latitude. The 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)

Formula from Chris Broadfoot Comment .

+31
Sep 04 '15 at 21:51
source share

Google Map Basics

Zoom Level - Zoom

0 - 19

0 lowest scale (whole world)

19 highest scale (individual buildings, if any). Retrieve the current zoom level using mapObject.getZoom()

+56
Feb 20 '12 at 6:00
source share

What you are looking for are scales for each zoom level. Use them:

 20 : 1128.497220 19 : 2256.994440 18 : 4513.988880 17 : 9027.977761 16 : 18055.955520 15 : 36111.911040 14 : 72223.822090 13 : 144447.644200 12 : 288895.288400 11 : 577790.576700 10 : 1155581.153000 9 : 2311162.307000 8 : 4622324.614000 7 : 9244649.227000 6 : 18489298.450000 5 : 36978596.910000 4 : 73957193.820000 3 : 147914387.600000 2 : 295828775.300000 1 : 591657550.500000 
+16
Nov 17 '14 at 6:11
source share

The range depends on where you look. In some places, the zoom level is 15 or so, where in other places there are 23 (or possibly more). Here are some examples from 23 zoom levels. Google Maps has a getMaxZoomAtLatLng API , which you can get to get the maximum zoom level.

+8
May 21 '13 at
source share



All Articles