Subject: Re: [codec] I-D Action:draft-ietf-codec-opus-05.txt

From: Keith Yan <[email-masked]>
Date: Mon, 18 Apr 2011 17:33:41 +0800

Hi Jean-Marc,
I just test V0.9.3 code of DTX feature. The test result shows that DTX works abnormally when input frame size is 40ms, but it works fine if input frame is 20ms. 
Can you help to have a look on it.

Thanks
Keith

-----Original Message-----
From: Keith Yan 
Sent: 2011年3月16日 11:33
To: 'Jean-Marc Valin'; [email-masked]
Subject: RE: [codec] I-D Action:draft-ietf-codec-opus-05.txt

Dear Jean-Marc,
I have tested V0.9.2 code, and find if enable DTX, it will return from range checking, error code is Error: Range coder state mismatch between encoder and decoder.
And if not define OPUS_TEST_RANGE_CODER_STATE, the decoded file has sharp noise in the silence area. The left channel of test.wav is origin voice, and the right channel is encode/decode with DTX enabled.

Please check it.

Thanks
Keith

-----Original Message-----
From: Jean-Marc Valin [mailto:[email-masked]]
Sent: 2011年3月15日 13:16
To: [email-masked]
Subject: Re: [codec] I-D Action:draft-ietf-codec-opus-05.txt

Hi,

Just to let you know that the main change in that latest version is the ability to decode multi-frame packets. That code has received very little testing, so don't be surprised if it breaks. However, I did some amount of testing to at least make sure that random inputs do not cause buffer overruns and similar security issues.

Cheers,

	Jean-Marc

On 11-03-14 06:15 PM, [email-masked] wrote:
> A New Internet-Draft is available from the on-line Internet-Drafts directories.
> This draft is a work item of the Internet Wideband Audio Codec Working Group of the IETF.
>
>
> 	Title           : Definition of the Opus Audio Codec
> 	Author(s)       : J. Valin, K. Vos
> 	Filename        : draft-ietf-codec-opus-05.txt
> 	Pages           : 199
> 	Date            : 2011-03-14
>
> This document describes the Opus codec, designed for interactive 
> speech and audio transmission over the Internet.
>
> A URL for this Internet-Draft is:
> http://www.ietf.org/internet-drafts/draft-ietf-codec-opus-05.txt
>
> Internet-Drafts are also available by anonymous FTP at:
> ftp://ftp.ietf.org/internet-drafts/
>
> Below is the data which will enable a MIME compliant mail reader 
> implementation to automatically retrieve the ASCII version of the 
> Internet-Draft.
>
>
>
> _______________________________________________
> codec mailing list
> [email-masked]
> https://www.ietf.org/mailman/listinfo/codec

---

From: Koen Vos <[email-masked]>
Date: Mon, 18 Apr 2011 11:37:57 +0200 (CEST)

Hi Keith,

Thanks for the report.  It's a known bug in 0.9.3 (and it also exists with 60 ms).  I've fixed it locally, which will be included in the upcoming version that also adds stereo Voice mode.

best,
koen.

----- Original Message -----
From: "Keith Yan" <[email-masked]>
To: "Jean-Marc Valin" <[email-masked]>, [email-masked]
Sent: Monday, April 18, 2011 2:33:41 AM
Subject: Re: [codec] I-D Action:draft-ietf-codec-opus-05.txt

Hi Jean-Marc,

Thanks
Keith

-----Original Message-----
From: Keith Yan 
Sent: 2011年3月16日 11:33
To: 'Jean-Marc Valin'; [email-masked]
Subject: RE: [codec] I-D Action:draft-ietf-codec-opus-05.txt

Dear Jean-Marc,

Please check it.

Thanks
Keith

-----Original Message-----
From: Jean-Marc Valin [mailto:[email-masked]]
Sent: 2011年3月15日 13:16
To: [email-masked]
Subject: Re: [codec] I-D Action:draft-ietf-codec-opus-05.txt

Hi,

Cheers,

	Jean-Marc

---

From: Keith Yan <[email-masked]>
Date: Mon, 18 Apr 2011 17:57:12 +0800

Hi Koen,
Also I find that if call OPUS_SET_BANDWIDTH frequency during doing encode, encoder will enter into a while operation, and can't callback in function
static void ec_enc_normalize(ec_enc *_this){
  /*If the range is too small, output some bits and rescale it.*/
  while(_this->rng<=EC_CODE_BOT){
    ec_enc_carry_out(_this,(int)(_this->val>>EC_CODE_SHIFT));
    /*Move the next-to-high-order symbol into the high-order position.*/
    _this->val=_this->val<<EC_SYM_BITS&EC_CODE_TOP-1;
    _this->rng<<=EC_SYM_BITS;
    _this->nbits_total+=EC_SYM_BITS;
  }
}
And variable _this->rng is zero. After analyze, we think it's caused that internal sample rate is changed, but it doesn't update to encoder controller.

