Re: Stereo interleaved 16-bit format
Re: Stereo interleaved 16-bit format
- Subject: Re: Stereo interleaved 16-bit format
- From: Jeff Moore <email@hidden>
- Date: Mon, 26 Jan 2004 13:34:47 -0800
You are forgetting to set kAudioFormatFlagIsPacked in the mFlags field
I believe.
On Jan 26, 2004, at 2:08 AM, Austin Shoemaker wrote:
I have that parameter right, I just omitted it. I will continue
another round of trial and error tomorrow to figure out what is going
wrong when I go to stereo. In the mean time, if anybody is aware of
any special differences between QuickTime 16-bit PCM and CoreAudio
16-bit PCM, I would be really interested to know- it would save me
some time.
Thanks,
Austin
On Jan 26, 2004, at 2:03 AM, David Duncan wrote:
On Jan 26, 2004, at 04:35 AM, Austin Shoemaker wrote:
I just wanted to verify the equivalence of the following
specifications in QuickTime and CoreAudio, respectively:
In QuickTime:
format = k16BitBigEndianFormat;
numChannels = 2
sampleSize = 16
sampleRate = rate44khz
sampleCount = ...
In CoreAudio:
mSampleRate = 44100
mFormatID = kAudioFormatLinearPCM
mFormatFlags = kLinearPCMFormatFlagIsSignedInteger |
kLinearPCMFormatFlagIsBigEndian
mFramesPerPacket = 1
mBytesPerFrame = 4
mBytesPerPacket = 4
mBitsPerChannel = 16
These two descriptions specify an identical audio format, right? If
not, what am I missing? My project is working with mono streams,
but things get distorted (raspy, 2x playback speed) when I try to
make it work in interleaved stereo.
I must be doing something wrong, because it all seems right to me.
I have verified that the SoundComponentData record I am getting
matches the format I specified for it.
You forgot mChannelsPerFrame = 2.
--
Reality is what, when you stop believing in it, doesn't go away.
Failure is not an option. It is a privilege reserved for those who
try.
David Duncan
_______________________________________________
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.
--
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.