summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Marc Valin <jmvalin@jmvalin.ca>2016-06-02 18:15:00 -0400
committerJean-Marc Valin <jmvalin@jmvalin.ca>2016-06-02 18:15:00 -0400
commita0121298086718502d4597b86cab4eeeac4db449 (patch)
treeffc11f05faa59656cfce3c73389da841a8e7eafc
parent118c058d8b85e2d55dec73952d699b1a93be8733 (diff)
downloadopus-a0121298086718502d4597b86cab4eeeac4db449.tar.gz
Re-tuning compute_equiv_rate()
-rw-r--r--src/opus_encoder.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/opus_encoder.c b/src/opus_encoder.c
index 3aed38ca..7626ff8e 100644
--- a/src/opus_encoder.c
+++ b/src/opus_encoder.c
@@ -998,14 +998,14 @@ static opus_int32 compute_equiv_rate(opus_int32 bitrate, int channels,
equiv -= (40*channels+20)*(frame_rate - 50);
/* CBR is about a 10% penalty for both SILK and CELT. */
if (!vbr)
- equiv = equiv*9/10;
- /* Complexity makes about 10% difference (from 0 to 10) in general. */
+ equiv -= equiv/12;
+ /* Complexity makes about 8% difference (from 0 to 10) in general. */
equiv = equiv * (90+complexity)/100;
if (mode == MODE_SILK_ONLY || mode == MODE_HYBRID)
{
- /* SILK complexity 0-3 uses the non-delayed-decision NSQ, which
+ /* SILK complexity 0-1 uses the non-delayed-decision NSQ, which
costs about 20%. */
- if (complexity<4)
+ if (complexity<2)
equiv = equiv*4/5;
} else if (mode == MODE_CELT_ONLY) {
/* CELT complexity 0-4 doesn't have the pitch filter, which costs