Re: Device sample rates and stream virtual formats
Re: Device sample rates and stream virtual formats
- Subject: Re: Device sample rates and stream virtual formats
- From: Jeff Moore <email@hidden>
- Date: Sun, 01 Aug 2010 13:48:23 -0700
On Jul 31, 2010, at 2:29 PM, Stephen F. Booth wrote:
> When one sets a device's sample rate (kAudioDevicePropertyNominalSampleRate), is it expected that the device's streams will change their virtual formats (kAudioStreamPropertyVirtualFormat) to match the new sample rate?
Yes. The physical format properties would be updated as well.
> I searched the archives and documentation and wasn't able to find any clarification on the matter.
An AudioDevice can only have one current sample rate.
> This is the behavior that I've been seeing with the built-in audio on my MacBook Pro as well as on two different external USB DACs. I recently acquired a FireWire audio interface and it seems that most of the time, but not all of the time, the virtual format changes along with the device's sample rate. When the virtual format does not change but the sample rate does, strange things happen since I end up sending audio at the wrong rate to the stream.
>
> I should probably note that I register property listeners on the device and stream, and use them to determine when I need to adjust the audio format I'm sending.
That sounds like a bug of some sort. It's probably worth filing something so we can take a look.
--
Jeff Moore
Core Audio
Apple
_______________________________________________
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