To run the example project, clone the repo, and run pod install
from the Example directory first.
Property Definition
@property(nonatomic, strong) SimpleRecorder *recorder;
self.recorder = [[SimpleRecorder alloc] init];
self.recorder.delegate = self;
self.recorder.soundName = @"record";
}
- (IBAction)actionRecord:(id)sender {
[self.recorder startRecord];
}
- (IBAction)actionPlay:(id)sender {
[self.recorder startPlay];
}
- (IBAction)actionStop:(id)sender {
if ([self.recorder isRecording]) {
[self.recorder stopRecord];
}
[self.recorder stopPlay];
}
Delegate Methods
@protocol SimpleRecorderDelegate<NSObject>
@optional
- (void) recorderStartRecord:(NSString *)soundName;
- (void) recorderFinishedRecord:(NSString *)soundName;
- (void) recorderStartPlay:(NSString *)soundName;
- (void) recorderFinishedPlay:(NSString *)soundName;
@end
SimpleRecorder is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod "SimpleRecorder"
KoStudio, 44663768@163.com
SimpleRecorder is available under the MIT license. See the LICENSE file for more info.