Hello,

When trying out the new sox support in 0.19, I noticed the best recipe SOXR_VHQ sounds a little more harsh than what we used in the past, which was samplerate_converter "1" (medium sinc) in 0.18.X I could never get samplerate_converter "0" to work on power efficient atom/celeron hardware.

Sox is way more efficient than libsamplerate, so we started testing SOXR_LSR0Q which is sox's libsamplerate emulation for libsamplerate's "best sinc".

It actually sounded much better than the real libsamplerate's "Medium Sinc Interpolator", so I wrote a small patch to include these recipes.

example for a 24/96 .wav file upsampling to 705.6 kHz on a celeron 847, which my ifi dac supports:

samplerate_converter "soxr best sinc" consumes 20% cpu on one core
samplerate_converter "1 " consumes 95% cpu on one core

As the difference in sound quality between these two upsamplers is day and night in favor for sox, and the cpu load is only a fraction, please find my patch attached.

--
Best regards,

Frederic Vanden Poel

Klinkt Beter
www.klinktbeter.be
[email protected]

+32 473 79 36 91
Blauwe Paal 45
9230 Wetteren

--- SoxrResampler.cxx   2014-10-20 18:56:47.626263734 +0200
+++ SoxrResampler.cxx.new       2014-10-20 19:01:18.913522079 +0200
@@ -48,6 +48,12 @@
                return "Low Quality";
        case SOXR_QQ:
                return "Quick";
+       case SOXR_LSR0Q:
+               return "Libsamplerate equivalent Best sinc";
+       case SOXR_LSR1Q:
+               return "Libsamplerate equivalent Medium sinc";
+       case SOXR_LSR2Q:
+               return "Libsamplerate equivalent Fast sinc";
        }
 
        gcc_unreachable();
@@ -76,6 +82,12 @@
                soxr_quality_recipe = SOXR_LQ;
        else if (strcmp(quality, "quick") == 0)
                soxr_quality_recipe = SOXR_QQ;
+       else if (strcmp(quality, "best sinc") == 0)
+               soxr_quality_recipe = SOXR_LSR0Q;
+       else if (strcmp(quality, "medium sinc") == 0)
+               soxr_quality_recipe = SOXR_LSR1Q;
+       else if (strcmp(quality, "fast sinc") == 0)
+               soxr_quality_recipe = SOXR_LSR2Q;
        else
                return false;
 
_______________________________________________
mpd-devel mailing list
[email protected]
http://mailman.blarg.de/listinfo/mpd-devel

Reply via email to