[gephex-user] Another new module: Infinite Impulse Response image
filter
binary millenium
binarymillenium at gmail.com
Mon Jan 15 04:48:11 CET 2007
Here's another filter that implements an IIR filter on input video:
http://bmillenium.sourceforge.net/zimagefiltermodule.zip
Source and windows dlls provided, I'll provide linux x86 libs for this and
the earlier modules soon.
The filter has two buffers of size four, one stores the current input image
and also buffers of the input image for three samples into the past and also
stores three copies of the output image for three samples into the past. 8
coefficients sum all these buffered images up into one combined new output
frame (which is then buffered for use in the next time step).
The general equation where y is the output image, x is the input image, and
xn is the current image and xn-1 the image from one timestep back is:
yn = (a0*xn + a1*xn-1 + a2*xn-2 + a3*xn-3 - b1*yn-1 - b2*yn-2 - b3*yn-3) /
b0
If you know a thing or two about filter design you can make custom low-pass,
high-pass, or band-pass filters.
It would be possible to extend the length of the buffers, but there's a
large performance hit just for the current size. The code is currently
fairly ugly and I probably didn't make it as efficient as it could be (it
unnecessarily buffers an extra output image that is unused for instance).
-bm
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.gephex.org/pipermail/gephex-user/attachments/20070114/9ffce34d/attachment.html
More information about the gephex-user
mailing list