[Spice-devel] RFC on sound codec refactoring
Gerd Hoffmann
kraxel at redhat.com
Mon Oct 7 12:26:50 CEST 2013
On Mo, 2013-10-07 at 05:35 -0400, Marc-André Lureau wrote:
>
> ----- Original Message -----
> > On Fri, Oct 04, 2013 at 01:16:24PM -0500, Jeremy White wrote:
> > > Yes, he pointed out some issues back in August when this last came up
> > > (primarily supporting 'old' clients if you're sampling at 48K). That's
> > > the bit I'm not entirely clear on just yet, and hope to research a bit
> > > further.
> >
> > I'll look at your patches in more details later, but moving code out of
> > snd_channel.c sounds interesting ;)
> > Quick answer regarding the resampling, Opus wants to get 48kHz audio data,
> > so when using Opus, you've got to tell QEMU to give you that. If you are
> > talking to a client with Opus support, then it's all good, you encode to
> > Opus and that's it. If you are talking to a client without Opus support,
> > then you have to fallback to celt, which expects 44.1kHz input (at least,
> > if I'm not mistaken, and the way we use it in spice). You can't dynamically
> > tell QEMU that you no longer want 48kHz but that you want 44.1kHz instead,
>
> Instead of having to resample, can't we fix qemu (and spice headers) to use 48khz by default?
Sure we can switch the default. spice headers is enougth btw. Just
update the frequency there. And bumb the minor version so spice-server
can figure which frequency is used by qemu.
You can still face the case that spice-server has to handle a old
(not-yet rebuilt against new spice-headers) qemu binary which operates
at 44.1 kHz. So the 44.1 -> 48 resampling will be needed, even when is
used for a (hopefully short) transition period only.
cheers,
Gerd
More information about the Spice-devel
mailing list