Add method that tries to automatically detect the audio codec from the filename.