mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-09-08 13:18:52 +00:00
In reverse playback we were not taking into account the current buffer samples to check if we had reached EOS which was leading to a buffer with PTS = CLOCK_TIME_NONE containing too many frames followed by a useless buffer with pts=0 duration=0, and a g_critical issue in gst_object_sync_values. Also add a validate based test case. Without that patch this is how the expectation fails: ``` diff --- log-asink-sink-expected 2020-05-22 23:22:42.654384579 -0400 +++ log-asink-sink-actual 2020-05-22 23:29:35.671586380 -0400 @@ -27,5 +27,6 @@ buffer: pts=0:00:00.058820861, due=0:00:00.023219955, flags=discont buffer: pts=0:00:00.035600907, due=0:00:00.023219954, flags=discont buffer: pts=0:00:00.012380952, due=0:00:00.023219955, flags=discont -buffer: pts=0:00:00.000000000, due=0:00:00.012380952, flags=discont +buffer: due=0:00:00.012380953, flags=discont +buffer: pts=0:00:00.000000000, flags=discont event eos: (no structure) ``` Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/667>
45 lines
3.3 KiB
Text
45 lines
3.3 KiB
Text
event stream-start: GstEventStreamStart, flags=(GstStreamFlags)GST_STREAM_FLAG_NONE, group-id=(uint)1;
|
|
event caps: audio/x-raw, format=(string)S16LE, layout=(string)interleaved, rate=(int)44100, channels=(int)1;
|
|
event segment: format=TIME, start=0:00:00.000000000, offset=0:00:00.000000000, stop=none, time=0:00:00.000000000, base=0:00:00.000000000, position=0:00:00.000000000
|
|
event tag: GstTagList-stream, taglist=(taglist)"taglist\,\ description\=\(string\)\"audiotest\\\ wave\"\;";
|
|
buffer: pts=0:00:00.000000000, dur=0:00:00.023219954, flags=discont
|
|
event flush-start: (no structure)
|
|
event flush-stop: GstEventFlushStop, reset-time=(boolean)true;
|
|
event segment: format=TIME, start=0:00:00.000000000, offset=0:00:00.000000000, stop=0:00:00.500000000, rate=-1.000000, flags=0x01, time=0:00:00.000000000, base=0:00:00.000000000, position=0:00:00.500000000
|
|
buffer: pts=0:00:00.476780045, dur=0:00:00.023219955, flags=discont
|
|
buffer: pts=0:00:00.453560090, dur=0:00:00.023219955, flags=discont
|
|
buffer: pts=0:00:00.430340136, dur=0:00:00.023219954, flags=discont
|
|
buffer: pts=0:00:00.407120181, dur=0:00:00.023219955, flags=discont
|
|
buffer: pts=0:00:00.383900226, dur=0:00:00.023219955, flags=discont
|
|
buffer: pts=0:00:00.360680272, dur=0:00:00.023219954, flags=discont
|
|
buffer: pts=0:00:00.337460317, dur=0:00:00.023219955, flags=discont
|
|
buffer: pts=0:00:00.314240362, dur=0:00:00.023219955, flags=discont
|
|
buffer: pts=0:00:00.291020408, dur=0:00:00.023219954, flags=discont
|
|
buffer: pts=0:00:00.267800453, dur=0:00:00.023219955, flags=discont
|
|
buffer: pts=0:00:00.244580498, dur=0:00:00.023219955, flags=discont
|
|
buffer: pts=0:00:00.221360544, dur=0:00:00.023219954, flags=discont
|
|
buffer: pts=0:00:00.198140589, dur=0:00:00.023219955, flags=discont
|
|
buffer: pts=0:00:00.174920634, dur=0:00:00.023219955, flags=discont
|
|
buffer: pts=0:00:00.151700680, dur=0:00:00.023219954, flags=discont
|
|
buffer: pts=0:00:00.128480725, dur=0:00:00.023219955, flags=discont
|
|
buffer: pts=0:00:00.105260770, dur=0:00:00.023219955, flags=discont
|
|
buffer: pts=0:00:00.082040816, dur=0:00:00.023219954, flags=discont
|
|
buffer: pts=0:00:00.058820861, dur=0:00:00.023219955, flags=discont
|
|
buffer: pts=0:00:00.035600907, dur=0:00:00.023219954, flags=discont
|
|
buffer: pts=0:00:00.012380952, dur=0:00:00.023219955, flags=discont
|
|
buffer: pts=0:00:00.000000000, dur=0:00:00.012380952, flags=discont
|
|
event eos: (no structure)
|
|
event flush-start: (no structure)
|
|
event flush-stop: GstEventFlushStop, reset-time=(boolean)true;
|
|
event segment: format=TIME, start=0:00:00.000000000, offset=0:00:00.000000000, stop=0:00:01.000000000, rate=-1.000000, flags=0x01, time=0:00:00.000000000, base=0:00:00.000000000, position=0:00:01.000000000
|
|
buffer: pts=0:00:00.900000000, dur=0:00:00.100000000, flags=discont
|
|
buffer: pts=0:00:00.800000000, dur=0:00:00.100000000, flags=discont
|
|
buffer: pts=0:00:00.700000000, dur=0:00:00.100000000, flags=discont
|
|
buffer: pts=0:00:00.600000000, dur=0:00:00.100000000, flags=discont
|
|
buffer: pts=0:00:00.500000000, dur=0:00:00.100000000, flags=discont
|
|
buffer: pts=0:00:00.400000000, dur=0:00:00.100000000, flags=discont
|
|
buffer: pts=0:00:00.300000000, dur=0:00:00.100000000, flags=discont
|
|
buffer: pts=0:00:00.200000000, dur=0:00:00.100000000, flags=discont
|
|
buffer: pts=0:00:00.100000000, dur=0:00:00.100000000, flags=discont
|
|
buffer: pts=0:00:00.000000000, dur=0:00:00.100000000, flags=discont
|
|
event eos: (no structure)
|