mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-28 03:00:35 +00:00
player: Don't change state to PLAYING immediately if a seek is pending
We first have to finish the seek (in PAUSED) and move to PLAYING once the seek is actually finished (unless a new one is pending then).
This commit is contained in:
parent
3f44aea2e1
commit
a036b7ef9f
1 changed files with 2 additions and 1 deletions
|
@ -2766,7 +2766,8 @@ gst_player_play_internal (gpointer user_data)
|
|||
change_state (self, GST_PLAYER_STATE_BUFFERING);
|
||||
|
||||
if (self->current_state >= GST_STATE_PAUSED && !self->is_eos
|
||||
&& self->buffering >= 100) {
|
||||
&& self->buffering >= 100 && !(self->seek_position != GST_CLOCK_TIME_NONE
|
||||
|| self->seek_pending)) {
|
||||
state_ret = gst_element_set_state (self->playbin, GST_STATE_PLAYING);
|
||||
} else {
|
||||
state_ret = gst_element_set_state (self->playbin, GST_STATE_PAUSED);
|
||||
|
|
Loading…
Reference in a new issue