I'm working on a mac application that mix audio from a VideoCard and an external audio card.
How can I change volume on each channel (not each source) independently using AVAudioEngine.
Let's say I have an AVAudioPCMBuffer with 16 channels interleaved and I want channel 1 and 2 volume to 50% and other 100%
Should I convert from 1 AVAudioPCMBuffer with 16 channels to 16 mono AVAudioPCMBuffer and have one AVPlayerNode for each of them ? Then change the volume on each AVPlayerNode ?
Or can I keep o is there a way to change the underlying Audio Unit from the AVAudioMixerNode ?
Or should I use CoreAudio AudioUnits directly?