c++ - 使用 QPixmap::load( ) 读取 GeoTiff 时的 TIFFReadDirectory 警告

标签 c++ qt tiff geotiff

我有一个 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/

相关文章:

php - 从网页(PHP 或 JS)创建分层 PSD 或 TIFF

c++ - 主要针对 C++ 的持续构建基础架构建议;格林希尔诚信

c++ - 如何将关键点复制到另一个 vector

c++ - 函数模板参数推导和继承

c++ - 在 QTextEdit 中激活光标

qt - 在 QML 中创建一个矩形的副本

.net - 将 HTML 渲染为 TIFF

c++ - 在 C++ 中读取非标准位深度(12 位)的 TIFF

c++ - MPI 同步 vector 矩阵

c++ - IncludeOS hello world 失败