[Freegis-list] tool to find out lat/lon --> UTM
Frank Koormann
frank.koormann at intevation.de
Tue Feb 1 09:36:16 CET 2005
Cere,
* Paul Ramsey <pramsey at refractions.net> [050201 00:09]:
> Write up 20 lines of perl to wrap around your proj4 call. The zone value
> is a simple categorization on your longitude, so it is trivial to
> script. Possibly why noone has bothered to make such a think automagic.
>
Thuban implements an 'on demand' estimate of UTM Zone based on the
layers bounding box:
http://www.intevation.de/cgi-bin/viewcvs-thuban.cgi/thuban/Thuban/UI/projdialog.py?rev=HEAD&content-type=text/vnd.viewcvs-markup
Check for the UTMProposeZoneDialog, actually the estimate is 4 lines of
code:
x = x + 180
x2 = x2 + 180
center = (x2 - x) / 2 + x
proposedZone = int(center / 6 + 1)
Regards,
Frank
--
Frank Koormann <frank.koormann at intevation.de>
Professional Service around Free Software (http://intevation.net/)
FreeGIS Project (http://freegis.org/)
More information about the Freegis-list
mailing list
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)