Am 26.09.2014 13:51, schrieb teeschke:
Hi list

We have a grib file, that gets cropped after a projection from WGS84 to
WebMercator. The issue occurs in UMN Mapserver and QGIS. ArcMap can project
the grib file correctly - so I think its a GDAL thing.

<http://osgeo-org.1560.x6.nabble.com/file/n5164353/grib_projection_cutting.jpg>

Extracting the metadata with gdalinfo points out that the original corner
coordinates are shifted a little bit.

$ gdalinfo 2014-09-28T00\:00Z.grb
Driver: GRIB/GRIdded Binary (.grb)
Files: 2014-09-28T00:00Z.grb
Size is 1440, 721
Coordinate System is:
GEOGCS["Coordinate System imported from GRIB file",
     DATUM["unknown",
         SPHEROID["Sphere",6367470,0]],
     PRIMEM["Greenwich",0],
     UNIT["degree",0.0174532925199433]]
Origin = (-179.875000000000000,90.125000000000000)
Pixel Size = (0.250000000000000,-0.250000000000000)
Corner Coordinates:
Upper Left  (-179.8750000,  90.1250000) (179d52'30.00"W, 90d 7'30.00"N)
Lower Left  (-179.8750000, -90.1250000) (179d52'30.00"W, 90d 7'30.00"S)
Upper Right ( 180.1250000,  90.1250000) (180d 7'30.00"E, 90d 7'30.00"N)
Lower Right ( 180.1250000, -90.1250000) (180d 7'30.00"E, 90d 7'30.00"S)
Center      (   0.1250000,   0.0000000) (  0d 7'30.00"E,  0d 0' 0.01"N)

90° N can not be projected to Web Mercator (it would be in infinity), so +/-90.125 can also not be reprojected correctly.

Cut your file to +/-179.9/89.9 degrees, then try again the reprojection with gdalwarp.

HTH,
André Joost

_______________________________________________
gdal-dev mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/gdal-dev

Reply via email to