Update for _get_state() API change.

Original commit message from CVS:
* check/pipelines/simple_launch_lines.c: (run_pipeline):
* examples/seeking/Makefile.am:
* examples/seeking/cdplayer.c: (play_cb), (pause_cb), (stop_cb):
* examples/seeking/seek.c: (make_avi_msmpeg4v3_mp3_pipeline),
(do_seek), (set_update_scale), (message_received), (main):
* gst-libs/gst/audio/gstringbuffer.c: (gst_ring_buffer_commit),
(gst_ring_buffer_read), (gst_ring_buffer_clear):
Update for _get_state() API change.
This commit is contained in:
Wim Taymans 2005-10-12 12:25:31 +00:00
parent 5c17d94013
commit 7bc8bee1e1
11 changed files with 27 additions and 20 deletions

View file

@ -1,3 +1,14 @@
2005-10-12 Wim Taymans <wim@fluendo.com>
* check/pipelines/simple_launch_lines.c: (run_pipeline):
* examples/seeking/Makefile.am:
* examples/seeking/cdplayer.c: (play_cb), (pause_cb), (stop_cb):
* examples/seeking/seek.c: (make_avi_msmpeg4v3_mp3_pipeline),
(do_seek), (set_update_scale), (message_received), (main):
* gst-libs/gst/audio/gstringbuffer.c: (gst_ring_buffer_commit),
(gst_ring_buffer_read), (gst_ring_buffer_clear):
Update for _get_state() API change.
2005-10-11 Wim Taymans <wim@fluendo.com>
* gst-libs/gst/audio/gstbaseaudiosink.c:

View file

@ -56,7 +56,7 @@ run_pipeline (GstElement * pipe, const gchar * descr,
g_assert (bus);
ret = gst_element_set_state (pipe, GST_STATE_PLAYING);
ret = gst_element_get_state (pipe, NULL, NULL, NULL);
ret = gst_element_get_state (pipe, NULL, NULL, GST_CLOCK_TIME_NONE);
if (ret != GST_STATE_CHANGE_SUCCESS) {
g_critical ("Couldn't set pipeline to PLAYING");
goto done;

2
common

@ -1 +1 @@
Subproject commit 615cf4d4506ef1ffb1f600c434fced1fa26b0f44
Subproject commit 2485a65b662de25fb7b71857e34411426c6f530c

View file

@ -1,4 +1,4 @@
examples = seek # cdplayer cdparanoia
examples = seek scrubby # cdplayer cdparanoia
noinst_PROGRAMS = $(examples)

View file

@ -191,7 +191,7 @@ play_cb (GtkButton * button, gpointer data)
{
GstState state;
gst_element_get_state (pipeline, &state, NULL, NULL);
gst_element_get_state (pipeline, &state, NULL, GST_CLOCK_TIME_NONE);
if (state != GST_STATE_PLAYING) {
gst_element_set_state (pipeline, GST_STATE_PLAYING);
update_id =
@ -204,7 +204,7 @@ pause_cb (GtkButton * button, gpointer data)
{
GstState state;
gst_element_get_state (pipeline, &state, NULL, NULL);
gst_element_get_state (pipeline, &state, NULL, GST_CLOCK_TIME_NONE);
if (state != GST_STATE_PAUSED) {
gst_element_set_state (pipeline, GST_STATE_PAUSED);
gtk_timeout_remove (update_id);
@ -216,7 +216,7 @@ stop_cb (GtkButton * button, gpointer data)
{
GstState state;
gst_element_get_state (pipeline, &state, NULL, NULL);
gst_element_get_state (pipeline, &state, NULL, GST_CLOCK_TIME_NONE);
if (state != GST_STATE_READY) {
gst_element_set_state (pipeline, GST_STATE_READY);
gtk_timeout_remove (update_id);

View file

@ -1018,11 +1018,9 @@ do_seek (GtkWidget * widget)
}
if (res) {
GTimeVal tv;
gst_pipeline_set_new_stream_time (GST_PIPELINE (pipeline), 0);
GST_TIME_TO_TIMEVAL (100 * GST_MSECOND, tv);
gst_element_get_state (GST_ELEMENT (pipeline), NULL, NULL, &tv);
gst_element_get_state (GST_ELEMENT (pipeline), NULL, NULL,
100 * GST_MSECOND);
} else
g_print ("seek failed\n");
}

View file

@ -56,7 +56,7 @@ run_pipeline (GstElement * pipe, const gchar * descr,
g_assert (bus);
ret = gst_element_set_state (pipe, GST_STATE_PLAYING);
ret = gst_element_get_state (pipe, NULL, NULL, NULL);
ret = gst_element_get_state (pipe, NULL, NULL, GST_CLOCK_TIME_NONE);
if (ret != GST_STATE_CHANGE_SUCCESS) {
g_critical ("Couldn't set pipeline to PLAYING");
goto done;

View file

@ -1,4 +1,4 @@
examples = seek # cdplayer cdparanoia
examples = seek scrubby # cdplayer cdparanoia
noinst_PROGRAMS = $(examples)

View file

@ -1018,11 +1018,9 @@ do_seek (GtkWidget * widget)
}
if (res) {
GTimeVal tv;
gst_pipeline_set_new_stream_time (GST_PIPELINE (pipeline), 0);
GST_TIME_TO_TIMEVAL (100 * GST_MSECOND, tv);
gst_element_get_state (GST_ELEMENT (pipeline), NULL, NULL, &tv);
gst_element_get_state (GST_ELEMENT (pipeline), NULL, NULL,
100 * GST_MSECOND);
} else
g_print ("seek failed\n");
}

View file

@ -1,4 +1,4 @@
examples = seek # cdplayer cdparanoia
examples = seek scrubby # cdplayer cdparanoia
noinst_PROGRAMS = $(examples)

View file

@ -191,7 +191,7 @@ play_cb (GtkButton * button, gpointer data)
{
GstState state;
gst_element_get_state (pipeline, &state, NULL, NULL);
gst_element_get_state (pipeline, &state, NULL, GST_CLOCK_TIME_NONE);
if (state != GST_STATE_PLAYING) {
gst_element_set_state (pipeline, GST_STATE_PLAYING);
update_id =
@ -204,7 +204,7 @@ pause_cb (GtkButton * button, gpointer data)
{
GstState state;
gst_element_get_state (pipeline, &state, NULL, NULL);
gst_element_get_state (pipeline, &state, NULL, GST_CLOCK_TIME_NONE);
if (state != GST_STATE_PAUSED) {
gst_element_set_state (pipeline, GST_STATE_PAUSED);
gtk_timeout_remove (update_id);
@ -216,7 +216,7 @@ stop_cb (GtkButton * button, gpointer data)
{
GstState state;
gst_element_get_state (pipeline, &state, NULL, NULL);
gst_element_get_state (pipeline, &state, NULL, GST_CLOCK_TIME_NONE);
if (state != GST_STATE_READY) {
gst_element_set_state (pipeline, GST_STATE_READY);
gtk_timeout_remove (update_id);