Log in

View Full Version : Need for a lowpass video filter?


Dali Lama
30th July 2003, 23:12
Greetings,

I have found that the use of a lowpass filter is useful in some video types and wanted to know if there is interest to make a filter for AVISynth.

There is a nice one for AVIUtl and Cinema Craft Encoder has one too. I think that its common for sources to be filtered with a low pass filter and I am surprised that it hasn't been talked about here.

I also don't think that it would be too difficult to code this plugin, but I don't know really.

Throwing out an idea,

Dali

Richard Berg
31st July 2003, 04:48
I'm no DSP expert, and I don't want to rely solely on my Google skills; do you have any code or links?

Meanwhile, you can get a basic one with GeneralConvolution:
"1 1 1
1 1 1
1 1 1"

Laba
29th August 2003, 09:08
Originally posted by Richard Berg


Meanwhile, you can get a basic one with GeneralConvolution:
"1 1 1
1 1 1
1 1 1"

I got interested in the subject and did some preliminary testing with Matlab on a still image (JPEG, RGB). The GeneralConvolution is probably too heavy and the frequency response is quite limited. The test results can be found in here:

http://users.utu.fi/~latasu/2Dfilter.html

I used IFFT to get the coefficients into the GeneralConvolution.

I'll try to make some algorithm of the method. GeneralConvolution algorithm can be optimized, because in this method the coefficients have symmetry.

I'll get back to this next week.

Laba

sh0dan
29th August 2003, 12:12
Many (spatial) filters are some sort of lowpass filter. VagueDenoiser is probably the most obvious Lowpass filter. Reduceby2()/Resize back could also be considered a lowpass filter.

Kurosu
29th August 2003, 12:57
Originally posted by sh0dan
VagueDenoiser is probably the most obvious Lowpass filter.
Wrong.
Vaguedenoiser filters _any_ coefficient (on every scale/level representation) solely on its value, not its position. Lowpass would be filtering the last level coefficients (see the new debug mode to see what I mean). Particular uses of spatialsoften and DCTfilter give a closer example. Their concept is a bit different:
- lowpass filter assumes the higher the frequencies in a signal, the more the coefficients are mainly due to noise. They don't try to filter lower frequencies
- waveshrinking assume something like a white noise and a general noise level: any coefficient under a threshold is most probably noise. That they are mostly in the higher frequencies is just a cause of the way natural signals are constitued and how they are acquired (CCDs/Analog-to-Digital Converters most often act as lowpass filters). For instance, in a computer generated image, there are a lot more frequencies, and MPEG encoders have a bad time when using default quantization matrices on them.

btw, you can see the spatial part of mipsmooth as behaving close to a wavelet filter with one level (nstep=1).