[Ilugc] Fwd: LJ Tech Tip

  • From: sbharathi@xxxxxxxxxxxxx (Bharathi Subramanian)
  • Date: Wed Aug 3 21:41:12 2005

Tech Tip from LJ :-

When writing a program that plays audio using gstreamer, make sure to
use the user's configured output method, which could be OSS, ALSA or a
sound daemon such as ESD or JACK. You don't need to look up the user's
preference, simply make a "gconfaudiosink" and set your player's audio
sink to it, for example, where the variables "sink" and "play" are
both pointers to GstElement:

 sink = gst_element_factory_make("gconfaudiosink", "sink");
 play = gst_element_factory_make("playbin", "play");
 g_object_set (G_OBJECT (play), "audio-sink", sink, NULL);

For more info on developing applications with gstreamer, see the
GStreamer documentation:
http://gstreamer.freedesktop.org/documentation/.

HTH :)
--
Bharathi S

Other related posts: