From 627a965d69104652f28d443922225402c883e62d Mon Sep 17 00:00:00 2001 From: baldurk Date: Fri, 11 May 2018 13:07:54 +0100 Subject: [PATCH] Specify GLES2 renderable type when fetching egl config * Fixes preview display on PowerVR --- renderdoccmd/renderdoccmd_android.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/renderdoccmd/renderdoccmd_android.cpp b/renderdoccmd/renderdoccmd_android.cpp index 898150969..3e439f943 100644 --- a/renderdoccmd/renderdoccmd_android.cpp +++ b/renderdoccmd/renderdoccmd_android.cpp @@ -101,6 +101,7 @@ void DisplayGenericSplash() DLSYM_GET(eglBindAPI); DLSYM_GET(eglGetDisplay); DLSYM_GET(eglInitialize); + DLSYM_GET(eglGetError); DLSYM_GET(eglChooseConfig); DLSYM_GET(eglCreateContext); DLSYM_GET(eglCreateWindowSurface); @@ -147,6 +148,8 @@ void DisplayGenericSplash() EGL_WINDOW_BIT, EGL_COLOR_BUFFER_TYPE, EGL_RGB_BUFFER, + EGL_RENDERABLE_TYPE, + EGL_OPENGL_ES2_BIT, EGL_NONE}; EGLint numConfigs; @@ -277,7 +280,7 @@ void main() } else { - ANDROID_LOG("failed making surface"); + ANDROID_LOG("failed making surface: %x", eglGetError()); } eglMakeCurrent(eglDisplay, 0L, 0L, NULL); @@ -286,7 +289,7 @@ void main() } else { - ANDROID_LOG("failed making context"); + ANDROID_LOG("failed making context: %x", eglGetError()); } } else