View Single Post
Old 2nd August 2011, 00:08   #16  |  Link
IanB
Avisynth Developer
 
Join Date: Jan 2003
Location: Melbourne, Australia
Posts: 3,167
No question, Quality constrained, Variable Bitrate encoding gives the best available audio quality for the total space used. And all the posts in this thread keep confirming this.

For Quality constrained, Variable Bitrate encoding the rules are simple, use as many or few bits as required to encode this audio while maintaining a psycho-acoustic quality of the specified value. If a given 1 second of audio needs 1024kb/s then use 1024 kilobits. If another 1 second can be faithfully compressed at 4kb/s then just use 4 kilobits. This is what -q=value encoding with AAC is all about.

With CBR encoding the rules are very different. Here the goal is to make sure that the sustained bitrate is maintained within the declared buffer size. The rules are imposed for some bandwidth limited element in the distribution path, maybe a DVB channel allocation, maybe the minimum transfer speed of domestic DVD players, maybe the speed of your internet connection. If a given 1 second of audio has to be squeezed to q=0.01 to fit into a 64kb/s stream then the sound gets mashed, no choice. If another 1 second can be faithfully compressed at q=1.0 and still fit into the 64kb/s stream then we have good luck and the stream possibly gets some padding bits added.

When recompressing a CBR constrained stream as Quality constrained you need to consider the psycho-acoustic quality of each second of audio. If the CBR rate control function deemed a section of audio needs a q=0.2 then that audio is mashed forever, the VBR encoder happily encodes the simplified audio easily effectively at q=0.2. However if the CBR rate control function deemed a section of audio can be encoded at q=0.7 but the VBR encoder has been told do q=0.3 for that section the quality will be reduced to q=0.3. So what you get is a a variable quality stream with a maximum q=value as specified but lower values where the CBR rate control needed to squeeze harder. So the comparisons are a little unfair.

But as I said earlier commercial AC3 streams are very generous there is lots of fat to trim.


Also interesting observation that nero doesn't find good correlation in 5.1 streams. It's a very difficult problem because the ambience sound is delayed from the initial sound so you need to correlate across a wide time, maybe wider than duration of a compressed audio frame.
IanB is offline   Reply With Quote