rtpjitterbuffer: do not drop serialized events when latency is set

Serialized events are now queued in the jitter buffer, so we don't
want to drop them even latency is set.

https://bugzilla.gnome.org/show_bug.cgi?id=722372
This commit is contained in:
Aleix Conchillo Flaqué 2014-01-16 17:36:12 -08:00 committed by Sebastian Dröge
parent 447556fe6b
commit cdbb2ba6b8

View file

@ -2210,11 +2210,16 @@ gst_rtp_jitter_buffer_chain (GstPad * pad, GstObject * parent,
if (G_UNLIKELY (rtp_jitter_buffer_get_ts_diff (priv->jbuf) >= latency_ts)) {
RTPJitterBufferItem *old_item;
old_item = rtp_jitter_buffer_pop (priv->jbuf, &percent);
GST_DEBUG_OBJECT (jitterbuffer, "Queue full, dropping old packet %p",
old_item);
priv->next_seqnum = (old_item->seqnum + 1) & 0xffff;
free_item (old_item);
old_item = rtp_jitter_buffer_peek (priv->jbuf);
/* only drop non-event buffers */
if (old_item->type != ITEM_TYPE_EVENT) {
old_item = rtp_jitter_buffer_pop (priv->jbuf, &percent);
GST_DEBUG_OBJECT (jitterbuffer, "Queue full, dropping old packet %p",
old_item);
priv->next_seqnum = (old_item->seqnum + 1) & 0xffff;
free_item (old_item);
}
}
}