Given an audio file, one the first things you will do is to play that audio file, isn't it? In GStreamer, what basic elements do we need to play an audio? The essential elements are listed as follows.
The first thing we need is to open an audio file for reading
Next, we need a decoder to transform the encoded information
Then, there needs to be an element to convert the audio format so that it is in a 'playable' format required by an audio device such as speakers
Finally, an element that will enable the actual playback of the audio file
How will you play an audio file using the command-line version of GStreamer? One way to execute it using command line is as follows:
$gstlaunch-0.10 filesrc location=/path/to/audio.mp3 ! decodebin ! audioconvert ! autoaudiosink