Latest 0.5
Homepage https://github.com/owlcoding/PMAudioRecorderViewController
License Apache License
Platforms ios 6.0, requires ARC
Dependencies UIImage+BlurredFrame
Frameworks AVFoundation
Authors

Drop-in class to record audio note in iOS application and get it back in the app.

Usage

Instalation:

pod 'PMAudioRecorderViewController'

or drop the contents of AudioNoteRecorderViewController directory in your Xcode project.

In the code:

#import "AudioRecorderViewController"
...
[AudioNoteRecorderViewController showRecorderMasterViewController:self withFinishedBlock:^(BOOL wasRecordingTaken, NSURL *recordingURL) {
    if (wasRecordingTaken) {
        // do whatever you want with that URL to the .caf file
    }
}];

Or, to have it more customisable:

NSDictionary *recorderSettings = [NSDictionary dictionaryWithObjectsAndKeys:
                            [NSNumber numberWithInt:kAudioFormatAppleIMA4],AVFormatIDKey,
                            [NSNumber numberWithInt:44100],AVSampleRateKey, 
                            [NSNumber numberWithInt:1],AVNumberOfChannelsKey,
                            [NSNumber numberWithInt:16],AVLinearPCMBitDepthKey,
                            [NSNumber numberWithBool:NO],AVLinearPCMIsBigEndianKey, 
                            [NSNumber numberWithBool:NO],AVLinearPCMIsFloatKey,
                            nil];

[AudioNoteRecorderViewController showRecorderMasterViewController:self 
                                            withRecorderSettings:recorderSettings
                                            withFileExtension:@"caf"
                                            withFinishedBlock:^(BOOL wasRecordingTaken, NSURL *recordingURL) {
    if (wasRecordingTaken) {
        // do whatever you want with that URL to the .caf file
    }
}];

Author

(C) Paweł Mączewski, [email protected], Twitter: http://twitter.com/pawelmaczewski.

Latest podspec

{
    "name": "PMAudioRecorderViewController",
    "version": "0.5",
    "summary": "Drop-in class to record audio note in iOS application and get it back in the app",
    "description": "PMAudioRecorderViewControllern=============================nnn    #import "AudioRecorderViewController"n    ...n    [AudioNoteRecorderViewController showRecorderMasterViewController:self withFinishedBlock:^(BOOL wasRecordingTaken, NSURL *recordingURL) {n        if (wasRecordingTaken) {n            // do whatever you want with that URL to the .caf filen        }n    }];n",
    "homepage": "https://github.com/owlcoding/PMAudioRecorderViewController",
    "license": "Apache License",
    "authors": {
        "Pawel 'Kender' Maczewski": "[email protected]"
    },
    "source": {
        "git": "https://github.com/owlcoding/PMAudioRecorderViewController.git",
        "tag": "0.5"
    },
    "platforms": {
        "ios": "6.0"
    },
    "requires_arc": true,
    "frameworks": "AVFoundation",
    "source_files": "AudioNoteRecorderViewController/Classes/*",
    "resources": "AudioNoteRecorderViewController/Images/*",
    "dependencies": {
        "UIImage+BlurredFrame": []
    }
}

Pin It on Pinterest

Share This