egl: treat EGL_OPENGL_API as invalid on Android

At the moment one can use OpenGL in eglBindAPI() only to clear the
EGL_OPENGL_BIT from RenderableType and Conformant for _each_ config.

Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Tomasz Figa <tfiga@chromium.org>
This commit is contained in:
Emil Velikov 2016-08-25 12:02:07 +01:00 committed by Emil Velikov
parent a165e5cb7c
commit 7563c39641

View file

@ -69,7 +69,13 @@ struct _egl_thread_info
static inline EGLBoolean
_eglIsApiValid(EGLenum api)
{
return (api >= _EGL_API_FIRST_API && api <= _EGL_API_LAST_API);
#ifdef ANDROID
/* OpenGL is not a valid/supported API on Android */
return api >= _EGL_API_FIRST_API && api <= _EGL_API_LAST_API &&
api != EGL_OPENGL_API;
#else
return api >= _EGL_API_FIRST_API && api <= _EGL_API_LAST_API;
#endif
}