Qt Editor: Disable vsync to avoid laggy viewports

qteditor
Sven Eberhardt 2016-03-28 23:10:10 -04:00
parent 6eecf34e18
commit 370b9cf898
1 changed files with 1 additions and 0 deletions

View File

@ -428,6 +428,7 @@ bool C4ConsoleGUIState::CreateConsoleWindow(C4AbstractApp *app)
format.setBlueBufferSize(8);
format.setDepthBufferSize(8);
format.setProfile(QSurfaceFormat::CoreProfile);
format.setSwapInterval(0); // turn off vsync because otherwise each viewport causes an extra 1/(refesh rate) delay
if (Config.Graphics.DebugOpenGL)
format.setOption(QSurfaceFormat::DebugContext);
QSurfaceFormat::setDefaultFormat(format);