[opus] running at 44.1K but with standard frame sizes
Jean-Marc Valin
jmvalin at jmvalin.ca
Sat Jun 15 09:20:49 PDT 2013
On 06/15/2013 12:00 PM, Marc Lindahl wrote:
>> Do not do that, ever. Everything is calibrated for 48 kHz and you
>> will likely cause audible noise.
>
> How would it cause audible noise, I don't understand that part?
> After all the frequency calculations are off by 8%, that's not too
> extreme...
Well, the encoder is designed to follow the ear's response and shifting
everything by 8% will be sub-optimal. It'll still work, but you'll need
a higher bitrate to achieve the same quality.
>> Besides, running at the wrong rates means you lose all
>> compatibility anyway, so you might as well use the custom modes.
>
> Except, based on Ben's previous comments, possibly the quality isn't
> as good?
The quality of custom modes may not be nearly as good as the standard
case, but better than using 44.1 kHz and pretending it's 48 kHz.
> That's interesting… there isn't anything in the compression
> (estimators, etc.) or FEC that really 'likes' multiples of 120
> samples?
We use multiples of 120 at 48 kHz because it matches common frame sizes
(10 ms, 20 ms, ...) that people use in VoIP. There's nothing special
about these values otherwise.
>> There is no "stock frame size" with Opus custom. Modes are
>> generated on the fly (or you can always pre-generate them) with any
>> frame size. The frame size is that it can't have prime factors
>> above 5, but that's about the only constraint.
>
> What I meant was, 120, 240, 480, 960, 1920, or 2880 samples, the
> sizes imposed in the normal mode.
Well, if you're not running at 48 kHz, there's no point in using these
non-power-of-two sizes (i.e. it doesn't give you 20 ms anyway).
> So I still wonder, if you set up a custom mode, but then had all the
> settings the same as a normal mode, would the codec perform worse, or
> the same?
You'll have to try normal vs custom modes and choose. The only thing I'm
telling you is don't run a 48 kHz encoder at 44.1 kHz.
Cheers,
Jean-Marc
More information about the opus
mailing list