rtpjitterbuffer: Compare ext RTP times, not plain RTP time and ext RTP time when calculating elapsed time

Otherwise all RTP times after a wraparound would be considered as going
backwards, they will always be smaller than the ext RTP time.
This commit is contained in:
Sebastian Dröge 2015-06-16 10:30:34 +02:00
parent f4e01b13ee
commit 62a7bcb395

View file

@ -2717,10 +2717,9 @@ compute_elapsed (GstRtpJitterBuffer * jitterbuffer, RTPJitterBufferItem * item)
GST_LOG_OBJECT (jitterbuffer, "rtp %" G_GUINT32_FORMAT ", ext %"
G_GUINT64_FORMAT, rtp_time, priv->ext_timestamp);
if (rtp_time < priv->ext_timestamp) {
ext_time = gst_rtp_buffer_ext_timestamp (&priv->ext_timestamp, rtp_time);
if (ext_time < priv->ext_timestamp) {
ext_time = priv->ext_timestamp;
} else {
ext_time = gst_rtp_buffer_ext_timestamp (&priv->ext_timestamp, rtp_time);
}
if (ext_time > priv->clock_base)