diff options
author | Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> | 2015-04-20 11:27:10 +0200 |
---|---|---|
committer | Konstantin Ritt <ritt.ks@gmail.com> | 2015-05-04 17:55:14 +0000 |
commit | 4c00a26fc583003059f1854bf1289c28c7f01bd6 (patch) | |
tree | 8cd14fb6bda241b4b8032fa22b58c4b3aaf0b5ef /tests | |
parent | 5b1a3318125b72563b5de1bf7549088165ec60f4 (diff) | |
download | qtimageformats-4c00a26fc583003059f1854bf1289c28c7f01bd6.tar.gz |
Clean up reading TIFF headers
Split reading TIFF headers from the decoding to make it
possible to read correct metadata on undecoded images.
This fixes reading the image format from the QImageReader,
and is necessary for later patches.
Change-Id: Ida27e98252bf95459d87354586d4a5fba348efcb
Reviewed-by: Ivan Komissarov <ABBAPOH@gmail.com>
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/tiff/tst_qtiff.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/auto/tiff/tst_qtiff.cpp b/tests/auto/tiff/tst_qtiff.cpp index 6a9f9c1..89630c2 100644 --- a/tests/auto/tiff/tst_qtiff.cpp +++ b/tests/auto/tiff/tst_qtiff.cpp @@ -394,6 +394,8 @@ void tst_qtiff::readWriteNonDestructive() QVERIFY(buf.open(QIODevice::ReadOnly)); QImageReader reader(&buf); + QCOMPARE(reader.imageFormat(), expectedFormat); + QCOMPARE(reader.size(), image.size()); QImage image2 = reader.read(); QVERIFY2(!image.isNull(), qPrintable(reader.errorString())); |