Posts

Post not yet marked as solved
0 Replies
389 Views
Hello,is there any way to select which input channels shall be mapped to the output with a AVAudioMixerNode?I have a inputNode with 4 channels and want to use 2 specific channel from it within my processing chain.To get an idea it looks like this:... var mixer = AVAudioMixerNode() var inputFormat = audioEngine.inputNode.inputFormat(forBus: 0) // This one has 4 channels var outputFormat = AVAudioFormat(commonFormat: inputFormat.commonFormat, sampleRate: inputFormat.sampleRate, channels: 2, interleaved: inputFormat.isInterleaved)! audioEngine.attach(mixer) audioEngine.attach(someOtherNode) audioEngine.connect(inputNode, mixer, inputFormat) audioEngine.connect(mixer, someOtherNode, outputFormat) ...Basically this works as expected but I have no choice about the channel mapping from input to output.The mixer automatically maps channel 0 and 1 from the four input channels to the two output channels.How I can I tell the mixer that it should map channel 2 and 3 to the output channels?I tried to set mixer.auAudioUnit.channelMap to [2, 3] but it did not affect anything.mixer.auAudioUnit.channelMap is always nil.Any help would be very appreciated. Thank you!Daniel
Posted
by daniel_n.
Last updated
.
Post not yet marked as solved
0 Replies
279 Views
Hello,my app grabs audio from the microphone, encodes it to aac and streams it to the internet.Even though I have background audio activated it seems like at some point (3-20 minutes) after the device has been lockedmy audio tap does not receive audio samples anymore. Is that expected behaviour?Best RegardsDaniel
Posted
by daniel_n.
Last updated
.