[gdal-dev] problems reading a .img file containing only elevation data

Frank Warmerdam warmerdam at pobox.com
Sat Sep 27 20:08:59 EDT 2008

On Fri, Sep 26, 2008 at 8:15 PM, Tom Flynn <flynnt at acm.org> wrote:
> I'm expecting this call to put nXSize*4 bytes of data into my buffer
> at pData.  That data will contain floating point numbers.
> Do my arguments match what I intend?


I don't see any obvious problems with your call.

It might be helpful if you could do something like
"gdalinfo -mm abc.img" so we can see if GDAL recognises
some of the image data.

It is slightly posible that the file is in compressed format,
and that you are using an older version of the GDAL library
where floating point compressed data was not properly
supported (this has been an area of active work in the
last year or two).

It would be also very helpful if you could put a sample
.img file somewhere for download so that others could
try it too, though a 120MB file might be challenging to
download for only this issue.

Best regards,

I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | Geospatial Programmer for Rent

More information about the gdal-dev mailing list