Lat/Lon - Tile Formulas

Recommended Posts

Ok, Im confused.I thought I thoroughly understood lat/lon conversion formulas. I still think I have them right, because the database work I've done all lined up great... but I notice I cant teleport below 85

Share on other sites
 Help AVSIM continue to serve you!Please donate today!

BradIt's the way that the Fly! world is projected.85

Share on other sites

Could you please post it here, Colin? Or mail it to me, too. :-)nick@nik2.com

Share on other sites

NickHere is the formula:With an already declared array double zlat[256];void makelat(void){zlat[128]=0;zlat[127]=-1.40625;zlat[129]=1.40625;// northern hemispherefor(int z=130;z<256;z++){ zlat=zlat+(1.40625 *cos(zlat/ RAD)); }//southern hemispherefor(int z=126;z>=0;z--){ zlat=zlat-(1.40625 *cos(zlat/ RAD)); }}(You have to replace the < > with square brackets)1.40625 = 360/256 and is the constant for the longitude boundaries, they never change.It is a form of Mercator projection that varies the lattitude scale so that the longitude scale remains the same.I've also sent you a mail with a spreadsheet.Colin

Share on other sites

Ok, I finally got a chance to check out the spreadsheet you sent me Colin, but im a bit confused.If im reading your spreadsheet correctly...for GlobeTile 172:153You list latitudes of (assuming 173 is upperbounds of 172)173

Share on other sites

BradYou are reading the globe tile numbers wrongly.the globe tile numbering is transverse mercator, i.e. long:lat.In the example lattitude is tile 153 and longitude is 172.Colin

Doh!Thanks

Create an account

Register a new account

• Tom Allensworth,
Founder of AVSIM Online

• Hot Spots

• Flight Simulation's Premier Resource!

AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!

• Donation Goals

AVSIM's 2018 Fundraising Goal

Donate to our annual general fund. This donation keeps our doors open and providing you service 24 x 7 x 365. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. We reset this goal every new year for the following year's goal.

\$17,875.00 of \$36,000.00 goal reached.
Donate Now