[Webkit-unassigned] [Bug 51309] Share blur code between FEGaussianBlur and ContextShadow

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Dec 20 10:24:27 PST 2010


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





--- Comment #4 from Simon Fraser (smfr) <simon.fraser at apple.com>  2010-12-20 10:24:27 PST ---
(In reply to comment #3)
> (In reply to comment #2)
> > Must the alpha-only blur not touch the other channels?
> No, for source alpha the image is filled with solid black. Just the alpha channel differs.
> 
> > 
> > Even if we don't share code, it would be good to have all the blurring code in the same file.
> All FE*-files (as well as FEGaussianBlur) need FILTERs enabled, while ContextShadow doesn't. So if you want to share code, FEGaussianBlur needs access to ContextShadow for alpha blurring.

Another approach would be to just put the blurring methods into their own file.

> Does ContextShadow clear all other channels afterwards, or are they still filled with the temporary data of the blurring?

It does not clear them.

> I guess it doesn't clear the data, so it would be necessary to use a composite operator afterwards (source-in?), and I'm not sure if all platforms support accessing the GraphicsContext after a pixel manipulation on the ImageBuffer (Cairo does, and the others?).

CG, at least, is fine using source-in composting to just extract the alpha channel.

> So we either need a second round for filling all channels other than alpha with zero, or need a second temp imageBuffer to make the compositing.

I'm fine with keeping FEGaussianBlur's alpha-only blur in a separate function from the more optimized shadow blur. I just want them all in the same place, so that any optimizations that are made (e.g. use of vImage) are more likely do be done on all of them.

-- 
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