I'm newbie to AVAudioEngine. My task is quite simple: I want to get sound from microphone, change it's pitch and save to file or just play result.
self.engine = [[AVAudioEngine alloc] init];
self.pitchNode = [[AVAudioUnitTimePitch alloc] init];
self.recordNode = self.engine.inputNode;
[self.engine attachNode:self.pitchNode];
AVAudioFormat *fmt = [self.recordNode inputFormatForBus:0];
[self.engine connect:self.recordNode to:self.pitchNode format:fmt];
[self.engine connect:self.pitchNode to:self.engine.mainMixerNode fromBus:0 toBus:1 format:fmt];
[self.engine connect:self.engine.mainMixerNode to:self.engine.outputNode format:fmt];
[self.engine prepare]; // at this line i got error message
ERROR: >avae> AVAudioEngineGraph.mm:685: InitializeActiveNodesInInputChain: required condition is false: false == isInputConnToConverter
Can anybody help? thanks.