aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-11-28 20:48:02 +0100
committerMax Kellermann <max@duempel.org>2013-11-28 20:48:02 +0100
commite504913b0f118ddaa8e14ae9f8325c3dd5a339a6 (patch)
treeaa6d11231eb7236c217251e1d01642f940ff52a0
parentaf4133e3c92c78cc19ff14b876be6afcab1db091 (diff)
downloadmpd-e504913b0f118ddaa8e14ae9f8325c3dd5a339a6.tar.gz
mpd-e504913b0f118ddaa8e14ae9f8325c3dd5a339a6.tar.xz
mpd-e504913b0f118ddaa8e14ae9f8325c3dd5a339a6.zip
pcm: drop compatibility with libsamplerate older than 0.1.3
Remove compatibility code.
-rw-r--r--configure.ac10
-rw-r--r--src/pcm/PcmResampleLibsamplerate.cxx20
2 files changed, 1 insertions, 29 deletions
diff --git a/configure.ac b/configure.ac
index f7624a0f4..4ba2b2d3b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -748,20 +748,12 @@ dnl Converter Plugins
dnl ---------------------------------------------------------------------------
dnl ------------------------------ libsamplerate ------------------------------
-MPD_AUTO_PKG(lsr, SAMPLERATE, [samplerate >= 0.0.15],
+MPD_AUTO_PKG(lsr, SAMPLERATE, [samplerate >= 0.1.3],
[libsamplerate resampling], [libsamplerate not found])
if test x$enable_lsr = xyes; then
AC_DEFINE([HAVE_LIBSAMPLERATE], 1,
[Define to enable libsamplerate])
fi
-
-if test x$enable_lsr = xyes; then
- PKG_CHECK_MODULES([SAMPLERATE_013],
- [samplerate >= 0.1.3],,
- [AC_DEFINE([HAVE_LIBSAMPLERATE_NOINT], 1,
- [libsamplerate doesn't provide src_int_to_float_array() (<0.1.3)])])
-fi
-
AM_CONDITIONAL(HAVE_LIBSAMPLERATE, test x$enable_lsr = xyes)
dnl ---------------------------------------------------------------------------
diff --git a/src/pcm/PcmResampleLibsamplerate.cxx b/src/pcm/PcmResampleLibsamplerate.cxx
index 9eac2d545..e61ff2edf 100644
--- a/src/pcm/PcmResampleLibsamplerate.cxx
+++ b/src/pcm/PcmResampleLibsamplerate.cxx
@@ -225,26 +225,6 @@ pcm_resample_lsr_16(PcmResampler *state,
return dest_buffer;
}
-#ifdef HAVE_LIBSAMPLERATE_NOINT
-
-/* libsamplerate introduced these functions in v0.1.3 */
-
-static void
-src_int_to_float_array(const int *in, float *out, int len)
-{
- while (len-- > 0)
- *out++ = *in++ / (float)(1 << (24 - 1));
-}
-
-static void
-src_float_to_int_array (const float *in, int *out, int len)
-{
- while (len-- > 0)
- *out++ = *in++ * (float)(1 << (24 - 1));
-}
-
-#endif
-
const int32_t *
pcm_resample_lsr_32(PcmResampler *state,
unsigned channels,