[Mapnik-users] Getting UTM coordinates from Mapnik Viewer
artem at mapnik-consulting.com
Tue Jan 13 15:28:48 CET 2009
2009/1/11 Carl Johansson <mail at carl-johansson.com>:
> Hi Artem
> You're right, just subscribed.
> Again you are right, I want to turn screen coordinates into real world ones
> and from there on I will be able to turn them into MGRS rather than just
> I've been trying this with the simple viewer:
> double x = (double) e->x();
> double y = (double) e->y();
> coord2d coord;
> coord = coord2d(x, y);
> std::cout << coord << std::endl;
> Stockholm, Sweden is here coord2(1614085.074371404,6574896.886350079).
> Now I've really been trying to figure out what this represents but I
> couldn't find it anywhere.
OK, you get world coordinates in your Map (master) projection. Looks
like Mercator to me, but better check your *.xml file.
> Best regards,
> Artem Pavlenko-5 wrote:
>> Hi Carl,
>> Could you provide more details. Are you not sure how to translate 'screen'
>> coordinates into 'world' ? Or do you want to re-project them into UTM also
>> Please, consider subscribing to mapnik-users as anonymous postings are not
>> 2009/1/2 Carl Johansson <mail at carl-johansson.com>
>>> I've been trying to get a QString representation of the UTM coordinate
>>> pressed at in the Mapnik Viewer. Now I think that I should use some
>>> of CoordTransform passing it the coordinates from the widget. However
>>> where I get rather lost. Could anyone point me in the right direction?
>>> Already tried looking at posts like
>>> View this message in context:
>>> Sent from the Mapnik - Users mailing list archive at Nabble.com.
>>> Mapnik-users mailing list
>>> Mapnik-users at lists.berlios.de
>> Mapnik-users mailing list
>> Mapnik-users at lists.berlios.de
> View this message in context: http://www.nabble.com/Re%3A-Getting-UTM-coordinates-from-Mapnik-Viewer-tp21370149p21405648.html
> Sent from the Mapnik - Users mailing list archive at Nabble.com.
> Mapnik-users mailing list
> Mapnik-users at lists.berlios.de
More information about the Mapnik-users