Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[udig-users] Why does WGS84 map of UK appears squashed in uDig?

 
Hi,
 
I am a newbie to GIS and uDig and I have a shape file dataset for
regions of the UK, which I understand is in OSGB36 coordinates.
 
When I load this shapefile directly into uDig with
Layer->Add->Files->shapefile.shp, it appears the way you would expect to
see an outline of the UK, say, on Google Maps, for example.

However the coordinates in the shapefile are in OSGB36 format (metres
from a point in the south west) so for the coordinates to tally up with
Google Maps/Google Earth in KML, they need to be converted to WGS84
format.

I seem to have done this successfully with the following transformation
of the original shapefile with FWTools and the following command:

ogr2ogr -t_srs EPSG:4326 -s_srs "+proj=tmerc +lat_0=49 +lon_0=-2
+k=0.9996012717 +x_0=400000 +y_0=-100000 +ellps=airy +datum=OSGB36
+units=m +no_defs" regions_wgs84.shp shapefile.shp

Now the coordinates in regions_wgs84.shp match up with Google Maps and
can be used in KML. So for example, if I load in the new shapefile into
uDig and overlay a point in a new layer using coordinates for a place
taken from Google Maps, it appears in the correct place on the rendered
map in uDig.

However, I am perplexed about the map appearing vertically squashed in
uDig, whereas in Google Maps the map appears as you would expect it.

What am I doing wrong or not doing, so that the shape files transformed
to WGS84 coordinates appear correctly in uDig with the correct WGS84
coordinates?

I have also tried loading the transformed shape file into Postgres with
the following,

shp2pgsql -D -s 4326 regions_wgs84.shp regions > regions.sql
psql -Upostgres -f regions.sql db

, and then loading them into uDig via Layer->Add->PostGIS and selecting
the table from the database and the same squashed map appears.

Any help would be much apprectiated!

Thanks,

Andrew

http://www.bbc.co.uk/
This e-mail (and any attachments) is confidential and may contain personal views which are not the views of the BBC unless specifically stated.
If you have received it in error, please delete it from your system.
Do not use, copy or disclose the information in any way nor act in reliance on it and notify the sender immediately.
Please note that the BBC monitors e-mails sent or received.
Further communication will signify your consent to this.
					


Back to the top