WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED WORKSFORME
53658
FEGaussianBlur kernel size is slightly wrong
https://bugs.webkit.org/show_bug.cgi?id=53658
Summary
FEGaussianBlur kernel size is slightly wrong
Simon Fraser (smfr)
Reported
2011-02-02 20:41:44 PST
The spec <
http://www.w3.org/TR/SVG/filters.html#feGaussianBlurElement
> says: if d is odd, use three box-blurs of size 'd', centered on the output pixel. ... if d is even, two box-blurs of size 'd' (the first one centered on the pixel boundary between the output pixel and the one to the left, the second one centered on the pixel boundary between the output pixel and the one to the right) and one box blur of size 'd+1' centered on the output pixel. The kernelPosition() gets this wrong, since it it fails to subtract the center pixel for at least the (std % 2) case.
Attachments
Add attachment
proposed patch, testcase, etc.
Simon Fraser (smfr)
Comment 1
2011-02-02 20:42:33 PST
For example with std==47, all three blurs should use dLeft = dRight = 23. Right now they use 23,24.
Dirk Schulze
Comment 2
2011-02-03 02:05:55 PST
(In reply to
comment #1
)
> For example with std==47, all three blurs should use dLeft = dRight = 23. Right now they use 23,24.
This means the even and the odd cases are wrong, since we dLeft + dRight should be std - 1. right? But IIRC, this gets balanced during the blurring, since we do not differ between the center point and the points next to this point. So, in a row, we just take 'std'-number of pixels into account. And that is what the spec means: dleft + center pixel + dRight - pixels. Can you check this please?
Dirk Schulze
Comment 3
2014-05-12 06:01:56 PDT
I think this was fixed a long time ago.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug