Simple HAL device question
Simple HAL device question
- Subject: Simple HAL device question
- From: Christopher Corbell <email@hidden>
- Date: Thu, 29 Aug 2002 08:28:43 -0700
Sorry if this has been asked before, I'm new to the list
& didn't find it in last month's archives...
I am looking for the best method to determine the channels available for a
given AudioDeviceID and their basic characteristics. I'm coding from the
perspective of a client application that does not know anything about the
devices connected.
I'm using GetDeviceProperty(kAudioDevicePropertyStreams...) and I find 1
stream ID per device ID. I set the channel ID set to 0 for the query.
This seems
OK. If no stream is found for a query I switch the -is-input- flag and
try again
and it works, which lets me know whether the device is input or output.
Is this
the right way to determine this?
Calling GetDeviceProperty(kAudioDevicePropertyStreamConfiguration)
for the same set of devices returns without errors but one of the
devices returns
an AudioBufferList with 0 channels. This happens regardless of the
is-input flag with this device. Is this normal?
All of my initial queries use channel-ID 0. Is one supposed to iterate
through channel numbers until an error is returned to determine
how many channels are available? Which property selector would
I use for such an iteration to prove that a channel is valid?
Or is there a simple way to just get an array or range of channels for a
device?
Thanks in advance,
Chris
_______________________________________________
coreaudio-api mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/coreaudio-api
Do not post admin requests to the list. They will be ignored.