Load QtQuick settings
ClosedPublic

Authored by davidedmundson on Sep 28 2017, 6:35 PM.

Details

Reviewers
graesslin
Group Reviewers
Plasma
Commits
R108:e7b183f886fb: Load QtQuick settings
Summary

Loads settings on whether QtQuick uses GL or software rendering

Aurorae needed a fix. The rest "just works" with up-to-date plasma framework.

Test Plan

Alt tabbed
Showed an OSD
Grepped kwin's QML for any custom shaders.
(which is the only part that doesn't work here)

Diff Detail

Repository
R108 KWin
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
davidedmundson created this revision.Sep 28 2017, 6:35 PM
Restricted Application added a project: KWin. · View Herald TranscriptSep 28 2017, 6:35 PM
Restricted Application added subscribers: KWin, kwin, plasma-devel. · View Herald Transcript
graesslin accepted this revision.Sep 29 2017, 3:50 PM
graesslin added a subscriber: graesslin.

Let's assume we use XRender or QPainter compositor: how can we switch to software in this case? In KWin that is before we load any QtQuick (at least on Wayland on X11 I'm not sure, Aurorae might be loaded before).

This revision is now accepted and ready to land.Sep 29 2017, 3:50 PM
davidedmundson edited the summary of this revision. (Show Details)Sep 29 2017, 4:07 PM

Let's assume we use XRender or QPainter compositor: how can we switch to software in this case? In KWin that is before we load any QtQuick (at least on Wayland on X11 I'm not sure, Aurorae might be loaded before).

Unlike scene we can't switch this at runtime; which means whatever we do we have to support all 4 combinations of GL/Software views into -> GL/Software views.

If you do want to set this based on the initial scene backend, skip using this method and call the static method on QQuickWindow instead.

If you do want to set this based on the initial scene backend, skip using this method and call the static method on QQuickWindow instead.

After reading through the docs I think the combination of both is fine: We can use the QtQuickSettings to have a base. But if we init a QPainter compositor we just enforce software through the QQuickWindow API. That should (TM) work as well. Dynamic switching is then not required. AFAIK the only "dangerous" combination would be QPainter compositor and OpenGL compositing. The other 3 combinations should just work fine.

This revision was automatically updated to reflect the committed changes.