[gdal-dev] ogr2ogr midmif to tab format conversion

Luca Sigfrido Percich sigfrido at tiscali.it
Fri Apr 29 12:33:09 EDT 2011


Hi all,

Zoltan sent me a couple of MIF files. The problem is that the Coordinate
System declaration in the MIF file is wrong, because it says it's
unreferenced cartesian with units=meters, while the coordinates are in
decimal degrees (probably WGS84). When the coordsys declaration is
corrected in the mif file, ogr2ogr converts it perfectly; otherwise, the
-a_srs option can be successfully used to override the bad SRS
declaration.

Cheers

Sig



Il giorno ven, 29/04/2011 alle 10.03 -0400, Frank Warmerdam ha scritto:

> Zoltan,
> 
> As discussed in http://www.gdal.org/ogr/drv_mitab.html the driver needs to
> set a bounds for coordinates which determines precision.  If it doesn't
> know the coordinate system it won't know that the bounds should be small
> (and hence the precision high) for latitudes and longitudes.   Try adding
> -a_srs WGS84 to your ogr2ogr command to tell OGR that the coordinate system
> is geographic.
> 
> 
> eg.
> 
> ogr2ogr -f "MapInfo File" -a_srs WGS84 $n $m
> 
> Best regards,



More information about the gdal-dev mailing list