HUMAudioRecorder 0.1.8

HUMAudioRecorder 0.1.8

测试已测试
Lang语言 Obj-CObjective C
许可证 MIT
发布最后发布2018年1月

Colin Humber维护。



HUMAudioRecorder

[![CI 状态](http://img.shields.io/travis/Colin Humber/HUMAudioRecorder.svg?style=flat)](https://travis-ci.org/Colin Humber/HUMAudioRecorder)
Version
Carthage compatible
License
Platform

用法

要运行示例项目,先克隆仓库,然后首先从 Example 目录运行 pod install

要求

安装

HUMAudioRecorder 通过 CocoaPods 提供。要安装
它,只需将以下行添加到您的 Podfile 中

pod "HUMAudioRecorder"

或者,如果您正在使用 Carthage,只需将 HUMAudioRecorder 添加到您的 Cartfile

github "colinhumber/HUMAudioRecorder"

用法

使用 HUMAudioRecorder 非常简单!只需创建一个文件所在的 URL,设置音频会话设置,并创建一个新的 HUMAudioRecorder 实例。

有关 AVFoundation 设置的列表,请点击此处

NSURL *url = [NSURL fileURLWithPath:[NSTemporaryDirectory() stringByAppendingPathComponent:[NSString stringWithFormat:@"%@.m4a", [NSUUID UUID].UUIDString]]];

NSDictionary *settings = @{ AVFormatIDKey : @(kAudioFormatMPEG4AAC),
                            AVSampleRateKey : @44100,
                            AVNumberOfChannelsKey : @1,
                            AVEncoderAudioQualityKey : @(AVAudioQualityHigh)};

HUMAudioRecorder *audioRecorder = [[HUMAudioRecorder alloc] initWithURL:url settings:settings];

头文件有良好的文档,因此请查看它以获取属性和方法列表。使用该模块作为 UI 中的后备记录器/播放器时,可以使用定义良好的状态。

作者

Colin Humber, [email protected]

许可证

HUMAudioRecorder 在 MIT 许可证下可用。有关更多信息,请参阅 LICENSE 文件。