Re: AudioQueueNewOutput error
Re: AudioQueueNewOutput error
- Subject: Re: AudioQueueNewOutput error
- From: Brian Whitman <email@hidden>
- Date: Wed, 30 Apr 2008 10:51:40 -0400
On Apr 30, 2008, at 8:10 AM, Roland Silver wrote:
The fields of ASBDesc are set by initASBDesc():
ASBDesc.mSampleRate = consts.SampleRate; //consts.SampleRate =
44100.0
ASBDesc.mFormatID = kAudioFormatLinearPCM;
ASBDesc.mFormatFlags = kAudioFormatFlagsNativeFloatPacked;
ASBDesc.mBytesPerFrame =
consts.channelsPerFrame * consts.valuesPerChannel *
consts.bytesPerValue;
//mBytesPerFrame = 16
ASBDesc.mFramesPerPacket = consts.framesPerPacket; //1
ASBDesc.mChannelsPerFrame = consts.channelsPerFrame; //2
ASBDesc.mBitsPerChannel =
consts.valuesPerChannel * consts.bytesPerValue * consts.bitsPerByte;
//mBitsPerChannel = 64
You're missing mBytesPerPacket (which == mBytesPerFrame for PCM)
And I really don't think you mean to have 64 bits per channel. For a
Float type that should be 32 (and then bytesPerFrame should be
modified accordingly.) What is consts.valuesPerChannel mean?
_______________________________________________
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