Log in

View Full Version : what Blur() settings correspond to what convolution matrices?


Katie Boundary
3rd April 2024, 05:03
We know Blur (1.0) is equivalent to

1 2 1
2 4 2
1 2 1

But other than that...?

Julek
3rd April 2024, 05:35
Blur uses the kernel [(1−1/2^amount)/2, 1/2^amount, (1−1/2^amount)/2]. The largest allowable argument for Blur is log2(3) (which is about 1.58), which corresponds to a (1/3,1/3,1/3) kernel. A value of 1.0 gets you a (1/4,1/2,1/4) kernel for example. Likewise Blur(1.0).Blur(1.0) is a convolution of the kernel (1/4,1/2,1/4) with itself, being a (1/4,1/2,1/4)*(1/4,1/2,1/4) = (1/16,4/16,6/16,4/16,1/16) kernel. It can be read of Pascal's triangle.
https://avisynthplus.readthedocs.io/en/latest/avisynthdoc/corefilters/blur.html

Katie Boundary
6th April 2024, 13:11
https://avisynthplus.readthedocs.io/en/latest/avisynthdoc/corefilters/blur.html

Okay but can anyone translate that into English?

EDIT: I think I've deciphered it.

A blur(0.5) in one direction will yield a kernel of roughly (37.5, 181, 37.5)

A blur(0.5) in two directions will yield... uh...

(5.5, 26.5, 5.5,
26.5, 128, 26.5,
5.5, 26.5, 5.5)

Katie Boundary
7th April 2024, 01:22
Blur(0.19265) along one dimension should yield exactly: (16, 224, 16)

Along two dimensions:

(1, 14, 1,
14, 196, 14,
1, 14, 1)