From 1a608a5b7e5a533214982f35bda45042d3fba237 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Sun, 24 Nov 2013 16:35:50 +0100 Subject: [PATCH] TgaImporter: fix test on ES2. --- src/Plugins/TgaImporter/Test/TgaImporterTest.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/Plugins/TgaImporter/Test/TgaImporterTest.cpp b/src/Plugins/TgaImporter/Test/TgaImporterTest.cpp index 67dd92e7a..241d71f04 100644 --- a/src/Plugins/TgaImporter/Test/TgaImporterTest.cpp +++ b/src/Plugins/TgaImporter/Test/TgaImporterTest.cpp @@ -197,7 +197,11 @@ void TgaImporterTest::grayscaleBits8() { std::optional image = importer.image2D(0); CORRADE_VERIFY(image); + #ifndef MAGNUM_TARGET_GLES2 CORRADE_COMPARE(image->format(), ColorFormat::Red); + #else + CORRADE_COMPARE(image->format(), ColorFormat::Luminance); + #endif CORRADE_COMPARE(image->size(), Vector2i(2, 3)); CORRADE_COMPARE(image->type(), ColorType::UnsignedByte); CORRADE_COMPARE(std::string(reinterpret_cast(image->data()), 2*3), @@ -227,7 +231,11 @@ void TgaImporterTest::file() { std::optional image = importer.image2D(0); CORRADE_VERIFY(image); + #ifndef MAGNUM_TARGET_GLES2 CORRADE_COMPARE(image->format(), ColorFormat::Red); + #else + CORRADE_COMPARE(image->format(), ColorFormat::Luminance); + #endif CORRADE_COMPARE(image->size(), Vector2i(2, 3)); CORRADE_COMPARE(image->type(), ColorType::UnsignedByte); CORRADE_COMPARE(std::string(reinterpret_cast(image->data()), 2*3),