fix: black screen during playback
renderer_generated_frame_for_queue pushed a raw void* QVariant into the display queue, but on_paint only unwraps OakSharedBufferPtr; the unwrap failed and the widget painted blank. Paused display worked because set_display_image wraps with oak_make_shared_frame. Wrap the queued frames the same way. Also adds env-gated OAK_DEBUG_PLAYBACK diagnostics.
This commit is contained in:
@@ -1854,6 +1854,16 @@ void ViewerDisplayWidget::update_from_queue()
|
||||
|
||||
Rational time = Timecode::timestamp_to_time(t, playback_timebase_);
|
||||
|
||||
if (qEnvironmentVariableIsSet("OAK_DEBUG_PLAYBACK")) {
|
||||
qWarning("PLAYBACK-DEBUG: update_from_queue t=%lld time=%lld/%lld qlen=%d front_ts=%s",
|
||||
(long long)t, (long long)time.numerator(),
|
||||
(long long)time.denominator(), int(queue_.size()),
|
||||
queue_.empty() ? "-" : qPrintable(QStringLiteral("%1/%2").arg(
|
||||
queue_.front().timestamp.numerator())
|
||||
.arg(
|
||||
queue_.front().timestamp.denominator())));
|
||||
}
|
||||
|
||||
bool popped = false;
|
||||
|
||||
if (queue_.empty()) {
|
||||
|
||||
Reference in New Issue
Block a user