[Webkit-unassigned] [Bug 41605] Fixes to the gaussian blur algorithm

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Jul 12 11:51:08 PDT 2010


https://bugs.webkit.org/show_bug.cgi?id=41605





--- Comment #18 from Alejandro G. Castro <alex at igalia.com>  2010-07-12 11:51:08 PST ---
(In reply to comment #15)
> Created an attachment (id=61146)
 --> (https://bugs.webkit.org/attachment.cgi?id=61146) [details]
> Pixel results
> 
> Can you please take a careful look at it? Results with text seem a bit translated and partly more blurred than they should be.

I think the reason for the translation (it should happen in all the images) is the way we choose now the left and right parts in the kernel, before we just divide by two and substract, the problem with that is when kernel size is even, we were using 3 box blurs with a bigger right/down side, the effect is that the image is a little bit translated. For instance for kernelSize = 6 we did:

  1 2 3 4 5 6
        ^
        destination

Now we use:

 1 2 3 4 5 6
     ^

 1 2 3 4 5 6
       ^    

 1 2 3 4 5 6 7
       ^

Now the filter should be more centered, those are the steps pointed out in the svg standard. You can check it for instance with the blurred square in resource-invalidate-on-target-update.svg, without the patch the shadow down and right is darker (with std 2, if you increase to a number which gives you a odd kernel size it is more centered). Or if you use filter-on-filter-for-text.svg, change the deviation to 5 (gives an odd kernel size) and you could check how the text is translated. This is one of the reasons I had to fix this to make the tiling work.

Wrt more blurred text, probably you are talking about filter-on-filter-for-text.svg, the problem there is the deviation standard is 1, and the minimum for the algorithm is 2, so what I did was use 2 if the value is under 2. Not sure if this is the right thing to do (if you set 2 in the svg you can check the blur does not change). Any suggestions?

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list