Check the EGL error before calling eglTerminate().
Otherwise we always get EGL_SUCCESS, which is not very informative. Change-Id: I25311c14108ae385913aa9dc159a1f5fad142342 Reviewed-by: Rainer Keller <rainer.keller@digia.com> Reviewed-by: Andy Nichols <andy.nichols@digia.com>
This commit is contained in:
parent
9dacccd039
commit
fe4068a12b
@ -89,8 +89,9 @@ void QEglFSWindow::create()
|
||||
m_window = hooks->createNativeWindow(hooks->screenSize(), m_format);
|
||||
m_surface = eglCreateWindowSurface(display, config, m_window, NULL);
|
||||
if (m_surface == EGL_NO_SURFACE) {
|
||||
EGLint error = eglGetError();
|
||||
eglTerminate(display);
|
||||
qFatal("EGL Error : Could not create the egl surface: error = 0x%x\n", eglGetError());
|
||||
qFatal("EGL Error : Could not create the egl surface: error = 0x%x\n", error);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user