Page 1 of 1

Ugly Resampling

Posted: 14 Jun 2011 20:47
by aCOSwt
Hello,

Running vlc 1.1.10 under Gentoo (Audio output to Jack)

My ears were telling me that the resampling under vlc was... ugly ! :cry:

I need resampling mainly in order to cope with my Jack's occurrence sampling rate.

And... it is actually ugly :

Code: Select all

main debug: input 's16l' 44100 Hz Stereo frame=1 samples/4 bytes main debug: filter(s) 's16l'->'f32l' 44100 Hz->44100 Hz Stereo->Stereo main debug: looking for audio filter module: 13 candidates audio_format debug: s16l->f32l, bits per sample: 16->32 main debug: using audio filter module "audio_format" main debug: TIMER module_need() : 0.067 ms - Total 0.067 ms / 1 intvls (Avg 0.067 ms) main debug: found a filter for the whole conversion main debug: filter(s) 'f32l'->'f32l' 52800 Hz->48000 Hz Stereo->Stereo main debug: looking for audio filter module: 13 candidates main debug: using audio filter module "ugly_resampler"
This despite I checked the High-Quality resampling box as part of the audio preferences. :?

What did I miss (or messed-up) :cry:

BTW, where does the 52800 Hz (from the preceding code snippet) come from ? :?

Re: Ugly Resampling

Posted: 14 Jun 2011 21:53
by Rémi Denis-Courmont
52800 is just a hack/artifact of the VLC audio core to find a resampling filter. Ignore it.

There were four resamplers in VLC until recently:
- The band-limited resampler was disabled because it is buggy.
- The ugly resampler (copy or drop samples) is what you have.
- The linear resampler was removed because it sounded worse than the ugly resampler, while being more computationally intensive.
- The trivial resampler was removed because it was really not a resampler in the first place (crop).
So currently, there is only the ugly one.

Re: Ugly Resampling

Posted: 14 Jun 2011 22:28
by aCOSwt
So currently, there is only the ugly one.
:cry:
Thank you Rémi for answering.
Well... would have preferred I had not correctly configured...
Do the devs need help in implementing some secret-rabbit-code or has resampling been thrown out of the project scope for a while ?

Re: Ugly Resampling

Posted: 15 Jun 2011 09:12
by Rémi Denis-Courmont
Yeah, someone needs to either:
- fix the band-limited resampler, or
- write a better resampler from scratch.

Resampling is absolutely in the scope of the project, since VLC cannot work without one. But the existing developers are overwhelmed so they cannot take care of it.

Re: Ugly Resampling

Posted: 09 Aug 2011 19:52
by Rémi Denis-Courmont
VLC 1.2-git supports libsamplerate, including low-noise sinc-based resampling as of today.

Re: Ugly Resampling

Posted: 09 Aug 2011 20:04
by Jean-Baptiste Kempf
VLC 1.2-git supports libsamplerate, including low-noise sinc-based resampling as of today.
Yeah!