I\'d like to use MediaCodec to encode the data coming from the camera (reason: it\'s more low-level so hopefully faster than using MediaRecorder). Using Camera.PreviewCallBa
See example at https://gist.github.com/3990442. You should set MIME type of what you want to get out of encoder, i.e. "video/avc".