[gdal-dev] GDAL can't read values from new raster dataset, but Global Mapper can
even.rouault at spatialys.com
Mon Sep 30 03:51:17 PDT 2019
On lundi 30 septembre 2019 03:42:32 CEST CDelancy wrote:
> Hello. I am using GDAL 3 in a c++ project. I have found that GDAL does not
> seem to properly read values from raster datasets that it has created. For
> example, if I create a new raster dataset with one band and read the min and
> max values from that band, it always returns -4294967295.0 and
With which API ? With GetMinimum() and GetMaximum() ? In that case, that's the documented behaviour:
Fetch the minimum value for this band.
For file formats that don’t know this intrinsically, the minimum supported value for the data type will generally be returned.
Look at ComputeStatistics() or ComputeRasterMinMax():
Spatialys - Geospatial professional services
More information about the gdal-dev