[opus] How frequently should Opus Control Parameters be modified?

Jean-Marc Valin jmvalin at jmvalin.ca
Mon May 12 23:58:42 PDT 2014


On 13/05/14 01:36 AM, Amit Chowdhary wrote:
> 1) Any suggestions on how often I should change the bit-rate and 
> expected packet loss, (maybe even lower the audio bandwidth if the 
> bit-rate available is below the sweet-spot for WB)?
> 
> 2) How is the codec's performance affected every time a control parameter 
> such as bit-rate or audio bandwidth is changed? 
> Would doing this every second or every five seconds be a good idea? 
> Or should this be done rarely?

Opus is designed such that all its parameters can be changed on a
frame-by-frame basis without causing transition artefacts. Whenever the
available bitrate changes, just update the bitrate you ask for. However,
it is *not* recommended to change the bandwidth manually, since the Opus
encoder already has code to automatically adjust the bandwidth based on
the bitrate available. In practice, the main parameters you may want to
change at run-time are the bit-rate and the expected percentage of
packet loss (and even for that one, a static value is usually fine if
you don't have a good estimate).

> 3) I would also like to know about complexity and what would be a good 
> value on mobile devices. In my understanding a high complexity will add 
> delay (latency) to the codec, will it have any other bad effect? 
> Will this delay be device dependent? I will test these values but getting 
> an estimate of a good value to use on mobile clients would be nice.

Changing the complexity only affects the amount of CPU required for
encoding. It does not change the delay of the codec unless the CPU is
really slow. Just go with whatever complexity you can afford in your
situation.

	Jean-Marc


More information about the opus mailing list