diff --git a/ChangeLog b/ChangeLog index 48d91b15cc..7d94ac8ee6 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2005-08-18 Ronald S. Bultje + + * docs/manual/basics-helloworld.xml: + Fix example for dmix (use audioconvert/audioscale). + 2005-08-10 Tim-Philipp Müller * gst/gst.c: (gst_init_check_with_popt_table), (init_pre): diff --git a/common b/common index 856fbbfa88..8ff526a316 160000 --- a/common +++ b/common @@ -1 +1 @@ -Subproject commit 856fbbfa88621ab67df141ead8d4d3df32c5c176 +Subproject commit 8ff526a316f9b576e727b8e32cba0a53cdec07a6 diff --git a/docs/manual/basics-helloworld.xml b/docs/manual/basics-helloworld.xml index e5a2d701c9..4ed2bbb0c4 100644 --- a/docs/manual/basics-helloworld.xml +++ b/docs/manual/basics-helloworld.xml @@ -65,7 +65,7 @@ * example, we will use them, however. */ -GstElement *pipeline, *source, *parser, *decoder, *sink; +GstElement *pipeline, *source, *parser, *decoder, *conv, *scale, *sink; static void new_pad (GstElement *element, @@ -75,7 +75,7 @@ new_pad (GstElement *element, /* We can now link this pad with the audio decoder and * add both decoder and audio output to the pipeline. */ gst_pad_link (pad, gst_element_get_pad (decoder, "sink")); - gst_bin_add_many (GST_BIN (pipeline), decoder, sink, NULL); + gst_bin_add_many (GST_BIN (pipeline), decoder, conv, scale, sink, NULL); /* This function synchronizes a bins state on all of its * contained children. */ @@ -100,6 +100,8 @@ main (int argc, source = gst_element_factory_make ("filesrc", "file-source"); parser = gst_element_factory_make ("oggdemux", "ogg-parser"); decoder = gst_element_factory_make ("vorbisdec", "vorbis-decoder"); + conv = gst_element_factory_make ("audioconvert", "conv"); + scale = gst_element_factory_make ("audioscale", "scale"); sink = gst_element_factory_make ("alsasink", "alsa-output"); /* set filename property on the file source */ @@ -109,7 +111,7 @@ main (int argc, * decoder yet, becuse the parser uses dynamic pads. For that, * we set a new-pad signal handler. */ gst_element_link (source, parser); - gst_element_link (decoder, sink); + gst_element_link_many (decoder, conv, scale, sink, NULL); g_signal_connect (parser, "new-pad", G_CALLBACK (new_pad), NULL); /* put all elements in a bin - or at least the ones we will use @@ -121,6 +123,8 @@ main (int argc, * This will decrease the amount of time spent on linking these * elements when the Ogg parser emits the new-pad signal. */ gst_element_set_state (decoder, GST_STATE_READY); + gst_element_set_state (conv, GST_STATE_READY); + gst_element_set_state (scale, GST_STATE_READY); gst_element_set_state (sink, GST_STATE_READY); gst_element_set_state (pipeline, GST_STATE_PLAYING);