[CELT-dev] opus sampling rates

Gregory Maxwell gmaxwell at gmail.com
Thu May 12 13:15:34 PDT 2011

On Thu, May 12, 2011 at 3:36 PM,  <bryandonnovan at gmail.com> wrote:
> I hope it is OK to ask an Opus question here.  If not, please advise the
> correct forum.
> Regarding the statement "Internally, the codec always operates at a 48
> kHz sampling rate, though it
> allows input and output of various bandwidths..."
> Can I infer from this that it is most CPU efficient to always input and
> output PCM data at 48000 samples per sec, regardless of other factors such
> as bitrate?
> My use of Opus is for an interactive app, so I want to set capture and
> playback sampling rates appropriately and avoid resampling inside the codec
> to the extent possible.  Opus is operating on 20 msec mono frames, set for
> OPUS_MODE_AUTO / OPUS_BANDWIDTH_AUTO, with a bit rate that varies between
> 10kbps - 64kbps.

Using 48kHz is correct and best.  At very low rates the codec will
effectively be resampling internally but thats internal sausage-making
that you shouldn't worry about. It's not inefficient, and because it
works this way you'll be able to switch to full bandpass quality
when you have the channel capacity available.

More information about the celt-dev mailing list