Sunday, May 1, 2011

Does waveInXXX applies a lowpass filter?

When I use the (win32) waveInXXX functions in order to collect samples from a mic at a certain sampling frequency (say 8kHZ, even lower possibly), does the system/soundcard applies a lowpass filter on the input sample, or would i get aliasing? Should I sample at a higher frequency and do the filtering myself before lowering the sampling freq?

From stackoverflow
  • Interesting question. I don't know how you would find out the answer for sure (short of experimenting). I suspect that the actual sample rate of the recording might well be 44.1kHz (or 48kHz) and Windows would then do SRC, in which case a low-pass filter almost definitely would be applied. If the sound-card itself is sampling at 8kHz, one would hope that the hardware would perform the low pass filter beforehand.

    In short, don't bother implementing a low-pass filter unless you experience problems with aliasing artefacts.

    Bandi-T : I second that. Experiment with the OS environments and soundcards similar to what your software will be running on to see how often aliasing occurs. I would bet though that you would be hard pressed to find a computer sound setup in 2010 that results in aliasing.


Post a Comment