0

I have an AUGraph setup and working, it consists of a multichannel mixer (with a single monophonic input) feeding a RemoteIO (kAudioUnitSubType_RemoteIO) unit to output to the speaker. I implemented the single input mixer in order to be able to pan my audio source between Left and Right hardware output channels. This works just fine.

As this is a VOIP application, I have been experimenting with using a Voice-processing IO Unit (kAudioUnitSubType_VoiceProcessingIO) in place of the Remote IO Unit (kAudioUnitSubType_RemoteIO). Per Apple's description, this unit should behave like a Remote IO unit with some extra features...

The Voice-Processing I/O unit (subtype kAudioUnitSubType_VoiceProcessingIO) has the characteristics of the Remote I/O unit and adds echo suppression for two-way duplex communication. It also adds automatic gain correction, adjustment of voice-processing quality, and muting. This is the correct I/O unit to use for VoIP (Voice over Internet Protocol) apps.

But I am noting that when I switch to the Voice Processing IO Unit, I lose the ability to pan using the mixer. Any ideas as to what is going on here? Is the Voice Processing IO Unit inherently monophonic?

Chris Loonam
  • 5,635
  • 6
  • 40
  • 61
Electro-Bunny
  • 1,350
  • 2
  • 12
  • 31
  • What are your stream formats? I don't think the VP I/O unit is inherently monphonic – ruoho ruotsi Mar 24 '15 at 21:32
  • The mixer input has the following format: AudioStreamBasicDescription audioFormat = { 0 }; audioFormat.mSampleRate = 16000.00; audioFormat.mFormatID = kAudioFormatLinearPCM; audioFormat.mFormatFlags = kAudioFormatFlagIsSignedInteger | kAudioFormatFlagIsPacked; audioFormat.mFramesPerPacket = 1; audioFormat.mChannelsPerFrame = 1; audioFormat.mBitsPerChannel = 16; audioFormat.mBytesPerPacket = 2; audioFormat.mBytesPerFrame = 2; – Electro-Bunny Mar 24 '15 at 22:52
  • okay, that looks right. If you have the code on github/gist I can take a look, but its hard to see what's happenning without more context or info. Like what does *losing ability to pan* mean? Is there an error thrown or panning just stops working? – ruoho ruotsi Mar 26 '15 at 03:28
  • Regarding "losing the ability to pan"... using RemoteIO gives me a stereo signal to the headphones which responds to Left/Right balance adjustments, either at the multi-channel mixer or the iOS/Settings/General/Accessibility/Balance slider. When I simply switch the subtype to the VPIO unit, the signal no longer responds to the balance adjustment. The signal appears to be equal in Left/Right channels independent of balance (aka panning) and so I assumed the output must be monophonic. – Electro-Bunny Mar 26 '15 at 12:52

1 Answers1

3

For my particular AUGraph, a Multichannel Mixer Output feeding the IO Unit, dumping the ASBD for the input scope of the IO Unit always shows 2 channels per frame. As I understand from the documentation, the Multichannel Mixer's output is stereo.

I dumped the ASBD for the output scope of the RemoteIO unit and indeed the ASBD shows 2 channels per frame. Trying to overwrite this to 1 channel resulted in a kAudioUnitErr_PropertyNotWritable error.

Then I switched the subtype to the VPIO unit. Dumping the ASBD for the output scope shows 1 channel per frame. And as above, trying to overwrite this to 2 channels also resulted in the same property-not-writable error.

So at least for my particular AUGraph , I must conclude that the VPIO unit is inherently monophonic.

Electro-Bunny
  • 1,350
  • 2
  • 12
  • 31