diff options
author | Qt Forward Merge Bot <qt_forward_merge_bot@qt-project.org> | 2019-08-08 01:00:08 +0200 |
---|---|---|
committer | Qt Forward Merge Bot <qt_forward_merge_bot@qt-project.org> | 2019-08-08 01:00:08 +0200 |
commit | 2b38408cbc23816034f087779d351f4db2ee4b1b (patch) | |
tree | c97a6881875331c7ef4b9aecf896434071382a46 /src/gui/kernel/qsurface.cpp | |
parent | 0ea7360eaa70c2b024a37b2ff9106531440cdee7 (diff) | |
parent | 36cc171b9314bf77fc84d4273dceb6264aef7134 (diff) |
Merge remote-tracking branch 'origin/5.12' into 5.13
Change-Id: I4c0fd501db974fb8339944b8df845336776d80a9
Diffstat (limited to 'src/gui/kernel/qsurface.cpp')
-rw-r--r-- | src/gui/kernel/qsurface.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gui/kernel/qsurface.cpp b/src/gui/kernel/qsurface.cpp index 415e64b39c..709f28d431 100644 --- a/src/gui/kernel/qsurface.cpp +++ b/src/gui/kernel/qsurface.cpp @@ -39,6 +39,8 @@ #include "qsurface.h" #include "qopenglcontext.h" +#include <qpa/qplatformintegration.h> +#include <QtGui/private/qguiapplication_p.h> QT_BEGIN_NAMESPACE @@ -103,6 +105,10 @@ QT_BEGIN_NAMESPACE bool QSurface::supportsOpenGL() const { SurfaceType type = surfaceType(); + if (type == RasterSurface) { + QPlatformIntegration *integ = QGuiApplicationPrivate::instance()->platformIntegration(); + return integ->hasCapability(QPlatformIntegration::OpenGLOnRasterSurface); + } return type == OpenGLSurface || type == RasterGLSurface; } |