opengl: use compatibility profile

The GLSL shaders are written in GLSL 1.10 even though the OpenGL standard is
set to OpenGL ES 3.2 Core. Many platforms allow this but some platforms don't.
For standards compliance, it's probably a good idea in the future to upgrade
the shaders to 3.2, but for now we'll use 3.2 Compatibility which will allow the
GLSL 1.10 shaders to compile.
This commit is contained in:
itsmattkc
2020-04-21 02:49:17 +10:00
parent 0ced48d4df
commit baa8df38f6
+1 -1
View File
@@ -47,7 +47,7 @@ int main(int argc, char *argv[]) {
QSurfaceFormat format;
format.setVersion(3, 2);
format.setDepthBufferSize(24);
format.setProfile(QSurfaceFormat::CoreProfile);
format.setProfile(QSurfaceFormat::CompatibilityProfile);
QSurfaceFormat::setDefaultFormat(format);
// Try to share OpenGL contexts