Opened 18 years ago

Closed 16 years ago

Last modified 16 years ago

#1130 closed defect (worksforme)

Setting the "AREA_OR_POINT" Metadata item on GeoTIFFs fails to work

Reported by: cmichaelis@… Owned by: warmerdam
Priority: high Milestone:
Component: GDAL_Raster Version: unspecified
Severity: minor Keywords:
Cc: Mateusz Łoskot

Description (last modified by Mateusz Łoskot)

Hi there,

If I attempt to set the "AREA_OR_POINT" metadata item for a Geotiff in code, it seems to work - and I can even use GetMetadataItem() to fetch it back and it is indeed correct.

However, it's never written to the file - if I close the file and reopen it, the metadata item is no longer set.

The line I'm using to set it:

rasterDataset->SetMetadataItem("AREA_OR_POINT", "AREA");

The same thing seems to happen with various capitalizations of either parameter. It also doesn't seem to take permanent effect if you pass this parameter to the driver during creation of a new file.

Thanks! --Chris Michaelis

Change History (2)

comment:1 by Even Rouault, 16 years ago

Resolution: worksforme
Status: newclosed

This bug can't be reproduced any more. When read by gdalinfo, a file created by 'gdal_translate -mo "AREA_OR_POINT=AREA" src.tif dest.tif' shows AREA_OR_POINT=Area.

I think it has been fixed a long time ago. A svn blame on frmts/gtiff/geotiff.cpp seems to show that :

  • In r7491, the "AREA_OR_POINT" medata item was introduced and set from the GDALMD_AREA_OR_POINT key in the geotiff tag
  • In r7642, the GDALMD_AREA_OR_POINT key in the geotiff tag was written from the value of the metadata item.

This bug report may have been created between those 2 revisions.

comment:2 by Mateusz Łoskot, 16 years ago

Cc: Mateusz Łoskot added
Description: modified (diff)
Note: See TracTickets for help on using tickets.