PixelPicoSean Posted July 24, 2018 Share Posted July 24, 2018 Hi I just built a game with Phaser3 (3.10.1) and wrapped with cordova crosswalk (2.4.0), the screen keeps blinking while running on some Android devices. It works pretty well on most devices and even without any issue in the browser instead of cordova from same device. Anyone has similar experience? Link to comment Share on other sites More sharing options...
Milton Posted July 24, 2018 Share Posted July 24, 2018 Maybe try it without crosswalk? Since the browser webview works... Link to comment Share on other sites More sharing options...
Antriel Posted July 25, 2018 Share Posted July 25, 2018 I heard setting `preserveDrawingBuffer` to true can help in webgl for older devices. Not sure if that applies to cordova, but worth a try. For phaser you can set it in the game config `{ render: { preserveDrawingBuffer: true } }`. Link to comment Share on other sites More sharing options...
Tom Atom Posted July 25, 2018 Share Posted July 25, 2018 You can look at this topic: http://www.html5gamedevs.com/topic/25507-phaserwebgl-flickering-on-chrome-for-android-v53/ Setting preserveDrawingBuffer worked well, but for some devices, as I was reported by friends, it means big slowdown. Flickering is not caused by browser, but appears on devices with certain GPU. Here is list: Mali-400, Mali-450, Mediatek MT6582 List probably is not complete, so It would be good to add next GPUs if discovered. You can detect GPU on device like this: https://gist.github.com/cvan/042b2448fcecefafbb6a91469484cdf8 - I did not test it yet, but I am about to, as I have to make changes into one of our games. If you detected "bad" GPU, solution for Phaser 2 was to start game in Canvas rendering. Unfortunately Phaser 3 (3.11.0) is not ready for this yet. There are some fatures currently not supported in Canvas (tint - I added issue on GitHub with solution to support it at least for BitmapText - https://github.com/photonstorm/phaser/issues/3855 or at blog: http://sbcgames.io/category/blog/) and some are not working (RenderTexture - issue from yesterday - again with solution: https://github.com/photonstorm/phaser/issues/3862) So, you have two options: - use preserveDrawingBuffer and some devices may be really slow, - switch to canvas for some devices. If you do not need tint or render textures, you are happy and can switch without fixes. Otherwise, you may apply fixes and make your build. Link to comment Share on other sites More sharing options...
PixelPicoSean Posted July 25, 2018 Author Share Posted July 25, 2018 Thank you all for the reply, I am trying the preserveDrawingBuffer fix and see whether it works. The phone that has this issues is Zenphone Z00VD. Link to comment Share on other sites More sharing options...
Tom Atom Posted July 26, 2018 Share Posted July 26, 2018 @PixelPicoSean hmmm... it is Mali-400 (https://www.gsmarena.com/asus_zenfone_go_zc500tg-7368.php). Let us know, about results! Link to comment Share on other sites More sharing options...
Recommended Posts