From 4c00a26fc583003059f1854bf1289c28c7f01bd6 Mon Sep 17 00:00:00 2001 From: Allan Sandfeld Jensen Date: Mon, 20 Apr 2015 11:27:10 +0200 Subject: 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 Reviewed-by: Konstantin Ritt --- tests/auto/tiff/tst_qtiff.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'tests/auto/tiff/tst_qtiff.cpp') 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())); -- cgit v1.2.3