fmt.setProfile(QSurfaceFormat::CoreProfile);
fmt.setMajorVersion(3);
fmt.setMinorVersion(1);
+
+ // Turn off vsync, since Qt generally gives us at most frame rate
+ // (display frequency) / (number of QGLWidgets active).
+ fmt.setSwapInterval(0);
+
QSurfaceFormat::setDefaultFormat(fmt);
QGLFormat::setDefaultFormat(QGLFormat::fromSurfaceFormat(fmt));
fprintf(stderr, "Failed to lock Nageru into RAM. You probably want to\n");
fprintf(stderr, "increase \"memlock\" for your user in limits.conf\n");
fprintf(stderr, "for better realtime behavior.\n");
+ uses_mlock = false;
+ } else {
+ uses_mlock = true;
}
int rc = app.exec();