[Speex-dev] fir_mem16,iir_mem16 and filter_mem16 optimisations

Jean-Marc Valin jean-marc.valin at usherbrooke.ca
Sat Aug 2 17:02:43 PDT 2008


> I still in doubt.
> You could tell in more detail about filter_mem16()? 
> I can't find comments in filter_mem2().
> I think, filter_mem16 is a IIR filter, and const spx_coef_t *num, const spx_coef_t *den is a input and output signal coefficients, but i am not sure... is it right?
> But there is only one coefficients array in iir_mem, and logic is not clear for me.
> I feel, fir_mem16() and iir_mem16() is a two parts of one IIR filter. fir_mem16 multiplies input signal, and iir_mem16 doing that with output...
> So, if we call fir_mem16() and then iir_mem16() with corresponding parameters it will be equivalent to filter_mem16()?
> 
> I'm sorry for a stupid questions, i am newbie in digital filtering.
> May be filter_mem2() will work better, but i am trying to understand approach.
> For me is interesting not only result in better performance of code, but i want to get some aducational effect.

OK, sorry I misunderstood your question. Basically, filter_mem16 is an
IIR filter with "num" as the numerator coefficients and "den" as the
denominator coefficients. iir_mem16() is a special case where there is
no numerator (just a 1) and fir_mem16() is the case with no denominator
(i.e. an FIR).

Note that in all cases, the initial 1 is omitted from num and den.
filter_mem2() is based on the same principle, except that it took 32-bit
inputs and outputs. It is no longer used and has been replaced by
filter_mem16().

	Jean-Marc


More information about the Speex-dev mailing list