Commit 37950e18 authored by Martin Schultz's avatar Martin Schultz
Browse files

fixed a

 setting in  CoreWidget, which still userd compatibility profile even when core profile was set via cmdline
parent 157d6dbf
......@@ -249,15 +249,21 @@ CoreWidget( QVector<ViewMode*>& _viewModes,
delete test;
// force the compatibility profile since OpenFlipper does not work with the
// Core profile
format.setProfile(OFGLFormat::CompatibilityProfile);
if (OpenFlipper::Options::coreProfile()) {
#if QT_VERSION >= 0x050000
// request the highest OpenGL version
// QT 5 should gracefully provide the next highest available version
format.setVersion(4,3);
// request the highest OpenGL version
// QT 5 should gracefully provide the next highest available version
format.setVersion(4, 0);
format.setProfile(OFGLFormat::CoreProfile);
#else
format.setProfile(OFGLFormat::CompatibilityProfile);
format.setOption(QSurfaceFormat::DeprecatedFunctions);
#endif
}
else {
format.setProfile(QSurfaceFormat::CompatibilityProfile);
format.setOption(QSurfaceFormat::DeprecatedFunctions);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment