1

iOSで音声を録音する場合、サイズが小さいのはどのオーディオ形式ですか? 品質は最高である必要はありませんが、ユーザーが話す内容は理解できるものでなければなりません。

4

3 に答える 3

0

いくつかの iOS アプリは、低ビット レートの音声にSpeexエンコーダーを使用します。組み込みではありませんが、エンコーディングを行うためのオープン ソースコードを利用できます。

于 2014-03-15T19:14:46.473 に答える
0

クラスを使用する予定があると仮定するとAVAudioRecorder、次のような録音設定を提供する必要があります-

NSDictionary *recordSettings = [NSDictionary dictionaryWithObjectsAndKeys:
    [NSNumber numberWithInt:AVAudioQualityMin], AVEncoderAudioQualityKey,
    [NSNumber numberWithInt:16], AVEncoderBitRateKey,
    [NSNumber numberWithInt: 2],AVNumberOfChannelsKey,
    [NSNumber numberWithFloat:44100.0], AVSampleRateKey,nil];


NSError* error = nil;
AVAudioRecorder audioRecorder = [[AVAudioRecorder alloc]  
                                  initWithURL:soundFileURL 
                                  settings:recordSettings
                                  error:&error];

Apple のドキュメントAVEncoderAudioQualityKeyには、アプリで使用できる設定定数 (具体的には ) に関する詳細が記載されています。

于 2014-03-13T05:56:06.983 に答える