Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > General > Audio encoding

Reply
 
Thread Tools Search this Thread Display Modes
Old 9th October 2010, 23:11   #1  |  Link
simps
Registered User
 
Join Date: Feb 2005
Posts: 149
LC-AAC and HE-AAC for 5.1 audio

I am trying to understand a bit more about multi-channel AAC. Can someone help?

1) What is the difference between LC-AAC and HE-AAC in multi-channel (5.1)?

2) For 5.1 audio, which one is better (quality wise)? LC-AAC or HE-AAC? (If the answer depends on the bitrate, please show me the details)

3) What are the available encoders for LC-AAC and HE-AAC? (for 5.1 audio)

4) Is there a "prefered" encoder, quality wise?

5) I've only heard about LC-AAC and HE-AAC for 5.1 audio, but is there a better (quality wise) AAC variant?

Thanks,
Simps
simps is offline   Reply With Quote
Old 9th October 2010, 23:39   #2  |  Link
The Scientist
Registered User
 
The Scientist's Avatar
 
Join Date: Nov 2006
Location: UK
Posts: 275
A quick Google search answers all your questions.
The Scientist is offline   Reply With Quote
Old 10th October 2010, 00:14   #3  |  Link
simps
Registered User
 
Join Date: Feb 2005
Posts: 149
I used google for this (before I wrote the thread), but 95% of the results were for AAC and stereo. The other 5% really didn't help. I am interested in AAC 5.1 audio. Can someone help?
simps is offline   Reply With Quote
Old 10th October 2010, 00:41   #4  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 6,915
Is the same for stereo or 5.1. With AAC-HE the high frequencies are encoded with a special method (SBR) than work better for low bitrates.
Then for better quality use high bitrates and AAC-LC encode.

Please read http://en.wikipedia.org/wiki/Advanced_Audio_Coding
__________________
BeHappy, AviSynth audio transcoder.
tebasuna51 is offline   Reply With Quote
Old 10th October 2010, 00:48   #5  |  Link
Midzuki
Unavailable
 
Midzuki's Avatar
 
Join Date: Mar 2009
Location: offline
Posts: 1,480
Quote:
3) What are the available encoders for LC-AAC and HE-AAC? (for 5.1 audio)
neroaacenc

faac

There is also QuickTime,
but I don't use QuickTime since 1999.

Nero encoder is usually regarded as the "b35t" freeware AAC compressor available.
Midzuki is offline   Reply With Quote
Old 10th October 2010, 14:30   #6  |  Link
simps
Registered User
 
Join Date: Feb 2005
Posts: 149
Thanks tebasuna51 and Midzuki.

Quote:
Originally Posted by Midzuki View Post
neroaacenc

faac

There is also QuickTime,
but I don't use QuickTime since 1999.

Nero encoder is usually regarded as the "b35t" freeware AAC compressor available.
I have used neroaacenc before. I thought it wasn't able to do 5.1 audio? If I remember, you have to feed neroaacenc with a single .wav file.

So, how do you encode 5.1 audio (6 mono .wav files) with neroaacenc?
simps is offline   Reply With Quote
Old 10th October 2010, 15:00   #7  |  Link
nurbs
Registered User
 
Join Date: Dec 2005
Posts: 1,460
Quote:
Originally Posted by simps View Post
If I remember, you have to feed neroaacenc with a single .wav file.

So, how do you encode 5.1 audio (6 mono .wav files) with neroaacenc?
.wav files can be 5.1 or more channels. If you have 6 mono .wavs combine them to a 5.1 wav. There is software that can do this mentioned in this subforum, but I'm too lazy to search. It's probably easiest not to decode you source to multiple wav files to begin with.
Nero also accepts input from stdin.

edit:
Wavewizard can combine the wavs.

Last edited by nurbs; 10th October 2010 at 15:03.
nurbs is offline   Reply With Quote
Old 10th October 2010, 16:11   #8  |  Link
shon3i
BluRay Maniac
 
shon3i's Avatar
 
Join Date: Dec 2005
Posts: 2,419
Never use faac for any aac encoding, because is unfinished. NeroAAC, CTAAC (now Dolby) or QTAAC is freely avaible, and produce very high quality.

as input you need 6ch interleaved wav file.

And keep in mind, never go below 300kbps if you use LC-AAC.
shon3i is offline   Reply With Quote
Old 11th October 2010, 00:49   #9  |  Link
simps
Registered User
 
Join Date: Feb 2005
Posts: 149
Thanks nurbs and shon3i.

I think I will give AAC 5.1 a try.
Since my source will usually be a 5.1ch ac3 or dts file, I will do this:

1) demux to 6 mono wavs with eac3to
2) mux the 6 mono wavs into a single 6ch wav (I will need to learn more about this. About the channel order, the tool to do it, etc)
3) neroaacenc. I think neroaacenc will automaticly set LC, HE or HEv2 based on the -q value, or the bitrate. So all I need to do is especify a "q" value, or a "bitrate".

