wayland: Also force qtquick to use OpenGL when using OpenGL compositing
Ideally they should match. If kwin uses software renderer, qtquick should too. If kwin uses OpenGL, then qtquick should a hardware accelerated graphics api too.
This commit is contained in:
parent
92bbfbc233
commit
647790b44c
1 changed files with 8 additions and 2 deletions
|
@ -175,9 +175,15 @@ void WaylandCompositor::start()
|
|||
if (m_selectedCompositor == NoCompositing) {
|
||||
m_selectedCompositor = m_backend->compositingType();
|
||||
|
||||
// Force qtquick to software rendering if kwin uses software rendering too.
|
||||
if (m_selectedCompositor == QPainterCompositing) {
|
||||
switch (m_selectedCompositor) {
|
||||
case NoCompositing:
|
||||
break;
|
||||
case OpenGLCompositing:
|
||||
QQuickWindow::setGraphicsApi(QSGRendererInterface::OpenGL);
|
||||
break;
|
||||
case QPainterCompositing:
|
||||
QQuickWindow::setGraphicsApi(QSGRendererInterface::Software);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue