#1595 closed defect (fixed)
GDALComputeRasterMinMax is failing on NETCDF subdasets
Reported by: | jluis | Owned by: | Mateusz Łoskot |
---|---|---|---|
Priority: | normal | Milestone: | 1.4.3 |
Component: | GDAL_Raster | Version: | 1.4.0 |
Severity: | normal | Keywords: | |
Cc: | warmerdam |
Description (last modified by )
Create a NETCDF file using GMT's example 5 (the mexican hat)
grdmath -R-15/15/-15/15 -I0.3 X Y HYPOT DUP 2 MUL PI MUL 8 DIV COS EXCH NEG 10 DIV EXP MUL = sombrero.grd
Using this example file (sombrero.grd) the following example code returns adfMinMax[0] = adfMinMax[1] = 0
hDataset = GDALOpen(gdal_filename, GA_ReadOnly); hBand = GDALGetRasterBand(hDataset,1); GDALComputeRasterMinMax(hBand, FALSE, adfMinMax);
Attachments (2)
Change History (10)
comment:1 by , 17 years ago
Version: | unspecified → 1.4.0 |
---|
comment:2 by , 17 years ago
Cc: | added |
---|---|
Component: | default → GDAL_Raster |
Milestone: | → 1.4.3 |
Owner: | changed from | to
comment:3 by , 17 years ago
Status: | new → assigned |
---|
JLuis,
I'd appreciate if you could attach sample GMT file I could use to reproduce the problem. If it's a problem with uploading it here, because of size/copying issue, perhaps you could send it on my e-mail (mateusz at loskot dot net). Thank you in advance.
by , 17 years ago
Attachment: | sombrero.grd added |
---|
comment:4 by , 16 years ago
Description: | modified (diff) |
---|
by , 16 years ago
Simple program testing computation of min/max for sombrero.grd
comment:5 by , 16 years ago
I prepared and run small test (see test.cpp program attached) and I can not reproduce this problem. GDAL calculates min and max values for sombrero.grd dataset as follows:
mloskot@dog:~/dev/gdal/bugs/1595$ ./test sombrero.grd Min: -0.675759 Max: 1
So, I'm inclined to say this bug has been fixed since GDAL 1.4.0.
comment:6 by , 16 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
JLuis, I'm closing this ticket. Please reopen if the problem still occurs for you when using GDAL in newer version than 1.4.0.
comment:7 by , 16 years ago
Frank, would it be reasonable to add sombrero.grd file and appropriate test case to the autotest package?
comment:8 by , 16 years ago
I added sombrero.grd dataset to autotest package and extended NetCDF test cases accordingly (r12456)
Mateusz,
Could you look into this? JLuis, it would be helpful if you could attach a small sample GMT file with demonstrating the issue, saving Matuesz the time to install GMT.