[OSM-dev] tile calculation
Rob Aerts
rob at coolbegin.com
Sun Jul 29 18:12:39 BST 2007
i try to calculate the x and y tile url in c
the example on the wiki (in perl code) looks like
my $xtile = int( ($lon+180)/360 *2**$z ) ;
my $ytile = int( (1 - log(tan($lat*pi/180) + sec($lat*pi/180))/pi)/2 *2**$z
) ;
i can't figure out the sec formula in the $ytile
wiki : http://wiki.openstreetmap.org/index.php/Slippy_map_tilenames
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/dev/attachments/20070729/d3b52e19/attachment.html>
More information about the dev
mailing list