summaryrefslogtreecommitdiffstats
path: root/examples/qt3d
diff options
context:
space:
mode:
authorMike Krus <mike.krus@kdab.com>2020-04-27 11:56:17 +0100
committerPaul Lemire <paul.lemire@kdab.com>2020-05-06 15:29:54 +0200
commit764924da8ab3255c1b8d1ad5b39f85675f4b855e (patch)
treec7b3e9d94318fd347ef2717feb5b539f5c18ff13 /examples/qt3d
parent9838d91e2d433f13c57bdae48e31ba0b909988aa (diff)
Fix build for Qt6
- updated dependencies, excluding qtgamepad for now - fixed issues with Q_PROPERTY not supporting forward declarations - fixed for changes in QtQuick private API - fixed for changes in QtOpenGLVersionFunctions API - fixed for removal of QT_OPENGL_ES* macros - fixed for changes in QtConcurrent API - fixed RHI based build Change-Id: I42ccd2f101b7f0a78e2860c6d551722bf6710a11 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
Diffstat (limited to 'examples/qt3d')
-rw-r--r--examples/qt3d/advancedcustommaterial/main.cpp2
-rw-r--r--examples/qt3d/scene3d/main.cpp2
-rw-r--r--examples/qt3d/simple-cpp/orbittransformcontroller.h6
-rw-r--r--examples/qt3d/simplecustommaterial/main.cpp2
4 files changed, 5 insertions, 7 deletions
diff --git a/examples/qt3d/advancedcustommaterial/main.cpp b/examples/qt3d/advancedcustommaterial/main.cpp
index 631e26e43..eef254063 100644
--- a/examples/qt3d/advancedcustommaterial/main.cpp
+++ b/examples/qt3d/advancedcustommaterial/main.cpp
@@ -55,7 +55,7 @@
void setSurfaceFormat()
{
QSurfaceFormat format;
-#ifdef QT_OPENGL_ES_2
+#if QT_CONFIG(opengles2)
format.setRenderableType(QSurfaceFormat::OpenGLES);
#else
if (QOpenGLContext::openGLModuleType() == QOpenGLContext::LibGL) {
diff --git a/examples/qt3d/scene3d/main.cpp b/examples/qt3d/scene3d/main.cpp
index 2a988a271..4d22a5b68 100644
--- a/examples/qt3d/scene3d/main.cpp
+++ b/examples/qt3d/scene3d/main.cpp
@@ -56,7 +56,7 @@ int main(int argc, char **argv)
{
// Set OpenGL requirements
QSurfaceFormat format = QSurfaceFormat::defaultFormat();
-#ifndef QT_OPENGL_ES_2
+#if !QT_CONFIG(opengles2)
format.setVersion(4, 1);
format.setProfile(QSurfaceFormat::CoreProfile);
format.setSamples(4);
diff --git a/examples/qt3d/simple-cpp/orbittransformcontroller.h b/examples/qt3d/simple-cpp/orbittransformcontroller.h
index 5f41722b6..7a6e8b819 100644
--- a/examples/qt3d/simple-cpp/orbittransformcontroller.h
+++ b/examples/qt3d/simple-cpp/orbittransformcontroller.h
@@ -55,11 +55,9 @@
#include <QObject>
#include <QMatrix4x4>
-QT_BEGIN_NAMESPACE
+#include <Qt3DCore/qtransform.h>
-namespace Qt3DCore {
-class QTransform;
-}
+QT_BEGIN_NAMESPACE
class OrbitTransformController : public QObject
{
diff --git a/examples/qt3d/simplecustommaterial/main.cpp b/examples/qt3d/simplecustommaterial/main.cpp
index 6ccdcce64..da299e913 100644
--- a/examples/qt3d/simplecustommaterial/main.cpp
+++ b/examples/qt3d/simplecustommaterial/main.cpp
@@ -55,7 +55,7 @@
void setSurfaceFormat()
{
QSurfaceFormat format;
-#ifdef QT_OPENGL_ES_2
+#if QT_CONFIG(opengles2)
format.setRenderableType(QSurfaceFormat::OpenGLES);
#else
if (QOpenGLContext::openGLModuleType() == QOpenGLContext::LibGL) {