Chris@25: Chris@25: Decimation Chris@25: ========== Chris@25: Chris@25: The aim of this little project is to compare a few different methods Chris@25: of signal decimation for relative speed and quality. "Decimation" Chris@27: refers here to downsampling a signal by a power-of-two factor. Chris@25: Chris@25: The principle is to use a low-pass filter to reduce the bandwidth of Chris@25: the signal to below the Nyquist frequency at the target sample rate Chris@25: (i.e. with the maximum frequency content being below the original rate Chris@25: divided by twice N, for a decimation factor N) and then to pick every Chris@25: Nth sample. Chris@25: Chris@25: This is simple enough, but we have a few different implementations Chris@25: available with different quality and performance tradeoffs. Here we Chris@25: compare: Chris@25: Chris@25: * "decimate": the Decimator implementation in the qm-dsp library, Chris@25: which uses an 8-tap IIR lowpass filter; Chris@25: Chris@25: * "resample_hq", "resample_mq", "resample_lq": the Resampler Chris@25: implementation in the qm-dsp library, which uses a lengthy Chris@25: Kaiser-windowed sinc filter, at three different quality settings; Chris@25: Chris@25: * "src": the sndfile-resample program which uses libsamplerate, a Chris@25: well trusted resampler also using a Kaiser-windowed sinc Chris@25: implementation, at its default quality setting; Chris@25: Chris@25: * "zoh": the sndfile-resample zero-order hold resampler, which just Chris@25: takes every Nth sample without any filtering, serving as a Chris@25: baseline. Chris@25: Chris@25: Run "make" (caution: only tested on Linux with GNU make and bash) to Chris@25: build and run the tests. Chris@25: Chris@25: Author: Chris Cannam (cannam@all-day-breakfast.com) Chris@25: