Re: Basic Audio Mixer question
Re: Basic Audio Mixer question
- Subject: Re: Basic Audio Mixer question
- From: Christian Rober <email@hidden>
- Date: Mon, 01 Feb 2016 19:22:42 -0500
Cara,
A couple of things that may help you (apologies if you already know this):
1) Assuming you are using an AUGraph, each node in the graph (except the RemoteI/O or an audio hardware node) will need something connected to its input and have its output connected to some other node (for the pull model to work).
2) The input to an AUGraph node can be either A) another single AUGraph node (i.e. an audio unit), B) multiple AUGraph nodes, or C) a rendering callback function.
3) The ASBD's (which include channel count) must match on the connected buses.
4) If a translation of format, or a channel count change, is required, you may need to insert an audio unit in-between two AUGraph nodes so that the respective I/O's match.
So in your case, you probably want a mixture of the input from the microphone and the audio stream from the network (if I read your requirements accurately). This means one input bus of your mixer would be hooked up to the RemoteI/O's mic "output" bus, (and the ASBD's must match, of course) and the other mixer bus would be hooked up to another audio unit that has the audio from the network. In other words, implementing your own audio unit(s) for the incoming network multi-channel/bus is a solution that allows you to connect the microphone AND other audio to the mixer via AUGraph node connection API.
It might look something like this:
|mic AU| ---> | Bus(0) |
| MultiChannelMixer AU |---> | RemoteI/O output AU |
|net AU| ---> | Bus(1) |
Take a look at this Apple code sample for how to connect nodes to one another and how to setup audio callbacks (look at initializeAUGraph: in particular)
At some point you may need something a little bit more sophisticated than the multi-channel mixer. I recommend searching the archives of this list for more information about the Matrix Mixer AU (which is what I use most of the time).
I hope that helps.
--Christian
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden