Tuesday, February 3, 2015

Audio Recording On MAC

The steps for audio recording on MAC is simple as below

1. Create a capture session
2. Begin configuration of the capture session
3. Get the Audio Device
4. Create a Capture Input with the audio device
5. To the Capture session, add the created CaptureInputDevice
6. Initialise AVCaptureAudioOutput which is a local file path
7. Add the AVCaptureAudioOutput to the capture session
8. set the buffer delegate to the AVCaptureDataOutput
9. Now create an AssetWriter with local file path and the type as audio
10. Now create AVASsetWriterInput with the output audio settings
11. To the asset writer, add the AVAssetWriterInput
12 Now commit the configuration of CApture session
13. Call start Running on capture session
14. call start writing on the asset writer

the flow seqeuence diagram for this is like below



References:
My own test app.
 

No comments:

Post a Comment