I have a Qt code for an 3D application developed with OpenGL. I'm trying to build/run the Qt application with QtCreator but I'm getting the following error:
Error in compiling shader.
0:1(10): error: GLSL 3.30 is not supported. Supported versions are: 1.10, 1.20, 1.30, 1.00 ES, 3.00 ES, 3.10 ES, and 3.20 ES
I tried adding the following to my code as suggested by this answer:
QSurfaceFormat glFormat;
glFormat.setVersion(3, 3);
glFormat.setProfile(QSurfaceFormat::CoreProfile);
QSurfaceFormat::setDefaultFormat(glFormat);
Actually the above code worked, I mean the error got resolved. However, when application is running, it doesn't show/render any 3D content. For example when importing a STL file into the Qt application, the STL content is not shown. Did anybody run into a similar issue?