[GRASS-dev] latlon support

Markus Metz markus.metz.giswork at googlemail.com
Mon Jan 26 07:51:11 EST 2009


When I was updating v.in.gshhs (see user list) I came across a strange 
phenomenon in GRASS latlon support when crossing the datum border. The 
map extends reported by v.info are wrong because East is larger than 180 
(about 191) and converted to (East - 360) which is only 10 degrees east 
of West. The shorelines are spanning 370 degrees of longitude and not 10 
degrees. I know GRASS doesn't support crossing the datum border, i.e. 
going beyond 180E or 180W, but I don't understand why not. The GSHHS 
shoreline vector for example crosses the datum border and clipping or 
converting coordinates of vertices would create artifacts. Geographic 
features can cross the datum border, so why not supporting a range -360 
to 360 for longitude? I am aware that 181 is equal to -179 (in latlon), 
but going from 179 to 181 is different from going from 179 to -179. 
Mathematically the difference in the first case is 2 degrees longitude, 
in the latter case 358 degrees longitude. The distance between two 
points depends on whether you go east or west (or north or south). So 
if  the first point is on 179 lon and the second is on 181 lon, this 
would indicate to go east, while when the second point is on -179 lon 
this would indicate to go west from the first point. Does that make sense?
How much havoc would it cause to support longitudes from -360 to 360 in 
latlon?

Markus M



More information about the grass-dev mailing list