From 83fb4f6743860bfb746e6243aad00513d498db4f Mon Sep 17 00:00:00 2001 From: Paul Olav Tvete Date: Tue, 16 Jun 2020 17:03:47 +0200 Subject: Clean up QT_CONFIG(opengl) Accelerated graphics is now possible without OpenGL support. With this change, a Qt build with -no-opengl can still run Qt Quick with a Vulkan, Metal, or Direct3D backend. Fixes: QTBUG-84027 Change-Id: Ib63c733d28cfdf7de16b138df136fa7628e1747b Reviewed-by: Laszlo Agocs --- src/quick/items/qquickrendercontrol.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'src/quick/items/qquickrendercontrol.cpp') diff --git a/src/quick/items/qquickrendercontrol.cpp b/src/quick/items/qquickrendercontrol.cpp index 53c0b6b731..51483bce57 100644 --- a/src/quick/items/qquickrendercontrol.cpp +++ b/src/quick/items/qquickrendercontrol.cpp @@ -203,8 +203,7 @@ void QQuickRenderControlPrivate::windowDestroyed() rc->invalidate(); QQuickWindowPrivate::get(window)->animationController.reset(); -// ### Qt 6 clean this up -#if QT_CONFIG(quick_shadereffect) && QT_CONFIG(opengl) +#if QT_CONFIG(quick_shadereffect) QSGRhiShaderEffectNode::cleanupMaterialTypeCache(); #endif window = nullptr; @@ -281,8 +280,6 @@ int QQuickRenderControl::samples() const bool QQuickRenderControl::initialize() { Q_D(QQuickRenderControl); -// ### Qt 6 clean this up -#if QT_CONFIG(opengl) if (!d->window) { qWarning("QQuickRenderControl::initialize called with no associated window"); return false; @@ -306,7 +303,6 @@ bool QQuickRenderControl::initialize() qWarning("QRhi is only compatible with default adaptation"); return false; } -#endif return true; } -- cgit v1.2.3