summaryrefslogtreecommitdiff
path: root/opengl/java/javax
diff options
context:
space:
mode:
authorJack Palevich <jackpal@google.com>2012-03-29 12:23:57 -0700
committerJack Palevich <jackpal@google.com>2012-03-29 12:23:57 -0700
commitdb6c78b5bdf264abe8f6de97f67ca5e90fb6a05a (patch)
treecf23eb1f3affd7590cc1ac34d8f53bd66d4814e7 /opengl/java/javax
parentdb2026000a1d832b60d73e0a046bc8137fbb1960 (diff)
Make GLSurfaceView handle eglSwapBuffers errors more robustly.
A careful reading of the EGL spec, as well as experience with many different EGL drivers, has shown that it is error prone to attempt to discriminate between different error conditions. We now treat any error besides EGL_CONTEXT_LOST as an indication that the EGL context is in a bad state, most likely due to the window manager having removed the underlying surface flinger surface. In addition, we changed the way we deal with this kind of error: Previously we would ignore the error and keep rendering. But if the EGL context and surface has become invalid, it would be better to stop drawing. We now stop drawing until the surface view surface is recreated. See b/6032663 for an example of this problem affecting the GMM app, but note that GMM is using their own version of GLSurfaceView, so this change won't help them directly. They'll have to make a similar change to their version of GLSurfaceView. Change-Id: Iffe3e1e3a3c7a91d03140fd34391eadeaecf777e Signed-off-by: Jack Palevich <jackpal@google.com>
Diffstat (limited to 'opengl/java/javax')
0 files changed, 0 insertions, 0 deletions