mirror of https://github.com/PCSX2/pcsx2.git
gsdx:EGL: prefer EGL over GLX + add some error messages
This commit is contained in:
parent
84e6fb45e8
commit
2f9d5334ee
|
@ -310,10 +310,11 @@ static int _GSopen(void** dsp, char* title, int renderer, int threads = -1)
|
|||
break;
|
||||
}
|
||||
#else
|
||||
wnd[0] = new GSWndOGL();
|
||||
#ifdef EGL_SUPPORTED
|
||||
wnd[1] = new GSWndEGL();
|
||||
wnd[0] = new GSWndEGL();
|
||||
wnd[1] = new GSWndOGL();
|
||||
#else
|
||||
wnd[0] = new GSWndOGL();
|
||||
wnd[1] = NULL;
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -58,7 +58,7 @@ void GSWndEGL::CreateContext(int major, int minor)
|
|||
eglChooseConfig(m_eglDisplay, attrList, &eglConfig, 1, &numConfigs);
|
||||
if ( numConfigs == 0 )
|
||||
{
|
||||
fprintf(stderr,"EGL: Failed to get a frame buffer config!\n");
|
||||
fprintf(stderr,"EGL: Failed to get a frame buffer config! (0x%x)\n", eglGetError() );
|
||||
throw GSDXRecoverableError();
|
||||
}
|
||||
|
||||
|
@ -283,11 +283,15 @@ void GSWndEGL::OpenEGLDisplay()
|
|||
{
|
||||
// Create an EGL display from the native display
|
||||
m_eglDisplay = eglGetDisplay((EGLNativeDisplayType)m_NativeDisplay);
|
||||
if ( m_eglDisplay == EGL_NO_DISPLAY )
|
||||
if ( m_eglDisplay == EGL_NO_DISPLAY ) {
|
||||
fprintf(stderr,"EGL: Failed to open a display! (0x%x)\n", eglGetError() );
|
||||
throw GSDXRecoverableError();
|
||||
}
|
||||
|
||||
if ( !eglInitialize(m_eglDisplay, NULL, NULL) )
|
||||
if ( !eglInitialize(m_eglDisplay, NULL, NULL) ) {
|
||||
fprintf(stderr,"EGL: Failed to initialize the display! (0x%x)\n", eglGetError() );
|
||||
throw GSDXRecoverableError();
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue