#5326 closed defect (fixed)
Writing/Reading GCPZ to/from .aux.xml
Reported by: | oleinik | Owned by: | Even Rouault |
---|---|---|---|
Priority: | normal | Milestone: | 1.10.2 |
Component: | GDAL_Raster | Version: | 1.10.1 |
Severity: | major | Keywords: | |
Cc: |
Description
I have raster file with GCPs points including "Z"-coorinate. After calling GDALSetGCPs with my points I'v got attached file "1.bmp.aux.xml". After calling GDALGetGCPs I have Z=0 on every points. Gdalinfo.log also attached.
I think that because different xml attribute used during write/read aux.xml file
GDALPamDataset::SerializeToXML: if( psGCP->dfGCPZ != 0.0 )
CPLSetXMLValue( psXMLGCP, "#GCPZ",
oFmt.Printf( "%.12E", psGCP->dfGCPZ ) );
GDALPamDataset::XMLInit: psGCP->dfGCPZ = atof(CPLGetXMLValue(psXMLGCP,"Z","0.0"));
Attachments (2)
Change History (7)
by , 10 years ago
Attachment: | 1.bmp.aux.xml added |
---|
by , 10 years ago
Attachment: | gdalinfo.log added |
---|
comment:1 by , 10 years ago
Owner: | changed from | to
---|
comment:2 by , 10 years ago
Milestone: | → 1.10.2 |
---|---|
Resolution: | → fixed |
Status: | new → closed |
comment:4 by , 10 years ago
I have found similar bug in another files: alg\gdal_tps.cpp alg\gdal_crs.c
comment:5 by , 10 years ago
trunk r26731 "Remove duplicated serialization and deserialization of GCP list that was found in 4 instances in the code base... So now TPS and Polynomial GCP transformation have the Z component of their GCPs properly serialized/deserialized (#5326)"
branches/1.10 r26732 "TPS and Polynomial GCP transformations: recognize 'GCPZ' attribute of GCP, in addition to 'Z', since 'GCPZ' is what we currently generate. But GDAL 1.11/2.0 will generate 'Z' for consistency (#5326)"
Good catch.
trunk r26727 "PAM .aux.xml and VRT: serialize Z component of a GCP as 'Z' attribute, for consistency, instead of GCPZ that could not be read back previously. In reading code, try reading 'Z' and if not found try 'GCPZ' (#5326)"
branches/1.10 r26728 "PAM .aux.xml and VRT: recognize 'GCPZ' attribute of GCP, in addition to 'Z', since 'GCPZ' is what we currently generate. But GDAL 1.11/2.0 will generate 'Z' for consistency (#5326)"