Or in C++ :
....
mapnik::projection prj("+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0
+lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgri...@null +no_defs
+over");
double x = 1114078.557;
double y = 6054943.745;
prj.inverse(x0,y0);
std::cout << x << " ," << y << "\n";
Artem
2009/1/13 Artem Pavlenko <[email protected]>:
> 2009/1/13 Carl Johansson <[email protected]>:
>>
>> While no responses to
>> http://www.nabble.com/Re%3A-Getting-UTM-coordinates-from-Mapnik-Viewer-td21370149.html
>> Getting UTM coordinates from Mapnik Viewer here on this list I've been
>> trying to figure out what the coordinates I get from the mapnik viewer.
>>
>> Now I can turn degrees and radians into UTM, MGRS, whatever.
>
> UTM (Universal Transverse Mercator ) needs some zone number (??).
> But I don't know what is MGRS stands for, could you let me know.
>
> The coordinates
>> I get however, look similar to what I found in
>> https://lists.berlios.de/pipermail/mapnik-users/2008-December/001431.html
>> Problems With Raster Data .
>>
>>> Corner Coordinates:
>>> Upper Left ( 1114078.557, 6054943.745) ( 10d 0'28.58"E, 47d41'13.28"N)
>>> Lower Left ( 1114078.557, 5995663.745) ( 10d 0'28.58"E, 47d19'38.31"N)
>>> Upper Right ( 1168438.557, 6054943.745) ( 10d29'46.54"E, 47d41'13.28"N)
>>> Lower Right ( 1168438.557, 5995663.745) ( 10d29'46.54"E, 47d19'38.31"N)
>>> Center ( 1141258.557, 6025303.745) ( 10d15'7.56"E, 47d30'26.91"N)
>>
>> How do I get these guys into degrees or radians? More importantly, what are
>> they? (yes, still new to GIS but I'm sure working on it)
>
> They look like Mercator ( in meters) coordinates. You can verify this
> with simple Python script:
>
>
> from mapnik import *
>
> p = Projection("+proj=merc +datum=WGS84")
>
> # or for spherical Mercator (OSM,GMap etc)
>
> p = Projection("+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0
> +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgri...@null +no_defs
> +over")
>
> # re-project to WGS84 Geographical coordinate system (Lon/Lat)
> p.inverse(Coord(1114078.557, 6054943.745))
>
>>>>
>
> Artem
>>
>> Carl
>> --
>> View this message in context:
>> http://www.nabble.com/Coordinates-in-degrees%2C-radians-and...-what-else--tp21436631p21436631.html
>> Sent from the Mapnik - Users mailing list archive at Nabble.com.
>>
>> _______________________________________________
>> Mapnik-users mailing list
>> [email protected]
>> https://lists.berlios.de/mailman/listinfo/mapnik-users
>>
>
_______________________________________________
Mapnik-users mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/mapnik-users