convert(to:from:)
Performs a basic conversion between audio formats that doesn’t involve converting codecs or sample rates.
Declaration
func convert(to outputBuffer: AVAudioPCMBuffer, from inputBuffer: AVAudioPCMBuffer) throwsParameters
- outputBuffer:
The output audio buffer.
- inputBuffer:
The input audio buffer.
Discussion
The output buffer’s frameCapacity value needs to be at least at large as the frameLength value of the inputBuffer.