decklinkaudiosrc: Fix duration of the first audio frame after each discont

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1886>
This commit is contained in:
Sebastian Dröge 2020-12-16 18:32:25 +02:00 committed by GStreamer Merge Bot
parent 8af91be222
commit 70facfa8d3

View file

@ -654,6 +654,8 @@ retry:
// Convert to the sample numbers
start_offset =
gst_util_uint64_scale (start_time, self->info.rate, GST_SECOND);
// Convert back to round down to a sample multiple and get rid of rounding errors
start_time = gst_util_uint64_scale (start_offset, GST_SECOND, self->info.rate);
end_offset = start_offset + sample_count;
end_time = gst_util_uint64_scale_int (end_offset, GST_SECOND,