tags:

views:

44

answers:

2

Hi all,

I am trying to make a simple application which will store the sound said by user , say on click of record button and will play it back to him/her , say on click of play button.

Can anyone suggest me some appropriate way to do this ??

Thanks,

Miraaj

A: 

I used direct sound to create an entire internet phone application a few years ago. Your question is far simpler, you won't have to deal with the circular buffer as critically. Direct sound is pretty main stream and you can find a lot of help with it in forums, and it's free!

Steve H.
I doubt DirectSound will work in a Cocoa application.
Peter Hosey
+1  A: 

You can use QuickTime Kit's capture APIs to record a movie of the audio, and QTMovie (from the same framework) to convert it to a more conventional format for audio files and to play back both the intermediate file and the converted file.

There used to be a QuickTime Kit Programming Guide, but it didn't cover capturing and is now gone from developer.apple.com. You should file a bug against the docs.

This answer will work in a Cocoa (Mac) app. If you meant to ask about the iPhone, you should re-tag your question, as the solution will be completely different for a Cocoa app vs. a Cocoa Touch (iPhone) app.

Peter Hosey
hi Peter, thanks for your reply! I am developing it for Mac so your answer can prove to be very useful.
Miraaj