title: IllegalStateException when MediaCodec.configure Android
body: <p>I try create encoder for "audio/3gpp" and my app crash...</p>
  
  <p>I use this code</p>
  
  <pre><code>String mMime = "audio/3gpp";
  MediaCodec mMediaCodec = MediaCodec.createEncoderByType(mMime);
  MediaFormat mMediaFormat = MediaFormat.createAudioFormat(mMime, RECORDER_SAMPLERATE, 1);
  mMediaCodec.configure(mMediaFormat, null, null, MediaCodec.CONFIGURE_FLAG_ENCODE);
  mMediaCodec.start();
  </code></pre>
  
  <blockquote>
    <p>Exception
    <br>java.lang.IllegalStateException
    <br>android.media.MediaCodec.native_configure(Native Method)
    <br>at android.media.MediaCodec.configure(MediaCodec.java:256)
    <br>at com.agent.mobile.TestAppActivity.initMediaCodec(TestAppActivity.java:234)</p>
  </blockquote>