My goal is to shrink the audio files in the movies I encode for backup. I usually do AC3 5.1ch at 320kb/s. I hope I can shrink it to 256kb/s with AAC, keeping the same quality... we will see.
simps is offline   Reply With Quote
Old 11th October 2010, 00:55   #10  |  Link
nurbs
Registered User
 
Join Date: Dec 2005
Posts: 1,460
You can directly encode with with NeroAAC encoder using eac3to as long as the encoder is in the same directory.

eac3to input.ac3 output.aac -quality=0.45

or -256 if you want bitrate instead of quality.
nurbs is offline   Reply With Quote
Old 11th October 2010, 01:00   #11  |  Link
simps
Registered User
 
Join Date: Feb 2005
Posts: 149
Quote:
Originally Posted by nurbs View Post
You can directly encode with with NeroAAC encoder using eac3to as long as the encoder is in the same directory.

eac3to input.ac3 output.aac -quality=0.45

or -256 if you want bitrate instead of quality.
I thought that only worked with 2ch ac3? Are you sure that works with 5.1 ac3 too?
simps is offline   Reply With Quote
Old 11th October 2010, 01:13   #12  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 6,915
Quote:
Originally Posted by simps View Post
I thought that only worked with 2ch ac3? Are you sure that works with 5.1 ac3 too?
Of course, try before with -quality=0.35, with 0.45 you obtain a bitrate average greater than 256 Kb/s I think.
__________________
BeHappy, AviSynth audio transcoder.
tebasuna51 is offline   Reply With Quote
Old 11th October 2010, 03:53   #13  |  Link
IgorC
Registered User
 
Join Date: Apr 2004
Posts: 1,315
Nero encoder can do 2-pass ABR. It makes sense for large files (in opposite of songs). Nero VBR is enough constrained but still admits some wider deviation of bitrate than ABR.


Quote:
Originally Posted by shon3i View Post
.
And keep in mind, never go below 300kbps if you use LC-AAC.
Nero goes for HE-AAC up to 200-220 kbps for 5.1 by default (recommended) and higher is only LC-AAC.

Plus it depends a lot of compressibility.
IgorC is offline   Reply With Quote
Old 11th October 2010, 12:53   #14  |  Link
simps
Registered User
 
Join Date: Feb 2005
Posts: 149
Quote:
Originally Posted by IgorC View Post
Nero encoder can do 2-pass ABR. It makes sense for large files (in opposite of songs). Nero VBR is enough constrained but still admits some wider deviation of bitrate than ABR.



Nero goes for HE-AAC up to 200-220 kbps for 5.1 by default (recommended) and higher is only LC-AAC.

Plus it depends a lot of compressibility.
Is it possible to do 2-pass AAC encodes using eac3to? What would be the syntax?
simps is offline   Reply With Quote
Old 11th October 2010, 15:49   #15  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 6,915
Is not possible. For a 2-pass AAC encode you need a physical wav file.
You can decode the source to wav and after use the NeroAacEnc CLI.
__________________
BeHappy, AviSynth audio transcoder.
tebasuna51 is offline   Reply With Quote
Old 11th October 2010, 18:14   #16  |  Link
simps
Registered User
 
Join Date: Feb 2005
Posts: 149
Quote:
Originally Posted by tebasuna51 View Post
Is not possible. For a 2-pass AAC encode you need a physical wav file.
You can decode the source to wav and after use the NeroAacEnc CLI.
Ok, thanks.
I will share an info that might be useful to someone...

I encoded a 448kbps 5.1ch AC3 with eac3to input.ac3 output.m4a -quality=0.3 and this is what media info says about the output.m4a file:

-------------------------------

Audio
ID : 1
Format : AAC
Format/Info : Advanced Audio Codec
Format version : Version 4
Format profile : LC
Format settings, SBR : Yes
Format settings, PS : No
Codec ID : 40
Duration : 3h 13mn
Bit rate mode : Variable
Bit rate : 222 Kbps
Maximum bit rate : 308 Kbps
Channel(s) : 6 channels
Channel positions : Front: L C R, Side: L R, LFE
Sampling rate : 48.0 KHz
Stream size : 307 MiB (100%)
Encoded date : UTC 2010-10-11 14:12:01
Tagged date : UTC 2010-10-11 14:25:42


-------------------------------

So, for this particular source (will change from source to source), -q 0.3 resulted in a 222kbps 5.1ch AAC file. Note that it is using SBR, so I guess this would be an AAC-HE, instead of AAC-LC.

I did some blind test, switching between the 448kbps AC3 and the 222kbps AAC. They sound pretty much the same, with a tiny advantage for the AC3 file, pretty much negligible, very hard to detect.

So, I would recomend AAC with -q ~0.3 for 5.1ch audio. This will save space, and will give you the chance to raise your video bitrate for more image quality too.

I have only tested -q 0.3 with 5.1ch movie audio tracks. I don't know about stereo or music audio tracks, but I would imagine that for stereo music, -q 0.3 might not be enough, you might wanna use -q 0.35 or even higher values for stereo music tracks.

Last edited by simps; 11th October 2010 at 18:27.
simps is offline   Reply With Quote
Old 12th October 2010, 00:00   #17  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 6,915
-q 0.3 is the boundary betwenn AAC-HE and AAC-LC, for that I recommend -q 0.35 at least to recode AC3 448 or DTS 768.
Still there are players without support for SBR part, then for a little more bitrate you obtain a more compatible stream.

With the same sample:
encoded -q 0.30 -> AAC-HE 231 Kb/s
encoded -q 0.35 -> AAC-LC 266 Kb/s
__________________
BeHappy, AviSynth audio transcoder.

Last edited by tebasuna51; 12th October 2010 at 00:09.
tebasuna51 is offline   Reply With Quote
Old 12th October 2010, 09:20   #18  |  Link
SeeMoreDigital
Life's clearer in 4K UHD
 
SeeMoreDigital's Avatar
 
Join Date: Jun 2003
Location: Notts, UK
Posts: 12,227
Quote:
Originally Posted by Midzuki View Post
There is also QuickTime,
but I don't use QuickTime since 1999
When it comes to playback, Quicktime player does not support AAC-HE (SBR) decoding. And the Pro version does not offer AAC-HE encoding...
__________________
| I've been testing hardware media playback devices and software A/V encoders and decoders since 2001 | My Network Layout & A/V Gear |

Last edited by SeeMoreDigital; 12th October 2010 at 09:22.
SeeMoreDigital is offline   Reply With Quote
Old 12th October 2010, 13:38   #19  |  Link
simps
Registered User
 
Join Date: Feb 2005
Posts: 149
Quote:
Originally Posted by tebasuna51 View Post
-q 0.3 is the boundary betwenn AAC-HE and AAC-LC, for that I recommend -q 0.35 at least to recode AC3 448 or DTS 768.
Still there are players without support for SBR part, then for a little more bitrate you obtain a more compatible stream.

With the same sample:
encoded -q 0.30 -> AAC-HE 231 Kb/s
encoded -q 0.35 -> AAC-LC 266 Kb/s
I recode with -q 0.35 and got this:

-q 0.30 -> AAC-HE 222 Kbps (SBR: Yes)
-q 0.35 -> AAC-LC 260 Kbps (SBR: No)

I did some blind test between both files, and I couldn't tell the difference. Dialogs were just as clean in both files. There were some explosions and gun shots too, and I kept going back into those parts to try to see a difference between the files, and I couldn't. The audio is from a war movie, so there were some pretty complicated parts, and also, some silent parts. I couldn't find a difference between both files in the blind test, and I did it with a good HI-FI headphone (AT-AD900) and a X-FI sound card.

So, I guess the SBR algorithm is doing a really good job. 222kbps is 85% of 260kbps so you would expect a decrease in quality since 260kbps is already a bit low for 5.1ch audio, but for me, the quality was the same. I couldn't find a difference in the high freqs, or any other freq.

I guess if one is concerned about compatibility, then might be good to avoid SBR, as you said, since some players won't be able to decode it. But if that is not a problem, I think there is no point to be afraid of SBR. It really helps compression, and I wasn't able to detect any change in quality, even with an AT-AD900. OF course, if you go down as much as -q 0.25 or so, I am sure quality will suffer a lot. And all of this is valid only for 5.1ch movie tracks. For stereo music, you would need a higher -q value, and no SBR. Both -q 0.3 and -q 0.35 will give you enough quality for 5.1ch movie tracks in my opinion. One will waste a little more bitrate, but will be compatible with more players.

Anyway, thanks for all the help you guys provided in this thread. I learned a lot about AAC here.

Last edited by simps; 12th October 2010 at 13:53.
simps is offline   Reply With Quote
Old 17th October 2010, 03:52   #20  |  Link
IgorC
Registered User
 
Join Date: Apr 2004
Posts: 1,315
Quote:
Originally Posted by SeeMoreDigital View Post
When it comes to playback, Quicktime player does not support AAC-HE (SBR) decoding. And the Pro version does not offer AAC-HE encoding...
QT has HE-AAC codec (both encode and decode). And it's very good.
http://www.hydrogenaudio.org/forums/...opic=74781&hl=

http://tmkk.hp.infoseek.co.jp/qtaacenc/

Last edited by IgorC; 17th October 2010 at 03:54.
IgorC is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 09:03.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.