浏览代码

Force use of core profile

Change-Id: I67fde4859b5d9939816efec3502a04ea69b9df36
Donald Carr 5 年之前
父节点
当前提交
3fa970047c
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      src/main.cpp

+ 2 - 0
src/main.cpp

@@ -237,6 +237,7 @@ int main(int argc, char *argv[])
 #endif
     } else {
         QSurfaceFormat format = QSurfaceFormat::defaultFormat();
+        format.setProfile(QSurfaceFormat::CoreProfile);
 
         bool force24bpp = settings.value("force24bpp", false).toBool();
         bool force16bpp = settings.value("force16bpp", false).toBool();
@@ -270,6 +271,7 @@ int main(int argc, char *argv[])
         settings.setValue("forceDoubleBuffer", forceDoubleBuffer);
         settings.setValue("forceTripleBuffer", forceTripleBuffer);
 
+        qDebug() << "Setting format" << format;
         QSurfaceFormat::setDefaultFormat(format);
     }