Home » Android » Android: how to exclude devices with webview that doesn't support webGL, i.e. are on the gpu_blacklist

Android: how to exclude devices with webview that doesn't support webGL, i.e. are on the gpu_blacklist

Posted by: admin May 14, 2020 Leave a comment

Questions:

I have an app containing a webview, that runs very poorly on devices where hardware acceleration doesn’t work, e.g. some Samsung S4’s running 5.0.1

I know from here:
Supporting WebGL on Android 5's WebView
that I can use Crosswalk and ignore the gpu blacklist, so that it will run smoothly.

However, this library causes other problems in the app, and- the blacklist is there for a reason right?

What I would like to do is exclude devices where webgl doesn’t work for whatever reason. I’ve looked here:
https://developer.android.com/google/play/filters.html
but I’m not sure if there is a way to specify this.

How to&Answers:

I don’t think filtering out devices without webGL is good idea. In fact your goal should be more and more devices install your app.

You should let everyone install your App and then when users try to run it and their device doesn’t support webGL then you should show an alert telling them to troubleshoot this problem by them self.
If troubleshoot is not possible let them know why they cant use your app.

  • How to detect webGL support can found here

  • How to enable WebGL in Browser can found here, I have already answer this for Android in this thread