gst-player: mp3 audio fast rewind then fast forward will exit with eos directly
Fast rewind then fast forward when play one mp3 audio, audio will exit directly at the first seek's stop time.
audio: Mpeg2L3_22kHz_64kbps_s_18DaftPunk_mplayer.mp3
Finally I find the root cause. gst-player set stop type as GST_SEEK_TYPE_NONE when generate seek event with rate>=0.0, and take the previous stop time which can be seen from below code in function gst_segment_do_seek().
/* stop can be -1 if we have not configured a stop. */
switch (stop_type) {
case GST_SEEK_TYPE_NONE:
stop = segment->stop;
update_stop = FALSE;
break;
case GST_SEEK_TYPE_SET:
/* stop holds required value */
break;
case GST_SEEK_TYPE_END:
if (segment->duration != -1) {
stop = segment->duration + stop;
} else {
stop = segment->stop;
update_stop = FALSE;
}
break;
}
So gst-player need to set stop type as GST_SEEK_TYPE_SET when generate seek event with rate>=0.0 to keep desired stop time to avoid such issue.