将一个AAC文件附加到另一个AAC文件时输出音频设置

som*_*dev 6 iphone audio aac objective-c avassetexportsession

我的应用程序使用带有音频参数的AVAudioRecorder逐个记录两个音频文件:

        NSDictionary *outputSettings = [NSDictionary dictionaryWithObjectsAndKeys:
                                    [NSNumber numberWithInt: kAudioFormatMPEG4AAC], AVFormatIDKey,
                                    [NSNumber numberWithFloat:44100.0], AVSampleRateKey,
                                    [NSNumber numberWithInt:1], AVNumberOfChannelsKey,
                                    [NSNumber numberWithInt:AVAudioQualityMin], AVEncoderAudioQualityKey,
                                    [NSNumber numberWithInt:16],AVEncoderBitDepthHintKey,
                                    [NSNumber numberWithInt:128000], AVEncoderBitRateKey,
                                    nil];
Run Code Online (Sandbox Code Playgroud)

我需要在file1的末尾添加file2.我正在使用那里的解决方案(通过在添加两个文件并使用exportAsynchronouslyWithCompletionHandler:AVAssetExportSession方法导出合成后创建AVMutableCompositionTrack来附加两个音频文件).
它有效,但我有两个输入文件128kbs 44.1kHz 16bit单声道,输出文件格式为:219.4kbs 44.1kHz 16bit立体声.

有没有办法为AVAssetExportSession配置输出音频文件参数?

som*_*dev 3

我找到了解决方案:SDAVAssetExportSession