I converted an audio stream into 3 different settings using essentially the same format. They ended up being exactly the same size. Why is this?

ffmpeg -i "Likoonl-Q1-All.mp4" -c:v copy -c:a libmp3lame -q:a 1 -b:a 192k "Q1-All-192k.mp4"
ffmpeg -i "Likoonl-Q1-All.mp4" -c:v copy -c:a libmp3lame -q:a 1 -b:a 160k "Q1-All-160k.mp4"
ffmpeg -i "Likoonl-Q1-All.mp4" -c:v copy -c:a libmp3lame -q:a 1 -b:a 128k "Q1-All-128k.mp4"

Because you're setting -q:a which is LAME's VBR setting. When you use -q:a, the CBR setting (-b:a) will have no effect.

If you look into the MP3 encoding guide from the FFmpeg wiki you'll find the possible values for -q:a with their corresponding average bitrate.

For completeness' sake, here's the relevant part of libmp3lame.cqscale is the long name of q:

/* rate control */
if (avctx->flags & CODEC_FLAG_QSCALE) { // VBR
    lame_set_VBR(s->gfp, vbr_default);
    lame_set_VBR_quality(s->gfp, avctx->global_quality / (float)FF_QP2LAMBDA);
} else {
    if (avctx->bit_rate) {
        if (s->abr) {                   // ABR
            lame_set_VBR(s->gfp, vbr_abr);
            lame_set_VBR_mean_bitrate_kbps(s->gfp, avctx->bit_rate / 1000);
        } else                          // CBR
            lame_set_brate(s->gfp, avctx->bit_rate / 1000);
  • 28
    4 minutes to find the source. +1 – Jonas Schäfer Oct 15 '14 at 19:38
  • I wondered if that wasn't the case! Thanks a lot. – Arlen Beiler Oct 15 '14 at 19:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.