[postgis-users] OpenStreetMap to GPS

Greg Troxel gdt at ir.bbn.com
Sat Nov 7 13:37:33 PST 2009


Matthew Pulis <mpulis at gmail.com> writes:

> I want to plot a list of GPS acquired locations with data originating from
> OpenStreetMap. I am thinking to keep everything in GPS projection since
> quite near in the future the project is going to be accepting live GPS
> readings.
>
> OSM SRID = 900913
>
> Should I consider GPS SRID to be: 4326?
>
> However when I try to transform this geometry:
>
> gis=# select astext(way), asewkt(way), st_srid(way) from malta_roads
> gis-# where osm_id = 23561453;

Have you looked at the .osm file with an editor to see what's actually
in it?

I think you'll find that the data in the osm file is actually in SRID
4326.  Certainly the osm file saved by JOSM is in this format, and also
e.g. the Massachusetts state extract of the planet file from cloudmade.

It is true that OSM uses google spherical mercator for creating map
tiles, but those are then projected coordinates rather than what appears
in the vector database.  It is of course possible that your vector file
has been pre-transformed to something unusual, but from my experience
with osm that would be somewhat odd.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 194 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20091107/6460c74c/attachment.pgp>


More information about the postgis-users mailing list