[Gdal-dev] Tiff with multiple IFDs
Frank Warmerdam
fwarmerdam at gmail.com
Wed Feb 16 17:43:48 EST 2005
On Wed, 16 Feb 2005 18:43:03 +0000 (UTC), Gao, Peng <pgao at esri.com> wrote:
> Does GDAL support tiff images with multiple IFDs? I have a tiff
> that GDAL says it has one band, but other imaging software
> say it has three bands. This tiff has multiple IFDs, with one
> band per IFD.
>
> How do I read tiff like these using GDAL?
Peng,
Such multiple IFD files are not currently conveniently handled by TIFF.
It is *possible* to access alternative directories but it is not convenient.
If you know the directories are there I think you can do something like:
gdalinfo GTIFF_DIR:2:target.tif
This would open IFD # 2 of target.tif.
It is very hard in cases like this for GDAL to know how to present the
file as a dataset. Should the different IFDs be considered bands of a
single dataset? Should each be considered a seperate dataset?
If I were to do more in this regard, I would treat all extra IFDs that
don't have the overview bit set as seperate datasets, and return them
as subdataset metadata so they could be identified and utilized.
If you would like, I could apply such a change.
However, generally speaking I feel that folks who emit data in this
form are not showing much interest in having it usable in non-customized
packages.
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