[gdal-dev] retrieve specific tiff tags

Frank Warmerdam warmerdam at pobox.com
Tue Aug 17 21:10:53 EDT 2010


Garrett, Benjamin D wrote:
> Hi,
> 
>  
> 
> I would like to be able to retrieve the value of this tiff tag:
> 
> 34737                    GeoAsciiParams
> 
>  
> 
> from a geotiff file.   How do I do this using GDAL?  I’ve searched the 
> FAQ, the mailing list via google, this page: 
> http://www.gdal.org/frmt_gtiff.html , etc.
> 
>  
> 
> When I dump the metadata for my file using “gdainfo”, the tag above 
> doesn’t show up (even though I know it is present in the file by dumping 
> it via other 3^rd party tools). I assume this is because I don’t know 
> what the right domain name is to pass in via -mdd.  But I haven’t found 
> any list of domain names that might be appropriate for tiff.

Ben,

This tag is considered internal structural information of the file,
and is not directly made available.  However, it will generally contain
things like the PSC citation name, datum name and such that are used to
build the projected coordinate system name.  So much of the contents will
typically come through in that fashion.

If you want to access such underlying TIFF tags you should really be
using libtiff, and TIFFGetField().  I would note that libgeotiff also
does not provide direct access to this tag.

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