Merge pull request #6572 from howard-stearns/fix-render-rate

Fix render rate.
This commit is contained in:
Brad Davis 2015-12-07 14:12:54 -08:00
commit 353fe774ca

View file

@ -152,7 +152,14 @@ OpenGLDisplayPlugin::OpenGLDisplayPlugin() {
});
connect(&_timer, &QTimer::timeout, this, [&] {
#ifdef Q_OS_MAC
// On Mac, QT thread timing is such that we can miss one or even two cycles quite often, giving a render rate (including update/simulate)
// far lower than what we want. This hack keeps that rate more natural, at the expense of some wasted rendering.
// This is likely to be mooted by further planned changes.
if (_active && _sceneTextureEscrow.depth() <= 1) {
#else
if (_active && _sceneTextureEscrow.depth() < 1) {
#endif
emit requestRender();
}
});