mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 12:11:13 +00:00
qtmux: Make sure to only change DTS of writable buffers
And trivial cleanup https://bugzilla.gnome.org/show_bug.cgi?id=774840
This commit is contained in:
parent
01e45b25b7
commit
01682ae95b
1 changed files with 2 additions and 2 deletions
|
@ -3239,6 +3239,7 @@ gst_qt_mux_add_buffer (GstQTMux * qtmux, GstQTPad * pad, GstBuffer * buf)
|
|||
GST_ERROR ("decreasing DTS value %" GST_TIME_FORMAT " < %" GST_TIME_FORMAT,
|
||||
GST_TIME_ARGS (GST_BUFFER_DTS (buf)),
|
||||
GST_TIME_ARGS (GST_BUFFER_DTS (last_buf)));
|
||||
buf = gst_buffer_make_writable (buf);
|
||||
GST_BUFFER_DTS (buf) = GST_BUFFER_DTS (last_buf);
|
||||
}
|
||||
|
||||
|
@ -3399,8 +3400,7 @@ gst_qt_mux_add_buffer (GstQTMux * qtmux, GstQTPad * pad, GstBuffer * buf)
|
|||
if (pad->create_empty_buffer) {
|
||||
GstBuffer *empty_buf;
|
||||
gint64 empty_duration =
|
||||
GST_BUFFER_TIMESTAMP (buf) - (GST_BUFFER_TIMESTAMP (last_buf) +
|
||||
duration);
|
||||
GST_BUFFER_PTS (buf) - (GST_BUFFER_PTS (last_buf) + duration);
|
||||
gint64 empty_duration_scaled;
|
||||
|
||||
empty_buf = pad->create_empty_buffer (pad, empty_duration);
|
||||
|
|
Loading…
Reference in a new issue