I am developing an application in which I have to perform three functions play, record and pause an audio file.
Has anyone implemented it before?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Take a look at
MediaPlayerorAudioTrackfor playback. The difference is thatMediaPlayercan play several audio formats directly from file (or in some cases even from remote URL), whileAudioTrackplays only from raw LPCM buffer,For recording take a look at
MediaRecorderorAudioRecord. The difference is thatMediaRecorderrecords audio and video to.3gp, whileAudioRecordgives you only audio as raw LPCM buffers. TheAudioRecorddata can be used to create.wavfiles (though some extra code is required for this).