[pulseaudio-discuss] GSoC Proposal: Resampling Improvements
Damir Jelić
poljarinho at gmail.com
Sat Apr 27 04:44:55 PDT 2013
On Mon, Apr 22, 2013 at 06:33:08PM +0200, Peter Meerwald wrote:
> Hello,
>
> > > > > > By "libresample", I guess you mean "libsamplerate". Peter can correct me
> > > > > > if I'm intepreting him wrong, but my understanding is that libsamplerate
> > > > > > was only mentioned as an example of a resampler with a problematic
> > > > > > license. I don't know either what should be done about it - perhaps the
> > > > > > idea was to compare the different resamplers, and if it turns out that
> > > > > > we don't have any good reason to keep using libsamplerate, we could drop
> > > > > > that code.
>
> > > libsamplerate was mentioned because of the GPL license;
> > > to work around, a loadable module interface could be offered, so the user
> > > can decide
>
> > This sounds like a lot of complexity for little gain. What is wrong with
> > compile time switches/options?
>
> maybe yes; depends on how many resamplers there will be
>
> a loadable module interface enforces a stricter and more stable interface,
> which may be a good thing
>
> some refactoring is in place anyway, so depends how far we want to take it
>
So I checked this out a little bit and I think I could also add this to
my proposal.
Here is what I came up with:
- make the pa_resampler structure implementation agnostic
- replace the static resampling method table with a hashmap or
idxset
- move the resampler methods to modules and let them register
themself inside with the core
How does that sound to you?
What do the other devs think about this?
> > > > > > > Speex has been obsoleted [2] and the resampler seems to had been moved to
> > > > > > > opus-tools. There are some interesting commits [3] inside this repo and I think
> > > > > > > it would be nice to update our speex resample method although I'm not sure
> > > > > > > if it's ok to drop speex and replace it with opus-tools just like that.
> > >
> > > > > > To me replacing the speex resampler with the opus-tools resampler sounds
> > > > > > like an obvious thing to do, if the upstream says that the speex
> > > > > > resampler code is deprecated in favour of opus-tools.
>
> > By the way is there some explicit reason you have chosen libav for this
> > project?
> > FFmpeg now also has a resampling library [1] and I found an interesting
> > blog post about "ffmpeg vs libav" [2].
>
> ffmpeg vs. libav is a mess, but I think the dust has settled a little by
> now
>
> my impression is that ffmpeg merged libav stuff, but not vice-versa; so
> there is libswresample and libavresample in ffmpeg, libavresample coming
> from libav
>
> > Maybe we should support both so different distributions can choose what
> > to use depending on the default lib they are using.
>
> libavresample can be provided by ffmpeg and libav; not sure if
> libswresample should be supported
According to this [1] libswresample should perform better or on par
libavresample, and if it doesn't we can complain.
Supporting both shouldn't be hard anyways and does no harm that I'm
aware of.
[1] http://ffmpeg.org/pipermail/ffmpeg-devel/2012-April/123746.html
More information about the pulseaudio-discuss
mailing list