From e7ad615cca2f4ae5383f1772b7c2845d59c4d68a Mon Sep 17 00:00:00 2001 From: Laszlo Agocs Date: Mon, 24 Mar 2014 19:58:58 +0100 Subject: Remove unused ifdef MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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 --- .../eglconvenience/qeglplatformcontext.cpp | 32 ++++------------------ 1 file changed, 6 insertions(+), 26 deletions(-) (limited to 'src/platformsupport') diff --git a/src/platformsupport/eglconvenience/qeglplatformcontext.cpp b/src/platformsupport/eglconvenience/qeglplatformcontext.cpp index 0dcb9f68bb..eec6463c21 100644 --- a/src/platformsupport/eglconvenience/qeglplatformcontext.cpp +++ b/src/platformsupport/eglconvenience/qeglplatformcontext.cpp @@ -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; -- cgit v1.2.3