Temporal VBR tuning
authorJean-Marc Valin <jmvalin@jmvalin.ca>
Mon, 1 Jul 2013 20:12:27 +0000 (16:12 -0400)
committerJean-Marc Valin <jmvalin@jmvalin.ca>
Mon, 1 Jul 2013 20:14:48 +0000 (16:14 -0400)
Applies temporal VBR up to higher bitrates after IgorC reported it being
useful at 64 kb/s for amount=0.1

celt/celt_encoder.c

index bcaf36a..d77c80f 100644 (file)
@@ -1215,7 +1215,7 @@ static int compute_vbr(const CELTMode *mode, AnalysisInfo *analysis, opus_int32
    {
       opus_val16 amount;
       opus_val16 tvbr_factor;
-      amount = MULT16_16_Q15(QCONST16(.000006f, 30), IMAX(0, IMIN(42000, 68000-bitrate)));
+      amount = MULT16_16_Q15(QCONST16(.0000031f, 30), IMAX(0, IMIN(32000, 96000-bitrate)));
       tvbr_factor = SHR32(MULT16_16(temporal_vbr, amount), DB_SHIFT);
       target += (opus_int32)MULT16_32_Q15(tvbr_factor, target);
    }