Re: Setting Sample Rates
Re: Setting Sample Rates
- Subject: Re: Setting Sample Rates
- From: Jeff Moore <email@hidden>
- Date: Mon, 14 Jan 2002 16:53:11 -0800
on 1/14/02 3:52 PM, Jim Dolan <email@hidden> wrote:
>
I don't see any way to set the device to a specific stream - Daisy just
>
seams to track streams by the menu selection.
I'm not sure what you mean. A device has a set of streams. You cannot tell
the device to use a particular stream. It uses them all, all the time.
>
What would I expect a device
>
with multiple input streams to look like? Would I ever need to process data
>
from multiple streams in a single IOProc simultaneously?
In your IOProc, each stream is represented by a buffer in the appropriate
AudioBufferList that's passed in. You can get an idea of what this will look
like ahead of time using kAudioDevicePropertyStreamConfiguration.
>
Are the streams
>
associated with a source?
Each stream can have a source. kAudioDevicePropertyDataSource covers that.
>
If a device has two input streams each with two
>
channels - would this likely be four channels of simultaneous input or would
>
each stream likely represent different sets of input (analog vs. digital for
>
example)?
It is not necessarily the case that you will get a stream for each jack on
the box you are dealing with. Some devices like to have all the channels
interleaved regardless of whether or not they are physically separate jacks.
Some devices will divide it up into a bunch of single mono streams even
though it's coming from a single multi-channel jack.
The topology of a device can be pretty complicated. The HAL and the IOAudio
driver family are very flexible in how things can be represented (just look
at the driver for the MAudio 10/10 cards for a pretty extreme example). It's
up to the device and the driver to decide how it wants to present things.
>
If the answer is either - how am I supposed to tell the
>
difference?
Tell the difference between what and what?
At this point in time, the HAL doesn't provide any information about the
transport type of a device or stream.
--
Jeff Moore
Core Audio
Apple