Android: Fix OpenGL shader compilation on updated emulator

In 0ae4b948515af904dba397448839056d9b7965af, we added a work-around
specifically for the Android emulator, causing it to override the
precision qualifiers in shader code, since the emulator would send
the shader code directly to the host OpenGL driver and thus there
was no guarantee that the qualifiers would be supported.

Since then, the original issue with the emulator has been fixed,
so now Qt applications are failing because of the work-around.

[ChangeLog][Android] Removed old work-around which was causing
OpenGL shader compilation to fail on updated Android emulators.

Task-number: QTBUG-44697
Change-Id: I0da879b3a8fbe7cb2d0969cdf45664d0b3499891
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
This commit is contained in:
Eskil Abrahamsen Blomfeldt 2017-02-09 12:30:10 +01:00
parent 6282948e96
commit 440ccba0ab

View File

@ -98,10 +98,6 @@ bool QAndroidPlatformOpenGLContext::makeCurrent(QPlatformSurface *surface)
bool ret = QEGLPlatformContext::makeCurrent(surface);
QOpenGLContextPrivate *ctx_d = QOpenGLContextPrivate::get(context());
const char *rendererString = reinterpret_cast<const char *>(glGetString(GL_RENDERER));
if (rendererString != 0 && qstrncmp(rendererString, "Android Emulator", 16) == 0)
ctx_d->workaround_missingPrecisionQualifiers = true;
if (!ctx_d->workaround_brokenFBOReadBack && needsFBOReadBackWorkaround())
ctx_d->workaround_brokenFBOReadBack = true;