Re: AudioConverter MP3 decode questions
Re: AudioConverter MP3 decode questions
- Subject: Re: AudioConverter MP3 decode questions
- From: William Stewart <email@hidden>
- Date: Wed, 15 Mar 2006 12:37:27 -0800
On 14/03/2006, at 4:25 PM, Vince Shumaker wrote:
Thought I'd also forward this to the list...
Thanks!
How time a given packet represents is described by the ASBD - most
formats specify a frames per packet (for linear pcm this is 1, for
compressed its generally > 1). For instance, AAC typically represents
its data as 1024 frames/packet - apple lossless as 4096, etc...
...and for MP3 its 1152? I'd like to clarify what this should be when
I create an AudioConverter using ASBD. I know that MP3 frames have a
fixed number of 1152 samples/frame. I've also seen some of the
/Developer examples using AudioFile api to get the ASBD... and the
frames/packet value comes back as 1152.
So I guess that I shouldn't think about "samples per frame" vs "frames
per packet" when describing MP3. It's really just a blob of time
expressed as 1152?
Its a blob of data that represents a period of time -> frames per
packet / sample rate (to give you that time in seconds), But yes, you
got it.
There's some utility calls in the AudioFormat API to fill out ASBD -
have a look at the utility code for the ConvertFile example in the
SDK. By using the AFormat calls, you don't have to hard code this
stuff in your own code.
Bill
--
mailto:email@hidden
tel: +1 408 974 4056
________________________________________________________________________
__
"Much human ingenuity has gone into finding the ultimate Before.
The current state of knowledge can be summarized thus:
In the beginning, there was nothing, which exploded" - Terry Pratchett
________________________________________________________________________
__
_______________________________________________
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