seek: set selected/default audio/video sinks on playbin and playbin2

https://bugzilla.gnome.org/show_bug.cgi?id=630322
This commit is contained in:
Vladimir Eremeev 2010-09-27 13:32:31 +04:00 committed by Tim-Philipp Müller
parent 2b12546e02
commit 4c8fd85e8e

View file

@ -930,6 +930,7 @@ static GstElement *
construct_playerbin (const gchar * name, const gchar * location)
{
GstElement *player;
GstElement *avsink;
player = gst_element_factory_make (name, "player");
g_assert (player);
@ -941,6 +942,14 @@ construct_playerbin (const gchar * name, const gchar * location)
/* force element seeking on this pipeline */
elem_seek = TRUE;
avsink = gst_element_factory_make_or_warn (opt_audiosink_str, "a_sink");
if (avsink)
g_object_set (player, "audio-sink", avsink, NULL);
avsink = gst_element_factory_make_or_warn (opt_videosink_str, "v_sink");
if (avsink)
g_object_set (player, "video-sink", avsink, NULL);
return player;
}