[GRASS-dev] [bug #4897] (grass) r.in.gdal, AAIGrid: FCELL is forced on output

Request Tracker grass-bugs at intevation.de
Mon Jul 24 07:36:36 EDT 2006


this bug's URL: http://intevation.de/rt/webrt?serial_num=4897
-------------------------------------------------------------------------

Subject: r.in.gdal, AAIGrid: FCELL is forced on output

Platform: GNU/Linux/x86
grass obtained from: CVS
grass binary for platform: Compiled from Sources
GRASS Version: 2006.07.23

If the input AAIGrid raster is double floating point, r.in.gdal will import it as a trunctated FCELL anyway.

to reproduce:

create a DCELL map, eg.:
r.mapcalc 'map=double(rand(100.0,1000.0))'

export and import it back:
r.out.gdal input=map format=AAIGrid type=Float32 output=map.arc
r.in.gdal input=/home/shoofi/map.arc output=map_gdal 

see the difference (ie. data corruption):
r.mapcalc 'diff=map-map_gdal'
r.info -r diff
min=-0.000031
max=0.000031



Note that the integer/floating point detection for AAIGrid driver in GDAL was fixed after 1.3.2 release, so we could consider disposing r.out/in.arc in Grass 7 *if* r.in.gdal is fixed to support DCELL for AAIGrid (r.in.arc allows enforcing DCELL output, maybe r.in.gdal should follow?).

Maciek


-------------------------------------------- Managed by Request Tracker




More information about the grass-dev mailing list