It's apparently a little known fact that you can easily convert files from format to another with gstreamer. For example, i wanted to convert an Ogg/Vorbis file in to MP3 format.
gst-launch-0.10 filesrc location=export.ogg ! \ decodebin ! audioconvert ! audioresample ! \ lame ! filesink location=export.mp3
That's a single command, split in to multiple lines for readability. If i had wanted wav files, i could have used wavenc instead of lame.
Sometimes i wonder why people want to build applications to do a task. Instead you could build on an existing framework and get a lot of features for free.