shithub: opus

Download patch

ref: da97db1ca1f92592af3534c9a2596da0e9a009ca
parent: 648eb9adff253c1216a5430237cc8df30cce6751
author: Jean-Marc Valin <[email protected]>
date: Wed Sep 3 22:48:21 EDT 2014

Fixes comments

--- a/src/opus_multistream_encoder.c
+++ b/src/opus_multistream_encoder.c
@@ -860,10 +860,10 @@
          opus_encoder_ctl(enc, OPUS_SET_ENERGY_MASK(bandLogE));
       /* number of bytes left (+Toc) */
       curr_max = max_data_bytes - tot_size;
-      /* Reserve three bytes for the last stream and four for the others */
+      /* Reserve one byte for the last stream and two for the others */
       curr_max -= IMAX(0,2*(st->layout.nb_streams-s-1)-1);
       curr_max = IMIN(curr_max,MS_FRAME_TMP);
-      /* Repacketizer will add one byte for self-delimited frames */
+      /* Repacketizer will add one or two bytes for self-delimited frames */
       if (s != st->layout.nb_streams-1) curr_max -=  curr_max>253 ? 2 : 1;
       if (!vbr && s == st->layout.nb_streams-1)
          opus_encoder_ctl(enc, OPUS_SET_BITRATE(curr_max*(8*Fs/frame_size)));