PDA

View Full Version : Correlation between sample rate and bitrate (aac)


Selur
12th August 2008, 09:24
Using mencoder to convert audio streams to aac I stumbled over the phenomenon (http://forum.doom9.org/showthread.php?p=1168295#post1168295) that when wanting to encode at a lower bitrate I would have to lower the samplerate.

using MEncoder Sherpya-SVN-r27323-4.2.4 with this command line:
mencoder -mc 0 -noskip "test.avi" -ovc copy -oac faac -faacopts br=64:mpeg=4:object=2 -af volume=5 -channels 2 -srate 48000 -of rawaudio -o "test.aac"
and changing the samplerate (srate) I get the following bitrates for the output:
srate->bitrate
48000 -> 128kBit/s+
32000 -> 96kBit/s+
24000 -> 76kBit/s+
22000 -> 72kBit/s+
22500 -> 72kBit/s+
20000 -> 66kBit/s+
19000 -> 64kBit/s+
16000 -> 62kBit/s+
12000 -> 64kBit/s+
8000 -> 56kBit/s+

Since I can't find any documentation about the relationship between bitrate and samplerate I'd like to know if someone knows of some?
I'd like to know what sample rate I would have to choose for encoding to hit a specific bitrate. Atm. it's more like encoding x time, changing the sample rate to hit the average bitrate I aim for.

Cu Selur

Blue_MiSfit
15th August 2008, 22:06
Why would you adjust the sample rate manually for the sake of lowering the bitrate?!

It's much simpler to just select your target bitrate, and let the AAC encoder subsample if necessay...

~MiSfit

Selur
19th August 2008, 08:12
I normally do not want to change the sample rate, but ffmpeg assumes a sample rate of 48kHz for the output if you choose nothing and so you can't reach low datarates without specifying the sample rate.