We find pitch_high_bits is not right after changed max internal sample rate. It will bigger than 32.
        if( encode_absolute_lagIndex ) {
            /* Absolute encoding */
            SKP_int32 pitch_high_bits, pitch_low_bits;
            pitch_high_bits = SKP_DIV32_16( psIndices->lagIndex, SKP_RSHIFT( psEncC->fs_kHz, 1 ) );
            pitch_low_bits = psIndices->lagIndex - SKP_SMULBB( pitch_high_bits, SKP_RSHIFT( psEncC->fs_kHz, 1 ) );
            SKP_assert( pitch_low_bits < psEncC->fs_kHz / 2 );
            SKP_assert( pitch_high_bits < 32 );
            ec_enc_icdf( psRangeEnc, pitch_high_bits, SKP_Silk_pitch_lag_iCDF, 8 );
            ec_enc_icdf( psRangeEnc, pitch_low_bits, psEncC->pitch_lag_low_bits_iCDF, 8 );
        }

Thanks
Keith

-----Original Message-----
From: Koen Vos [mailto:[email-masked]] 
Sent: 2011年4月18日 17:38
To: Keith Yan
Cc: Jean-Marc Valin; [email-masked]
Subject: Re: [codec] I-D Action:draft-ietf-codec-opus-05.txt

Hi Keith,

best,
koen.

----- Original Message -----
From: "Keith Yan" <[email-masked]>
To: "Jean-Marc Valin" <[email-masked]>, [email-masked]
Sent: Monday, April 18, 2011 2:33:41 AM
Subject: Re: [codec] I-D Action:draft-ietf-codec-opus-05.txt

Hi Jean-Marc,

Thanks
Keith

-----Original Message-----
From: Keith Yan 
Sent: 2011年3月16日 11:33
To: 'Jean-Marc Valin'; [email-masked]
Subject: RE: [codec] I-D Action:draft-ietf-codec-opus-05.txt

Dear Jean-Marc,

Please check it.

Thanks
Keith

-----Original Message-----
From: Jean-Marc Valin [mailto:[email-masked]]
Sent: 2011年3月15日 13:16
To: [email-masked]
Subject: Re: [codec] I-D Action:draft-ietf-codec-opus-05.txt

Hi,

Cheers,

	Jean-Marc

---

From: Koen Vos <[email-masked]>
Date: Mon, 18 Apr 2011 12:18:37 +0200 (CEST)

Thanks Keith,
I'll take a look at that.
best,
koen.

----- Original Message -----
From: "Keith Yan" <[email-masked]>
To: "Koen Vos" <[email-masked]>
Cc: "Jean-Marc Valin" <[email-masked]>, [email-masked]
Sent: Monday, April 18, 2011 2:57:12 AM
Subject: RE: [codec] I-D Action:draft-ietf-codec-opus-05.txt

Hi Koen,

Thanks
Keith

-----Original Message-----
From: Koen Vos [mailto:[email-masked]] 
Sent: 2011年4月18日 17:38
To: Keith Yan
Cc: Jean-Marc Valin; [email-masked]
Subject: Re: [codec] I-D Action:draft-ietf-codec-opus-05.txt

Hi Keith,

best,
koen.

----- Original Message -----
From: "Keith Yan" <[email-masked]>
To: "Jean-Marc Valin" <[email-masked]>, [email-masked]
Sent: Monday, April 18, 2011 2:33:41 AM
Subject: Re: [codec] I-D Action:draft-ietf-codec-opus-05.txt

Hi Jean-Marc,

Thanks
Keith

-----Original Message-----
From: Keith Yan 
Sent: 2011年3月16日 11:33
To: 'Jean-Marc Valin'; [email-masked]
Subject: RE: [codec] I-D Action:draft-ietf-codec-opus-05.txt

Dear Jean-Marc,

Please check it.

Thanks
Keith

-----Original Message-----
From: Jean-Marc Valin [mailto:[email-masked]]
Sent: 2011年3月15日 13:16
To: [email-masked]
Subject: Re: [codec] I-D Action:draft-ietf-codec-opus-05.txt

Hi,

Cheers,

	Jean-Marc