From d4e4d02774c642df1df62e021aa1e09b8151e4f3 Mon Sep 17 00:00:00 2001 From: Oliver Smith Date: Tue, 27 Nov 2018 08:52:33 +0100 Subject: [PATCH] pmos-ui-plasma-mobile: enable software rendering When rendering on framebuffer, always do software rendering. This should make it possible to boot up Plasma Mobile on most devices with downstream kernels, although terribly slow. Still better than a black screen though. Tested and working on the samsung-i9100. We can improve the code and possibly make the rendering mode configurable per device once we experimented more with: * llvmpipe vs. softpipe on various devices * armv7 (around the corner in Alpine) * a proper display manager like lightdm --- main/postmarketos-ui-plasma-mobile/APKBUILD | 6 +++--- main/postmarketos-ui-plasma-mobile/start_plasma.sh | 6 ++++++ 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/main/postmarketos-ui-plasma-mobile/APKBUILD b/main/postmarketos-ui-plasma-mobile/APKBUILD index 776f72f61..c36d80c39 100644 --- a/main/postmarketos-ui-plasma-mobile/APKBUILD +++ b/main/postmarketos-ui-plasma-mobile/APKBUILD @@ -1,7 +1,7 @@ pkgname=postmarketos-ui-plasma-mobile pkgver=1 -pkgrel=19 -pkgdesc="(Wayland) Mobile variant of KDE Plasma, optimized for touchscreen (aarch64, x86_64 or hardware acceleration required!)" +pkgrel=20 +pkgdesc="(Wayland) Mobile variant of KDE Plasma, optimized for touchscreen (slow without hardware acceleration!)" url="https://wiki.postmarketos.org/wiki/Plasma_Mobile" arch="noarch" license="GPL3+" @@ -33,7 +33,7 @@ package() { install -D -m644 "$srcdir"/org.kde.phone.homescreen.js \ "$pkgdir"/usr/share/plasma/look-and-feel/org.kde.plasma.phone/contents/plasmoidsetupscripts/org.kde.phone.homescreen.js } -sha512sums="fc3b0d988b5de786557cdbaa4cf5fa2fb59df09e2e671d73782941c0d8eb31f4a36df2683ce4cfab269298d3c7eb7a806a0fd0528b1662c1aa661df3c99ea852 start_plasma.sh +sha512sums="ccc27798d579470f5323f5b60cb43326348571b0012bf3d8bfbe86830d08837b3290d831c319228599ec4352592c3ffcb0d6d359deb1b186592678f3d0619c3a start_plasma.sh a95d3bbd1e8051c9b394ad7a26e4beb2d1be8d3c38189819da61fd42b1c7fd3948c4737bc9246eee23eaf5fd9451cd6362fb06442f3d8f967f930d3bcc5cfbe9 kwinrc 8eb0a095cd6e8cf693af212d57c0b99c74f39636d8f4f391561197ec662a7ca4dd5648aa74bb8ac5f088d8baf2bde976567c333f98db708e19f6ed7839d6b6fe kdeglobals 341f0b866c315f37868ef3e7137cce8b53a0e8e6164e5af71b3e8e2fa68321afbf0652d76124ef84bade1393f701748852ac939aef9daff7e272a0df827780eb qtlogging.ini diff --git a/main/postmarketos-ui-plasma-mobile/start_plasma.sh b/main/postmarketos-ui-plasma-mobile/start_plasma.sh index e4fb760c3..e7acae955 100644 --- a/main/postmarketos-ui-plasma-mobile/start_plasma.sh +++ b/main/postmarketos-ui-plasma-mobile/start_plasma.sh @@ -25,7 +25,13 @@ if test -z "${XDG_RUNTIME_DIR}"; then if [ -d "/dev/dri" ]; then ck-launch-session kwin_wayland --drm --xwayland plasma-phone 2>&1 | logger -t "$(whoami):plasma-mobile" else + # NOTE: using GALLIUM_DRIVER=llvmpipe might give you better performance (or not work at all.) + # If it does give you a performance gain, please open an issue to discuss how to implement this properly. + export GALLIUM_DRIVER=softpipe export KWIN_COMPOSE=Q + export LIBGL_ALWAYS_SOFTWARE=1 + + echo "start_plasma.sh: using software rendering with: ${GALLIUM_DRIVER}" | logger -t "$(whoami):plasma-mobile" ck-launch-session kwin_wayland --framebuffer --xwayland plasma-phone 2>&1 | logger -t "$(whoami):plasma-mobile" fi fi