[Spice-devel] [PATCH spice-gtk] Update dropping frames debug messages
Snir Sheriber
ssheribe at redhat.com
Sun Jul 15 14:56:54 UTC 2018
Since non-mjpeg decoders are available in spice-gtk late frames
are not always dropped
---
In stats late frames are still counted & named as dropped meanwhile i
leave it as is.
---
src/channel-display-mjpeg.c | 1 +
src/channel-display.c | 3 ++-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/src/channel-display-mjpeg.c b/src/channel-display-mjpeg.c
index 7b2f775..6f7ded6 100644
--- a/src/channel-display-mjpeg.c
+++ b/src/channel-display-mjpeg.c
@@ -262,6 +262,7 @@ static gboolean mjpeg_decoder_queue_frame(VideoDecoder *video_decoder,
* So drop late frames as early as possible to save on processing time.
*/
if (latency < 0) {
+ SPICE_DEBUG("dropping a late MJPEG frame");
frame->free(frame);
return TRUE;
}
diff --git a/src/channel-display.c b/src/channel-display.c
index 44ba043..9a9bc99 100644
--- a/src/channel-display.c
+++ b/src/channel-display.c
@@ -1544,11 +1544,12 @@ static void display_handle_stream_data(SpiceChannel *channel, SpiceMsgIn *in)
latency = op->multi_media_time - mmtime;
if (latency < 0) {
- CHANNEL_DEBUG(channel, "stream data too late by %u ms (ts: %u, mmtime: %u), dropping",
+ CHANNEL_DEBUG(channel, "stream data too late by %u ms (ts: %u, mmtime: %u)",
mmtime - op->multi_media_time, op->multi_media_time, mmtime);
st->arrive_late_time += mmtime - op->multi_media_time;
st->arrive_late_count++;
+ /* Late frames are counted as drops in the stats but aren't necessarily dropped - depends on codec and decoder */
if (!st->cur_drops_seq_stats.len) {
st->cur_drops_seq_stats.start_mm_time = op->multi_media_time;
}
--
2.17.0
More information about the Spice-devel
mailing list