Google Maps, spherical mercator, excel 2
$30-100 USD
Paid on delivery
Attached is a spreadsheet with some vb code to interact with the google map interface. Given Lat, Long and Z, the code will calculate which tile has that location on it and generate a url to retrieve it on Sheet 1.
On sheet 2 sub getmylat and getmylong will take in xtile, ytile, zoom, pixelx and pixely and tell you what the latitude and longitude of that pixel is.
The project has two requests.
FIRSTLY I am suspecting a bug in the lattitude formula. What I've done is measure the difference between pixel 1 and pixel 2 at every zoom level. With Longitudes there is no problem, at zoom 1 they are 0.703 degrees apart and at each zoom thereafter they are half that distance (Column T).
With Lattitudes it starts at 0.703 as well, but the next level down gives my a number 4.975328 times smaller and so on, not the 2 that I would expect if each tile has double the resolution of the previous zoom. I need to now if this is this an error in the formula or an error in my understanding. If it's in the formula I would ask to fix it, if there's something I don't understand here, please explain it to me.
SECONDLY I need you to program a function where if I know the lat, lon and zoom, xtile and ytile, it will tell me which pixel (x and y) corresponds. Something like getPixelXFromLong(Xtile, zoom, longitude) and getPixelYFromLat(Ytile, zoom, lattitude).
Project ID: #2728603