mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 19:51:11 +00:00
gst-play: Handle CLOCK_LOST message
It is necessary for playbin gapless playback when switching between audio-only and video-only files for example.
This commit is contained in:
parent
5df274f824
commit
2aa26a9807
1 changed files with 6 additions and 0 deletions
|
@ -210,6 +210,12 @@ play_bus_msg (GstBus * bus, GstMessage * msg, gpointer user_data)
|
|||
}
|
||||
break;
|
||||
}
|
||||
case GST_MESSAGE_CLOCK_LOST:{
|
||||
g_print (_("Clock lost, selecting a new one\n"));
|
||||
gst_element_set_state (play->playbin, GST_STATE_PAUSED);
|
||||
gst_element_set_state (play->playbin, GST_STATE_PLAYING);
|
||||
break;
|
||||
}
|
||||
case GST_MESSAGE_LATENCY:
|
||||
g_print ("Redistribute latency...\n");
|
||||
gst_bin_recalculate_latency (GST_BIN (play->playbin));
|
||||
|
|
Loading…
Reference in a new issue