Remove unused ifdef
The QEGL_DEBUG defines have been removed some time ago from eglfs and eglconvenience, except for this one. It is also inconvenient due to the OpenGL dependency of it. Quick apps can anyway get the same information with QSG_INFO=1. Change-Id: Ie25c5286234a10699652d618d6f4174c6d3238e2 Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>bb10
parent
11a6270079
commit
e7ad615cca
|
|
@ -268,37 +268,15 @@ bool QEGLPlatformContext::makeCurrent(QPlatformSurface *surface)
|
|||
return true;
|
||||
}
|
||||
|
||||
bool ok = eglMakeCurrent(m_eglDisplay, eglSurface, eglSurface, m_eglContext);
|
||||
if (!ok)
|
||||
qWarning("QEGLPlatformContext::makeCurrent: eglError: %x, this: %p \n", eglGetError(), this);
|
||||
#ifdef QEGL_EXTRA_DEBUG
|
||||
static bool showDebug = true;
|
||||
if (showDebug) {
|
||||
showDebug = false;
|
||||
const char *str = (const char*)glGetString(GL_VENDOR);
|
||||
qWarning("Vendor %s\n", str);
|
||||
str = (const char*)glGetString(GL_RENDERER);
|
||||
qWarning("Renderer %s\n", str);
|
||||
str = (const char*)glGetString(GL_VERSION);
|
||||
qWarning("Version %s\n", str);
|
||||
|
||||
str = (const char*)glGetString(GL_SHADING_LANGUAGE_VERSION);
|
||||
qWarning("Extensions %s\n",str);
|
||||
|
||||
str = (const char*)glGetString(GL_EXTENSIONS);
|
||||
qWarning("Extensions %s\n", str);
|
||||
|
||||
}
|
||||
#endif
|
||||
|
||||
const bool ok = eglMakeCurrent(m_eglDisplay, eglSurface, eglSurface, m_eglContext);
|
||||
if (ok) {
|
||||
if (!m_swapIntervalEnvChecked) {
|
||||
m_swapIntervalEnvChecked = true;
|
||||
if (qEnvironmentVariableIsSet("QT_QPA_EGLFS_SWAPINTERVAL")) {
|
||||
QByteArray swapIntervalString = qgetenv("QT_QPA_EGLFS_SWAPINTERVAL");
|
||||
bool ok;
|
||||
const int swapInterval = swapIntervalString.toInt(&ok);
|
||||
if (ok)
|
||||
bool intervalOk;
|
||||
const int swapInterval = swapIntervalString.toInt(&intervalOk);
|
||||
if (intervalOk)
|
||||
m_swapIntervalFromEnv = swapInterval;
|
||||
}
|
||||
}
|
||||
|
|
@ -309,6 +287,8 @@ bool QEGLPlatformContext::makeCurrent(QPlatformSurface *surface)
|
|||
m_swapInterval = requestedSwapInterval;
|
||||
eglSwapInterval(eglDisplay(), m_swapInterval);
|
||||
}
|
||||
} else {
|
||||
qWarning("QEGLPlatformContext::makeCurrent: eglError: %x, this: %p \n", eglGetError(), this);
|
||||
}
|
||||
|
||||
return ok;
|
||||
|
|
|
|||
Loading…
Reference in New Issue