diff options
author | aavit <qt-info@nokia.com> | 2010-11-03 12:39:14 (GMT) |
---|---|---|
committer | aavit <qt-info@nokia.com> | 2010-11-03 12:39:14 (GMT) |
commit | 6aec74aba05e4288c64860e7fa698ec1ae7939dc (patch) | |
tree | b0b9d52a2f6573156bd663f57385010e605f294d /tests/auto | |
parent | 67a02b1c2e73e76604aa24836a768673992e48d3 (diff) | |
download | Qt-6aec74aba05e4288c64860e7fa698ec1ae7939dc.zip Qt-6aec74aba05e4288c64860e7fa698ec1ae7939dc.tar.gz Qt-6aec74aba05e4288c64860e7fa698ec1ae7939dc.tar.bz2 |
Fix compilation for when there is no OpenGL module
Diffstat (limited to 'tests/auto')
-rw-r--r-- | tests/auto/lancelot/tst_lancelot.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/auto/lancelot/tst_lancelot.cpp b/tests/auto/lancelot/tst_lancelot.cpp index 03bee42..a06a251 100644 --- a/tests/auto/lancelot/tst_lancelot.cpp +++ b/tests/auto/lancelot/tst_lancelot.cpp @@ -46,7 +46,9 @@ #include <baselineprotocol.h> #include <QHash> +#ifndef QT_NO_OPENGL #include <QtOpenGL> +#endif #ifndef SRCDIR #define SRCDIR "." @@ -82,8 +84,10 @@ private slots: void testRasterRGB16_data(); void testRasterRGB16(); +#ifndef QT_NO_OPENGL void testOpenGL_data(); void testOpenGL(); +#endif }; tst_Lancelot::tst_Lancelot() @@ -170,6 +174,7 @@ void tst_Lancelot::testRasterRGB16() } +#ifndef QT_NO_OPENGL void tst_Lancelot::testOpenGL_data() { QStringList localBlacklist = QStringList() << QLatin1String("rasterops.qps"); @@ -196,6 +201,7 @@ void tst_Lancelot::testOpenGL() else QSKIP("System under test does not meet preconditions for GL testing. Skipping.", SkipAll); } +#endif bool tst_Lancelot::setupTestSuite(ImageItem::GraphicsEngine engine, QImage::Format format, const QStringList& blacklist) @@ -262,6 +268,7 @@ ImageItem tst_Lancelot::render(const ImageItem &item) paint(&img, script, QFileInfo(filePath).absoluteFilePath()); // eh yuck (filePath stuff) res.image = img; res.imageChecksums.append(ImageItem::computeChecksum(img)); +#ifndef QT_NO_OPENGL } else if (item.engine == ImageItem::OpenGL) { QGLWidget glWidget; if (glWidget.isValid()) { @@ -274,6 +281,7 @@ ImageItem tst_Lancelot::render(const ImageItem &item) res.image = fbo.toImage().convertToFormat(item.renderFormat); res.imageChecksums.append(ImageItem::computeChecksum(res.image)); } +#endif } return res; |