diff options
author | Mitch Curtis <mitch.curtis@qt.io> | 2021-05-12 11:25:44 +0200 |
---|---|---|
committer | Mitch Curtis <mitch.curtis@qt.io> | 2021-05-12 09:51:53 +0000 |
commit | 7c6ae74e549df65e73a9aafc641e702dee969a5a (patch) | |
tree | d36c337582344c20acddad101f9b66ff3ab4d743 | |
parent | 4bf0cd983c2620fb7c3168e00317dc17123b0615 (diff) |
Fix build without Qt Quick 3D
Change-Id: I5e181231080bbd39077b3d8b2f2d6ff8cdbae8b2
Reviewed-by: Daniel Smith <Daniel.Smith@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
-rw-r--r-- | src/main.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main.cpp b/src/main.cpp index 667e25f..a2e3036 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -32,7 +32,9 @@ #include <QtCore> #include <QtGui> #include <QtQuick> +#ifdef QT_QUICK3D_LIB #include <QtQuick3D> +#endif #include "benchmark.h" #include "benchmarkrunner.h" @@ -250,8 +252,12 @@ void setupDefaultSurfaceFormat(int argc, char **argv, bool subprocess) } } +#ifdef QT_QUICK3D_LIB if (subprocess) QSurfaceFormat::setDefaultFormat(QQuick3D::idealSurfaceFormat()); +#else + Q_UNUSED(subprocess); +#endif if (frameCountShell) { QSurfaceFormat format = QSurfaceFormat::defaultFormat(); |