title: Android AudioRecord and MediaRecorder
body: <p>I'm developing an audio processing application where I need to record audio, and then process it to obtain features of that recording. However, I want the audio in a playable format to play it after with MediaPlayer.</p>
  
  <p>I've seen that to record audio to process it it's better to use AudioRecord, because I can get the raw audio from there. But then I can't write the data to a file in a playable format (is there any library to do this in android?).</p>
  
  <p>I used this method to record raw data and then write it into a file:
  <a href="http://andrewbrobinson.com/2011/11/27/capturing-raw-audio-data-in-android/" rel="noreferrer">http://andrewbrobinson.com/2011/11/27/capturing-raw-audio-data-in-android/</a>
  But when i try to play this file on the device, it is not playable.</p>
  
  <p>Then if I use MediaRecorder I don't know how to decode the data to extract the features. I've been looking at MediaExtractor, but it seams that MediaExtractor doesn't decode the frames. </p>
  
  <p>So.. what's the best way to do this? I imagine that's common in any audio processing application, but I wasn't able to find the way to manage this. </p>
  
  <p>Thanks to your replies. </p>