qbektrix / gmapcatcher

Automatically exported from code.google.com/p/gmapcatcher
0 stars 0 forks source link

Google's new URL pattern #112

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
<mikezang@yahoo.co.jp> report:

according to
http://code.google.com/intl/en/apis/maps/documentation/upgrade.html#ZoomLevelOrd
er,
google map use a new zoom level representation.

The new zoom level should become 17-oldlevel. The old zoom level still
work, google check 'z' and 'zoom' to mark the two protocol.

old pattern:

http://mt1.google.com/vt/lyrs=m@115&hl=en&x=453&y=201&zoom=8

new:

http://mt1.google.com/vt/lyrs=m@115&hl=en&x=453&y=201&z=9

Google may shut down the old one in future.

I suggest to make a new class 'googleMapsURL' to deal with the map urls,
and design a new interface for start page parsing and tile URL forming.
However I have no time to do this.

Original issue reported on code.google.com by pi3or...@gmail.com on 16 Dec 2009 at 3:56

GoogleCodeExporter commented 9 years ago
I honestly do not see the need make a new class to fix this issue ...
All the interaction with google maps is in:
http://code.google.com/p/gmapcatcher/source/browse/trunk/src/mapServers/googleMa
ps.py

 We just need to update def parse_start_page(layer, html):

Original comment by heldersepu on 16 Dec 2009 at 2:03

GoogleCodeExporter commented 9 years ago
You are right. However some global state should still be saved: the mean of 'z' 
in
new pattern is different from old pattern, we have to add a var to identify 
whether
to use old pattern or the new one.

Original comment by pi3or...@gmail.com on 16 Dec 2009 at 2:16

GoogleCodeExporter commented 9 years ago
 I agree with you, but we could also do some "clean up" in googleMaps.py and leave only 
the new pattern, What do you think about that?

Original comment by heldersepu on 16 Dec 2009 at 2:38

GoogleCodeExporter commented 9 years ago
Remember people see different content in different country, we cannot ensure 
other
people can use the new interface, see Issue 94. I suggest to keep the old 
pattern, at
least for some month. How do you think?

Original comment by pi3or...@gmail.com on 16 Dec 2009 at 3:06

GoogleCodeExporter commented 9 years ago
 The documentation in the link is for the API version 2 that was launched on April 3, 
2006, I guess the old option is very very old! 

 Maybe not a "clean up" like I mentioned before but I guess we could safely replace 
"zoom" with "z"; I will do some testing now.

Original comment by heldersepu on 18 Dec 2009 at 4:31

GoogleCodeExporter commented 9 years ago
I made some improvements to def parse_start_page, see r645 & r646
and also replaced "zoom" with "z", see r647
 preliminary testing looks good!

Original comment by heldersepu on 18 Dec 2009 at 5:33

GoogleCodeExporter commented 9 years ago

Original comment by heldersepu on 8 Jan 2010 at 1:38