ndisrc: Use correct receive time to re-initialize time tracking on disconts

The base receive time should not be the monotonic system clock time, but
the monotonic system clock time adjusted by the current clock calibration.
For the first time this is equivalent as the clock calibration is the default,
but for further discontinuities it is not and would cause a
discontinuity in the clock times at this point.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1766>
This commit is contained in:
Sebastian Dröge 2024-09-05 11:46:31 +03:00 committed by GStreamer Marge Bot
parent bfc32cc692
commit 295b9f01c2

View file

@ -897,7 +897,7 @@ impl NdiSrc {
); );
state.base_timecode = Some(current_min_delta.remote_time); state.base_timecode = Some(current_min_delta.remote_time);
state.base_receive_time = Some(current_min_delta.local_time); state.base_receive_time = Some(clock_time);
discont = true; discont = true;
} else { } else {
let (base_timecode, base_receive_time) = let (base_timecode, base_receive_time) =