summaryrefslogtreecommitdiff
path: root/gst
diff options
context:
space:
mode:
authorWim Taymans <wim.taymans@collabora.co.uk>2013-09-12 15:01:36 +0200
committerWim Taymans <wim.taymans@collabora.co.uk>2013-09-12 15:04:30 +0200
commit9f9ba21404035dc37fef642e1679a6898da5cb8e (patch)
treebeb3b42cd82083a43e8cbe7be25fa6ed60921829 /gst
parent9d3dbd6581f86e824627d5fe51391a099f853b7a (diff)
jitterbuffer: handle segments with non-0 start
We keep the DTS and PTS in running-time inside the jitterbuffer. Make sure to transform it back to a buffer timestamp before pushing out the buffer. Fixes https://bugzilla.gnome.org/show_bug.cgi?id=707931
Diffstat (limited to 'gst')
-rw-r--r--gst/rtpmanager/gstrtpjitterbuffer.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gst/rtpmanager/gstrtpjitterbuffer.c b/gst/rtpmanager/gstrtpjitterbuffer.c
index 079ae0ca7..632647637 100644
--- a/gst/rtpmanager/gstrtpjitterbuffer.c
+++ b/gst/rtpmanager/gstrtpjitterbuffer.c
@@ -2071,6 +2071,9 @@ pop_and_push_next (GstRtpJitterBuffer * jitterbuffer, guint16 seqnum)
dts = GST_BUFFER_DTS (outbuf);
pts = GST_BUFFER_PTS (outbuf);
+ dts = gst_segment_to_position (&priv->segment, GST_FORMAT_TIME, dts);
+ pts = gst_segment_to_position (&priv->segment, GST_FORMAT_TIME, pts);
+
/* apply timestamp with offset to buffer now */
GST_BUFFER_DTS (outbuf) = apply_offset (jitterbuffer, dts);
GST_BUFFER_PTS (outbuf) = apply_offset (jitterbuffer, pts);