Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
How to test workstation OpenGL version with QSurfaceFormat?
Alchete last edited by
Our app runs across a variety of different workstations, some without proper graphics drivers installed, so I need to check the workstation opengl version before drawing anything.
In Qt 5.2, I had been using the following:
However, QGLFormat has been deprecated moving forward.
I'm probably missing something obvious, but in Qt 5.6 there doesn't appear to be an equivalent one-line check using QOpenGLWidget/QSurfaceFormat...
What's the recommended method to test how high an opengl level the workstation supports using QOpenGLWidget/QSurfaceFormat?
Rob P last edited by
QSurfaceFormat fmt(this->format()); cout << fmt.majorVersion() << "." << fmt.minorVersion() << endl;