我有一个 geotiff 文件,我正在使用 QPixmap::load() 将其加载到 QPixmap 中。我多次将以下警告打印到控制台。但是,直接使用 libtiff 会在没有警告的情况下打开它。
关于如何减轻 QT 中这些难看的警告的任何想法?
TIFFReadDirectory: Warning, foo: unknown field with tag 33550 (0x830e) encountered.
TIFFReadDirectory: Warning, foo: unknown field with tag 33922 (0x8482) encountered.
TIFFReadDirectory: Warning, foo: unknown field with tag 34735 (0x87af) encountered.
TIFFReadDirectory: Warning, foo: unknown field with tag 34736 (0x87b0) encountered.
TIFFReadDirectory: Warning, foo: unknown field with tag 34737 (0x87b1) encountered.
TIFFReadDirectory: Warning, foo: unknown field with tag 33550 (0x830e) encountered.
TIFFReadDirectory: Warning, foo: unknown field with tag 33922 (0x8482) encountered.
TIFFReadDirectory: Warning, foo: unknown field with tag 34735 (0x87af) encountered.
TIFFReadDirectory: Warning, foo: unknown field with tag 34736 (0x87b0) encountered.
TIFFReadDirectory: Warning, foo: unknown field with tag 34737 (0x87b1) encountered.
谢谢!
最佳答案
这些是可以使用 libtiff 库定义的自定义标签:
http://www.remotesensing.org/libtiff/addingtags.html
它们可能是 EXIF 标签:
http://www.awaresystems.be/imaging/tiff/tifftags/privateifd/exif.html
这些是 libtiff 的已知标签:
http://trac.imagemagick.org/browser/tiff/trunk/libtiff/tiff.h#L148
由于新定义包括类型和计数,您可能会猜到这些标签的含义。您也可以运行 exiftool 来检查未知的 TIFF 标签:
$ exiftool -htmldump sample.tif >/tmp/dump.html;火狐/tmp/dump.html
关于c++ - 使用 QPixmap::load( ) 读取 GeoTiff 时的 TIFFReadDirectory 警告,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14127160/