viewer: run queue if windows are still active

Fixes #1628
This commit is contained in:
itsmattkc
2021-05-12 11:10:08 +10:00
parent 72d5b4af86
commit 58d062ad75
2 changed files with 9 additions and 1 deletions
+7 -1
View File
@@ -605,7 +605,7 @@ void ViewerWidget::PlayInternal(int speed, bool in_to_out_only)
controls_->ShowPauseButton();
// Attempt to fill playback queue
if (display_widget_->isVisible()) {
if (display_widget_->isVisible() || !windows_.isEmpty()) {
prequeue_length_ = DeterminePlaybackQueueSize();
if (prequeue_length_ > 0) {
@@ -1243,6 +1243,12 @@ void ViewerWidget::PlaybackTimerUpdate()
if (display_widget_->isVisible()) {
// Updating display widget
UpdateTextureFromNode();
} else if (!windows_.empty()) {
// We still run the queue if windows are visible even if our own display widget isn't visible
rational t = GetTime();
while (!playback_queue_.empty() && playback_queue_.front().timestamp != t) {
PopOldestFrameFromPlaybackQueue();
}
}
}
+2
View File
@@ -119,6 +119,8 @@ void ViewerWindow::UpdateFromQueue()
queue_.pop_front();
}
}
display_widget_->update();
}
void ViewerWindow::UpdateMatrix()