Open
Bug 535412
Opened 16 years ago
Updated 3 years ago
Figure out how to do blur in hardware
Categories
(Core :: Graphics, defect)
Tracking
()
NEW
People
(Reporter: jrmuizel, Unassigned)
Details
We need to figure out whether we want to do blur/shadow at the cairo level or at the layers level. I'm sort of leaning toward the layer level as that will give us more flexibility and avoids adding api.
However, I wonder if doing things in cairo will let us be more efficient...
Also, quartz does support native shadow drawing, though I'm not sure we want to use that.
Thoughts anyone?
I was thinking about this this morning.
There can be a lot of shadows. E.g. if you have a lot of text with a blur-shadow of small radius, I don't think you want to do it all in hardware with a lot of layers.
I think the approach we have right now where we render a mask to an image surface and then blur it on the CPU is quite good and we can make it a lot better, per https://bugzilla.mozilla.org/show_bug.cgi?id=509052#c3. Another thing I realized is that for small radii, we should probably just apply an explicit Gaussian kernel instead of the 6-pass (3 horizontal, 3 vertical) box-blur that we currently do. I'd like to push on those optimizations before we switch over to hardware.
Hrm, I would actually prefer to do this in hardware, but maybe we just want both. A lot of text with blur-shadow of small radius I would think would be exactly what you want in hardware -- it's not a lot of layers, it's just one layer, right?
No, it's a lot of layers, because according to CSS the shadow gets painted directly under each text node. If the shadow overlaps adjacent text nodes (common), you're stuck with <shadow1> <text1> <shadow2> <text2> ...
Updated•3 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•