OSDN Git Service

init.sh: fallback to SwiftShader if necessary
authorChih-Wei Huang <cwhuang@linux.org.tw>
Wed, 27 Nov 2019 13:57:19 +0000 (21:57 +0800)
committerChih-Wei Huang <cwhuang@linux.org.tw>
Thu, 28 Nov 2019 08:52:08 +0000 (16:52 +0800)
Use SwiftShader if HWACCEL=0 or there is no supported GPU.

init.sh

diff --git a/init.sh b/init.sh
index f759a1c..be676c3 100644 (file)
--- a/init.sh
+++ b/init.sh
@@ -198,6 +198,7 @@ function init_hal_gralloc()
                        ;;
        esac
 
+       [ -z "$(getprop ro.hardware.gralloc)" ] && set_property ro.hardware.egl swiftshader
        [ -n "$DEBUG" ] && set_property debug.egl.trace error
 }