Quantcast
Channel: Recent Threads — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 204402

AndroidGameView.Pause without losing GL context

$
0
0

Currently it always loses GL context when paused, but it's not necessary to do so in all cases. Some gpus will support multiple EGL contexts.

I'm part of the MonoGame team and have implemented reloading of textures on resume. This works but it's still a very poor user experience. The larger the game the longer it takes to resume and even showing a fullscreen ad causes the context to be lost and forces a long resume.

As far as I can tell, AndroidGameView plays a similar role to Android's built in GLSurfaceView. This class has the same problem. Newer SDKs offer 'setPreserveEGLContextOnPause' but people have fixed (or worked around) it in older SDKs by customising this class:

http://stackoverflow.com/questions/2112768/prevent-onpause-from-trashing-opengl-context/11167948#11167948

Can someone from Xamarin please take a look at whether doing something like this would be an option for AndroidGameView? Currently it seems that we are stuck with the reloading textures even on the latest SDKs.

Aranda


Viewing all articles
Browse latest Browse all 204402

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>