[Spice-devel] [PATCH] make celt to be optional

Gerd Hoffmann kraxel at redhat.com
Wed Jun 13 23:55:59 PDT 2012


  Hi,

>> I suspect there is no way around resampling support though.  We'll need
>> it for compatibility reasons, so sound keeps working if only one side is
>> able to operate at 48 kHz.
> 
> The ability to resample OTOH probably isn't a silly thing to have, and
> can be fairly easily set up as an inline filter that is switched out
> if you really don't need it.
> 
> Just to be clear about this though, there is actually no reason that
> both sides of the link need to use the *same* sample rate, even without
> a resampler.
> 
> For instance you can perfectly well push an 8kHz stream into opus, and
> decode that as a 48kHz stream at the other end, or vice versa, without
> resampling, for any integer fraction of 48k down to 8.  Or just because
> one end needs to resample from 44.1 to 48, it doesn't prevent the other
> side from still natively using 48k etc.

Ah, ok, so opus is different from mp3 here.  So you could "reample"
using opus?  i.e. have one side feed 44.1 into opus encoder, then send
opus over the wire, have the other side decode 48 kHz from opus?

Is that true for celt 0.5.1 too btw?

> So this isn't something you strictly need to coordinate between endpoints
> unless they have their own requirements to do that.  The common thing
> they negotiate is "we both speak opus", while the sample rate they see
> at their own ends can be entirely up to them to decide, without needing
> to agree on a common rate, or to share information about the rate that
> they chose.
> 
> Once encoded in opus, there is no "sample rate" anymore, except what you
> choose to decode it as, at the time you choose to decode it.
> 
> Does that make sense, or did I just make this sound even more confusing
> than it really is ;?

Makes perfect sense.

thanks,
  Gerd


More information about the Spice-devel mailing list