AAC file header |
![]() ![]() |
AAC file header |
Aug 20 2002, 11:22
Post
#1
|
|
![]() MPEG Audio Collection developer Group: Developer Posts: 34 Joined: 2-May 02 From: Germany Member No.: 1934 |
I saw a description for the AAC file header here:
http://www.audiocoding.com/wiki/index.php?page=AAC , but I could not find how can I get the bitrate/duration from the ADTS header? Does anybody know a better description? And another question: what encoder uses the ADIF header? Please help... |
|
|
|
Aug 20 2002, 11:47
Post
#2
|
|
![]() Nero MPEG4 developer Group: Developer (Donating) Posts: 1218 Joined: 11-October 01 From: LA Member No.: 267 |
Count the number of frames, then you'll know the filesize, samplerate and number of frames, with that you can calculate the bitrate.
There's no easier way I believe, unless someone here has a good suggestion? Menno |
|
|
|
Aug 20 2002, 11:56
Post
#3
|
|
![]() Nero MPEG4 developer Group: Developer (Donating) Posts: 1218 Joined: 11-October 01 From: LA Member No.: 267 |
BTW: ADTS is the same as the headers in MP3, so you should be able to use about the same code (mind the emphasis bits for MPEG-2).
ADIF is supported by PsyTEL and very old versions of FAAC too (before it had ADTS support). Also, the FhG command line encoders use it by default and all the ISO reference AAC files have an ADIF header. Menno |
|
|
|
Aug 20 2002, 12:04
Post
#4
|
|
![]() MPEG Audio Collection developer Group: Developer Posts: 34 Joined: 2-May 02 From: Germany Member No.: 1934 |
> menno: Count the number of frames
Should I read the whole file trough? There must be a better solution, I think... |
|
|
|
Aug 20 2002, 12:06
Post
#5
|
|
![]() MPEG Audio Collection developer Group: Developer Posts: 34 Joined: 2-May 02 From: Germany Member No.: 1934 |
How much samples does an AAC frame contain?
|
|
|
|
Aug 20 2002, 12:13
Post
#6
|
|
![]() Nero MPEG4 developer Group: Developer (Donating) Posts: 1218 Joined: 11-October 01 From: LA Member No.: 267 |
AAC files always have 1024 samples per frame.
In MP4 files it can be 960 too, but I guess you're not working on that yet? Menno |
|
|
|
Aug 20 2002, 12:15
Post
#7
|
|
![]() Nero MPEG4 developer Group: Developer (Donating) Posts: 1218 Joined: 11-October 01 From: LA Member No.: 267 |
What solution are you thinking of? There is no way of telling the number of frames in a VBR file without going through the whole file. There's also no extra header available for that.
Menno |
|
|
|
Aug 20 2002, 13:04
Post
#8
|
|
![]() MPEG Audio Collection developer Group: Developer Posts: 34 Joined: 2-May 02 From: Germany Member No.: 1934 |
How the ACC-Plugin for Winamp get the duration? It doesn't scan the whole file for calculating the number of frames.
|
|
|
|
Aug 20 2002, 13:13
Post
#9
|
|
![]() Nero MPEG4 developer Group: Developer (Donating) Posts: 1218 Joined: 11-October 01 From: LA Member No.: 267 |
Yes it does, check aacinfo.c.
It can also be set to check 30 seconds for example and take the average bitrate of that. Menno |
|
|
|
Aug 20 2002, 13:36
Post
#10
|
|
![]() MPEG Audio Collection developer Group: Developer Posts: 34 Joined: 2-May 02 From: Germany Member No.: 1934 |
Where can I find the source of the AAC-Plugin for Winamp?
|
|
|
|
Aug 20 2002, 13:44
Post
#11
|
|
![]() Nero MPEG4 developer Group: Developer (Donating) Posts: 1218 Joined: 11-October 01 From: LA Member No.: 267 |
|
|
|
|
Aug 20 2002, 13:54
Post
#12
|
|
![]() BeSweet Developer Group: Developer Posts: 235 Joined: 14-December 01 From: sitting on top of a supercompact cardinal Member No.: 643 |
QUOTE Originally posted by menno
1024 samples per frame, per channel AAC files always have 1024 samples per frame. -------------------- DSPguru's Webpage - home of BeSweet & The OggMachine.
BeSplit - 7kb of A loseless AC3/AAC/MP3/MP2/WAV Cutter :) |
|
|
|
Aug 20 2002, 16:32
Post
#13
|
|
![]() Nero MPEG4 developer Group: Developer (Donating) Posts: 1218 Joined: 11-October 01 From: LA Member No.: 267 |
Right! :-)
|
|
|
|
Aug 20 2002, 16:35
Post
#14
|
|
![]() Nero MPEG4 developer Group: Developer (Donating) Posts: 1218 Joined: 11-October 01 From: LA Member No.: 267 |
BTW: Upto channel_configuration == 6 the number of channels is the same as the channel_configuration.
I'll try to add some more info about the headers on the wiki soon. Menno |
|
|
|
Aug 20 2002, 16:40
Post
#15
|
|
![]() MPEG Audio Collection developer Group: Developer Posts: 34 Joined: 2-May 02 From: Germany Member No.: 1934 |
Where can I download AAC examples with ADIF header?
|
|
|
|
Aug 20 2002, 16:44
Post
#16
|
|
![]() Nero MPEG4 developer Group: Developer (Donating) Posts: 1218 Joined: 11-October 01 From: LA Member No.: 267 |
|
|
|
|
Aug 20 2002, 16:49
Post
#17
|
|
![]() MPEG Audio Collection developer Group: Developer Posts: 34 Joined: 2-May 02 From: Germany Member No.: 1934 |
I would like to implement support for AAC files in my project MPEG Audio Collection , therefore I asked for the info.
1) What kind of AAC files are there? 2) Where can I find other ACC encoders (like FhG etc.)? 3) I need ACC examples (various encoders, modes etc.) - for in-depth tests. |
|
|
|
Aug 20 2002, 17:00
Post
#18
|
|
![]() Nero MPEG4 developer Group: Developer (Donating) Posts: 1218 Joined: 11-October 01 From: LA Member No.: 267 |
The ISO reference files found at that at&t website should cover everything. You will not find the FhG encoder that creates AAC files.
There are three different AAC formats possible (4 actually but let's not get into that): RAW ADIF ADTS You will not be able to extract any info from RAW files unless you decode them (which would make binary distribution of your program illegal). ADIF and ADTS I told about, you can find more info on http://www.audiocoding.com/wiki. Menno |
|
|
|
Aug 21 2002, 13:57
Post
#19
|
|
![]() MPEG Audio Collection developer Group: Developer Posts: 34 Joined: 2-May 02 From: Germany Member No.: 1934 |
How can I get the sampling rate from the ADIF header?
|
|
|
|
Aug 21 2002, 14:23
Post
#20
|
|
![]() Nero MPEG4 developer Group: Developer (Donating) Posts: 1218 Joined: 11-October 01 From: LA Member No.: 267 |
Sampling rate is taken from the sampling_frequency_index in the program_config_element.
I updated the ADIF page to describe this program_config_element: http://www.audiocoding.com/wiki/index.php?page=ADIF Menno |
|
|
|
Aug 21 2002, 14:38
Post
#21
|
|
![]() MPEG Audio Collection developer Group: Developer Posts: 34 Joined: 2-May 02 From: Germany Member No.: 1934 |
Thank you!
|
|
|
|
Aug 21 2002, 17:57
Post
#22
|
|
![]() Group: Members Posts: 650 Joined: 28-July 02 From: B'ham UK Member No.: 2828 |
Aah its cool to see you're adding AAC support to your MAC program
|
|
|
|
Aug 22 2002, 13:07
Post
#23
|
|
![]() MPEG Audio Collection developer Group: Developer Posts: 34 Joined: 2-May 02 From: Germany Member No.: 1934 |
I would like to get a sample encoded with the FhG ACC coder. Where can I download one?
|
|
|
|
Aug 22 2002, 13:15
Post
#24
|
|
![]() Nero MPEG4 developer Group: Developer (Donating) Posts: 1218 Joined: 11-October 01 From: LA Member No.: 267 |
If you send me an email, I can send you some.
Menno |
|
|
|
Aug 22 2002, 13:39
Post
#25
|
|
![]() MPEG Audio Collection developer Group: Developer Posts: 34 Joined: 2-May 02 From: Germany Member No.: 1934 |
> menno: If you send me an email, I can send you some.
jfaul at gmx dot de |
|
|
|
![]() ![]() |
|
Lo-Fi Version | Time is now: 20th May 2013 - 09:37 |