Re: Different number of channels in IOProc
Re: Different number of channels in IOProc
- Subject: Re: Different number of channels in IOProc
- From: Jeff Moore <email@hidden>
- Date: Fri, 26 Apr 2002 14:25:51 -0700
on 4/26/02 1:03 PM, Jim Dolan <email@hidden> wrote:
>
I am getting the size from the bufferlist's in the IOProc -
>
>
If this is a bug - Do you think it is the device driver or is it a CoreAudio
>
problem - The device I am using is a Tascam US-428 which has its own driver.
Well, the bug I hear you reporting is that kAudioDevicePropertyBufferSize is
returning the same value for input as it does for output on a stream despite
having differing numbers of channels. I looked at the code in the HAL and
sure enough it will erroneously report the same number for both.
If this isn't what you're having trouble with, then you might want to start
again from the beginning.
>
This sucks because many of my methods require the buffersize in bytes!
>
This means that I have to redo a lot tricky calculations to ensure that it
>
is working correctly...
kAudioDevicePropertyBufferSize really shouldn't be getting used any more. It
will only ever be accurate for devices with one stream for input and/or one
stream for output (presuming the bug gets fixed of course). This is why we
added kAudioDevicePropertyBufferFrameSize.
To convert from a frame size to a byte size for a given stream, all you need
is that stream's stream description and you can just multiply by
mBytesPerFrame.
--
Jeff Moore
Core Audio
Apple
_______________________________________________
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.