Soeren Gebbert wrote:
Dear Devs,
i found a strange behavior in r.out.gdal while updating the GRASS test suite.

Im using the grass6.4svn snapshot: grass-6.4.svn_src_snapshot_2009_08_01.tar.gz.
on openSuse 10.3 Linux 2.6.22.19-0.2-bigsmp
gdal version 1.6.1

Using grass6.4svn with gdal1.6.0 here

Exporting elevation from nc_spm_08 with

r.out.gdal input=elevat...@permanent format=DTED type=Float32 output=test.dted

gives me

Driver <DTED> does not support direct writing. Using MEM driver for
intermediate dataset.
Exporting to GDAL data type: Float32
100%
Warning 1: The source does not appear to be a properly formatted cell.
Warning 1: The source projection coordinate system is PROJCS["Lambert Conformal Conic",GEOGCS["grs80",DATUM["North_American_Datum_1983",SPHEROID["Geodetic_Reference_System_1980",6378137,298.257222101]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433]],PROJECTION["Lambert_Conformal_Conic_2SP"],PARAMETER["standard_parallel_1",36.16666666666666],PARAMETER["standard_parallel_2",34.33333333333334],PARAMETER["latitude_of_origin",33.75],PARAMETER["central_meridian",-79],PARAMETER["false_easting",609601.22],PARAMETER["false_northing",0],UNIT["Meter",1]]. Only WGS 84 is supported. The DTED driver will generate a file as if the source was WGS 84 projection coordinate system. Warning 1: The corner coordinates of the source are not properly aligned on plain latitude/longitude boundaries. Warning 1: The horizontal source size is not conformant with the one expected by DTED Level 1 at this latitude (1500 pixels found instead of 225).
r.out.gdal complete.



These steps are performed:

GRASS 6.4.0svn > g.region -p
projection: 1 (UTM)
At least in gdal1.6.0, only WGS84 is supported for DTED, see warning above. WGS72 is also supported, but the gdal driver issues a warning.

GRASS 6.4.0svn > r.out.gdal --verbose format=DTED type=Float32 input=elevation output=/tmp/test.dted ....
ERROR 5: Access window out of range in RasterIO().  Requested
(0,994) of size 201x1 on raster of 100x100.
ERROR 5: Access window out of range in RasterIO().  Requested
(0,995) of size 201x1 on raster of 100x100.
ERROR 5: Access window out of range in RasterIO().  Requested
(0,996) of size 201x1 on raster of 100x100.
These messages are generated by gdal, not r.out.gdal. See
http://www.gdal.org/frmt_dted.html
for more info on the DTED format, particularly the section Creation Issues and the link to the DTED specs:
http://www.nga.mil/ast/fm/acq/89020B.pdf
If you can confirm that the input data are exactly formatted as Level 0, 1 or 2 cell, it is a problem of r.out.gdal. Also note that for DTED, elevation data is returned as 16 bit signed integer (citation from gdal).

hope that helps,

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

Reply via email to