Advanced Audio Coding: Difference between revisions
No edit summary |
|||
(30 intermediate revisions by 3 users not shown) | |||
Line 5: | Line 5: | ||
* Sample Docs: [http://standards.iso.org/ittf/PubliclyAvailableStandards/ISO_IEC_14496-4_2004_Conformance_Testing/audio_conformance/mpeg4audio-conformance/doc/fileNameConventions.html sample docs] | * Sample Docs: [http://standards.iso.org/ittf/PubliclyAvailableStandards/ISO_IEC_14496-4_2004_Conformance_Testing/audio_conformance/mpeg4audio-conformance/doc/fileNameConventions.html sample docs] | ||
Specification | Specification links: | ||
*http://www. | *AAC: [http://www.iso.org/iso/iso_catalogue/catalogue_tc/catalogue_detail.htm?csnumber=53943 ISO/IEC 14496-3:2009], [ftp://ftp.tnt.uni-hannover.de/pub/MPEG/audio/mpeg4/documents/ Old (free) drafts] | ||
*Conformance: [http://www.iso.org/iso/catalogue_detail.htm?csnumber=53750 ISO/IEC 14496-26:2010] | |||
*[[ | *Gapless: [http://www.iso.org/iso/catalogue_detail.htm?csnumber=46461 14496-24:2008], [http://www.itscj.ipsj.or.jp/sc29/open/29view/29n7733t.doc Draft] | ||
*[http://www.3gpp.org/ftp/specs/html-info/26-series.htm ETSI 26.401-406] | |||
[[ | Reference Sources: | ||
*http:// | *MPEG [[AAC Reference Software]] | ||
*[http://www.3gpp.org/ftp/specs/html-info/26-series.htm ETSI 26.410-412] | |||
[[ | Usually stored in an [[MP4]] container. | ||
[[ | See also [[Understanding AAC]]. | ||
== Implementations == | |||
=== With Source Code === | |||
*[[Google]] has opensourced Android, which includes an Apache 2.0 licensed aac encoder and decoder: | |||
**http://android.git.kernel.org/?p=platform/frameworks/base.git;a=tree;f=media/libstagefright/codecs;hb=HEAD | |||
*[[Intel]] has source for its IPP based [[AAC]] decoder: | |||
**http://www.intel.com/cd/software/products/asmo-na/eng/perflib/ipp/219967.htm | |||
*[[Real|Real Networks]] has source for its Helix AAC fixedpoint decoder here: | |||
**https://datatype.helixcommunity.org/2005/aacfixptdec | |||
*[[FAAC]]/[[FAAD]] | |||
**http://www.audiocoding.com | |||
*FFmpeg/Libav | |||
*HE-AAC encoder based on 3GPP reference implementation | |||
**http://tipok.org.ua/node/17 | |||
=== Other Notables === | |||
*[[Nero]] has a well regarded freeware AAC encoder and decoder | |||
**http://www.nero.com/enu/technologies-aac-codec.html | |||
*[[Dolby Laboratories|Coding Technologies]] the inventor of [[Spectral Band Replication|SBR]] has a shareware encoder available in [[Winamp]] | |||
**http://www.winamp.com | |||
*[[Apple]] who popularized the format in its [[iTunes]] software has an encoders and decoders available in iTunes and [[QuickTime]]. [[Dolby]] was involved in its implementation. [http://support.apple.com/kb/HT2103] | |||
**http://www.apple.com/itunes | |||
=== Decoder Features === | |||
AAC decoder feature matrix | |||
{| border="1" style="border: 1px #aaa solid; border-collapse: collapse;" | |||
|- | |||
! Decoder | |||
! [http://streams.videolan.org/Mpeg_Conformance/ftp.iis.fhg.de/mpeg4audio-conformance/compressedMp4/al17_44.mp4 al17] | |||
! [http://samples.mplayerhq.hu/A-codecs/AAC/channel_model/elem_id0.mp4 elem_id0] | |||
! [http://samples.mplayerhq.hu/A-codecs/AAC/channel_model/bad_concat.mp4 bad_concat] | |||
! [http://samples.mplayerhq.hu/A-codecs/AAC/channel_model/lfe_is_sce.mp4 lfe_is_sce] | |||
! SBR | |||
! PS | |||
! [http://streams.videolan.org/Mpeg_Conformance/ftp.iis.fhg.de/mpeg4audio-conformance/compressedMp4/al07_44.mp4 CCE] | |||
! [http://streams.videolan.org/Mpeg_Conformance/ftp.iis.fhg.de/mpeg4audio-conformance/compressedMp4/am00_44.mp4 Main] | |||
! [http://streams.videolan.org/Mpeg_Conformance/ftp.iis.fhg.de/mpeg4audio-conformance/compressedMp4/ap01_48.mp4 LTP] | |||
! [http://streams.videolan.org/Mpeg_Conformance/ftp.iis.fhg.de/mpeg4audio-conformance/compressedMp4/er_ad1000_22_ep0.mp4 ER AAC LC] | |||
! [http://streams.videolan.org/Mpeg_Conformance/ftp.iis.fhg.de/mpeg4audio-conformance/compressedMp4/er_al10_44_ep0.mp4 ER AAC LD] | |||
! [http://streams.videolan.org/Mpeg_Conformance/ftp.iis.fhg.de/mpeg4audio-conformance/compressedMp4/al00sf_44.mp4 AAC-960] | |||
! [http://samples.mplayerhq.hu/A-codecs/AAC/aacPlusDecoderCheckPackage_v2.1/bitstreams/File1.aac ADTS (Implicit SBR+PS)] | |||
! [http://samples.mplayerhq.hu/A-codecs/AAC/aacPlusDecoderCheckPackage_v2.1/bitstreams/File2.mp4 MP4 (Implicit SBR+PS)] | |||
! [http://samples.mplayerhq.hu/A-codecs/AAC/aacPlusDecoderCheckPackage_v2.1/bitstreams/File3.mp4 MP4 (EBC SBR / Impl PS)] | |||
! [http://samples.mplayerhq.hu/A-codecs/AAC/aacPlusDecoderCheckPackage_v2.1/bitstreams/File4.mp4 MP4 (EBC SBR / EBC PS)] | |||
! [http://samples.mplayerhq.hu/A-codecs/AAC/aacPlusDecoderCheckPackage_v2.1/bitstreams/File5.mp4 MP4 (Impl SBR / ENBC PS)] | |||
! [http://samples.mplayerhq.hu/A-codecs/AAC/aacPlusDecoderCheckPackage_v2.1/bitstreams/File6.3gp 3GPP (EBC SBR / Impl PS)] | |||
! [http://samples.mplayerhq.hu/A-codecs/AAC/aacPlusDecoderCheckPackage_v2.1/bitstreams/File7.3gp 3GPP (ENBC SBR / Impl PS)] | |||
|- | |||
! mp4mcDec | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
|- | |||
! libavcodec | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| No | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
|- | |||
! libfaad2 | |||
| No | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| No | |||
| Yes | |||
| Yes | |||
| No | |||
| No | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| No | |||
| Yes | |||
| Yes | |||
|- | |||
! iTunes | |||
| No | |||
| No | |||
| Yes | |||
| No LFE | |||
| Yes | |||
| No? | |||
| No | |||
| No | |||
| No | |||
| No | |||
| No | |||
| No | |||
| No | |||
| No SBR | |||
| No PS | |||
| No PS | |||
| No PS | |||
| No PS | |||
| No PS | |||
|- | |||
! WinAMP | |||
| Yes | |||
| Garbled | |||
| No | |||
| Yes | |||
| Yes | |||
| Yes | |||
| No | |||
| No | |||
| No | |||
| No | |||
| No | |||
| No | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| No | |||
| No | |||
|- | |||
! Microsoft DTV-DVD Audio Decoder | |||
| No | |||
| Yes | |||
| Yes | |||
| No LFE | |||
| Yes | |||
| Yes | |||
| Yes | |||
| No | |||
| No | |||
| No | |||
| No | |||
| No | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
| Yes | |||
|} | |||
== Common AAC Flavors == | |||
=== MPEG-2 AAC-LC === | |||
The basic subset of AAC that most other flavors and profiles are based on. | |||
== | === The AAC Profile (MPEG-4 AAC-LC) === | ||
MPEG-2 AAC-LC plus a Perceptual Noise Substitution (PNS) tool. | |||
=== HE-AAC === | === The HE-AAC Profile (v1 and v2) === | ||
HE-AAC (also known | HE-AAC (also known by the [[Dolby Laboratories|Dolby]] trade name [http://www.codingtechnologies.com/products/aacPlus.htm aacPlus]) is MPEG-4 AAC-LC + [[Spectral Band Replication|SBR (Spectral Band Replication)]] and HE-AAC v2 (aacPlus v2) is MPEG-4 AAC-LC + SBR + [http://www.codingtechnologies.com/products/paraSter.htm PS (Parametric Stereo)]. Standard AAC-LC decoders can decode HE-AAC encoded files/streams but without SBR and PS you do not get the full quality. | ||
* See also | * See also | ||
** [[MP3#mp3PRO|MP3PRO]] that also uses SBR. | ** [[MP3#mp3PRO|MP3PRO]] that also uses SBR. | ||
=== MPEG-2/4 AAC Main === | |||
MPEG-2/4 AAC-LC plus a computationally intensive, intra-channel, inter-frame frequency domain prediction tool. Additionally this profile adds relaxation to the maximum TNS filter size, and time domain coupling. The details of the prediction tool are only given in ISO/IEC 13818-7 not in ISO/IEC 14496-3. In the wild this appears to be used in some [[Hulu]] streams. | |||
=== MPEG-4 AAC LTP === | |||
MPEG-4 AAC-LC plus a less computationally intensive frequency domain prediction tool. This flavor is rarely seen in the wild. Despite being an MPEG-4 only flavor it can be embedded in an [[ADTS]] stream. | |||
=== BSAC AAC === | |||
Bit Slice Arithmetic Coding (BSAC) is an alternate quantization and entropy coding scheme for AAC. It is used by the [[T-DMB]] broadcast standard. | |||
== Extensions == | |||
=== GAIN headers === | === GAIN headers === | ||
Line 37: | Line 218: | ||
See http://mp3gain.sourceforge.net and [[MP3#GAIN (MP3Gain) header|MP3 GAIN header]]. | See http://mp3gain.sourceforge.net and [[MP3#GAIN (MP3Gain) header|MP3 GAIN header]]. | ||
=== MPEG Surround === | |||
[http://www.mpegsurround.com MPEG Surround] is a multichannel coding scheme that can used with any core coder audio but is most often used with (HE-)AAC and BSAC. MPEG Surround technology shares similar characteristics with PS (Parametric Stereo) used in HE-AAC v2 including mixing in the same [[SBR]] domain used by HE-AAC. | |||
References: | |||
*[http://mpeg.chiariglione.org/technologies/mpeg-d/mpd-mps/index.htm N7390: Tutorial on MPEG Surround Audio Coding] | |||
*[http://web.archive.org/web/20071008044710/http://www.codingtechnologies.com/products/mpgsrnd.htm Coding Technologies product page] | |||
== AAC Encoding Guidelines == | |||
The following documents are must reads for anyone implementing an AAC encoder | |||
* ISO/IEC 14496-3:2009 - Decoding AAC, systems MPEG-4 integration | |||
* ISO/IEC 14496-26:2010 - Conformance, includes limits on various bitstream values | |||
* ISO/IEC 14496-24:2008 - ISO Gapless AAC | |||
* ISO/IEC 13818-7:2006 - MPEG-2 AAC includes informative annexes on encoding omitted from 14496-3 | |||
* 3GPP 26.403-405 - Elaborations on the annexes in 13818-7 | |||
* [http://www.mp3-tech.org/programmer/docs/di042001.pdf Improved ISO AAC Coder, Ivan Dimkovic, PsyTEL Research] | |||
[[Category:Audio Codecs]] | [[Category:Audio Codecs]] | ||
[[Category: MDCT Audio Codecs]] | [[Category: MDCT Audio Codecs]] | ||
[[Category: Multichannel Audio Codecs]] | [[Category: Multichannel Audio Codecs]] |
Latest revision as of 14:21, 31 October 2013
- FourCC: AAC AACP MP4A mp4a VLB
- Company: ISO
- Samples: http://samples.mplayerhq.hu/A-codecs/AAC/
- Samples: sample repo at standards.iso.org
- Sample Docs: sample docs
Specification links:
- AAC: ISO/IEC 14496-3:2009, Old (free) drafts
- Conformance: ISO/IEC 14496-26:2010
- Gapless: 14496-24:2008, Draft
- ETSI 26.401-406
Reference Sources:
Usually stored in an MP4 container.
See also Understanding AAC.
Implementations
With Source Code
- Google has opensourced Android, which includes an Apache 2.0 licensed aac encoder and decoder:
- Intel has source for its IPP based AAC decoder:
- Real Networks has source for its Helix AAC fixedpoint decoder here:
- FAAC/FAAD
- FFmpeg/Libav
- HE-AAC encoder based on 3GPP reference implementation
Other Notables
- Nero has a well regarded freeware AAC encoder and decoder
- Coding Technologies the inventor of SBR has a shareware encoder available in Winamp
- Apple who popularized the format in its iTunes software has an encoders and decoders available in iTunes and QuickTime. Dolby was involved in its implementation. [1]
Decoder Features
AAC decoder feature matrix
Decoder | al17 | elem_id0 | bad_concat | lfe_is_sce | SBR | PS | CCE | Main | LTP | ER AAC LC | ER AAC LD | AAC-960 | ADTS (Implicit SBR+PS) | MP4 (Implicit SBR+PS) | MP4 (EBC SBR / Impl PS) | MP4 (EBC SBR / EBC PS) | MP4 (Impl SBR / ENBC PS) | 3GPP (EBC SBR / Impl PS) | 3GPP (ENBC SBR / Impl PS) |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
mp4mcDec | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | |||||||
libavcodec | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | No | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
libfaad2 | No | Yes | Yes | Yes | Yes | Yes | No | Yes | Yes | No | No | Yes | Yes | Yes | Yes | Yes | No | Yes | Yes |
iTunes | No | No | Yes | No LFE | Yes | No? | No | No | No | No | No | No | No | No SBR | No PS | No PS | No PS | No PS | No PS |
WinAMP | Yes | Garbled | No | Yes | Yes | Yes | No | No | No | No | No | No | Yes | Yes | Yes | Yes | Yes | No | No |
Microsoft DTV-DVD Audio Decoder | No | Yes | Yes | No LFE | Yes | Yes | Yes | No | No | No | No | No | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
Common AAC Flavors
MPEG-2 AAC-LC
The basic subset of AAC that most other flavors and profiles are based on.
The AAC Profile (MPEG-4 AAC-LC)
MPEG-2 AAC-LC plus a Perceptual Noise Substitution (PNS) tool.
The HE-AAC Profile (v1 and v2)
HE-AAC (also known by the Dolby trade name aacPlus) is MPEG-4 AAC-LC + SBR (Spectral Band Replication) and HE-AAC v2 (aacPlus v2) is MPEG-4 AAC-LC + SBR + PS (Parametric Stereo). Standard AAC-LC decoders can decode HE-AAC encoded files/streams but without SBR and PS you do not get the full quality.
- See also
- MP3PRO that also uses SBR.
MPEG-2/4 AAC Main
MPEG-2/4 AAC-LC plus a computationally intensive, intra-channel, inter-frame frequency domain prediction tool. Additionally this profile adds relaxation to the maximum TNS filter size, and time domain coupling. The details of the prediction tool are only given in ISO/IEC 13818-7 not in ISO/IEC 14496-3. In the wild this appears to be used in some Hulu streams.
MPEG-4 AAC LTP
MPEG-4 AAC-LC plus a less computationally intensive frequency domain prediction tool. This flavor is rarely seen in the wild. Despite being an MPEG-4 only flavor it can be embedded in an ADTS stream.
BSAC AAC
Bit Slice Arithmetic Coding (BSAC) is an alternate quantization and entropy coding scheme for AAC. It is used by the T-DMB broadcast standard.
Extensions
GAIN headers
See http://mp3gain.sourceforge.net and MP3 GAIN header.
MPEG Surround
MPEG Surround is a multichannel coding scheme that can used with any core coder audio but is most often used with (HE-)AAC and BSAC. MPEG Surround technology shares similar characteristics with PS (Parametric Stereo) used in HE-AAC v2 including mixing in the same SBR domain used by HE-AAC.
References:
AAC Encoding Guidelines
The following documents are must reads for anyone implementing an AAC encoder
- ISO/IEC 14496-3:2009 - Decoding AAC, systems MPEG-4 integration
- ISO/IEC 14496-26:2010 - Conformance, includes limits on various bitstream values
- ISO/IEC 14496-24:2008 - ISO Gapless AAC
- ISO/IEC 13818-7:2006 - MPEG-2 AAC includes informative annexes on encoding omitted from 14496-3
- 3GPP 26.403-405 - Elaborations on the annexes in 13818-7
- Improved ISO AAC Coder, Ivan Dimkovic, PsyTEL Research