Closed Bug 1388235 Opened 8 years ago Closed 8 years ago

Support fallback path for nsDisplayFilter.

Categories

(Core :: Graphics: WebRender, enhancement)

enhancement
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla57
Tracking Status
firefox57 --- fixed

People

(Reporter: mtseng, Assigned: mtseng)

References

Details

Attachments

(1 file)

In bug 1386188, we add support for nsDisplayFilter. Since webrender doesn't support all filter effects, we need some fallback mechanism for unsupport effects. Because nsDisplayFilter is container type displayitem and fallback for container type displayitem is not trivial. Per discussion with Ethan, we have following proposals: 1. Reuse FrameLayerBuilder and BasicLayerManager. This might be simplest solution. 2. Implement a custom fallback mechanism for layers-free mode. This has some problem because nsDisplayFilter is a container type display item which means it would container all kind of display item in it. So we need implement a general fallback mechanism for all display item types. 3. Record filter's moz2d command and replay it on webrender. We don't know this is doable or not. But just like blob image, we record commands and send it to webrender. Webrender readback the buffer which need apply filter then replay the commands on this buffer. 4. Fully support css/svg filter in webrender Once this is done, we don't need fallback path for filter. Kats, Jeff, Do you have any suggestions for above proposals?
Flags: needinfo?(jmuizelaar)
Flags: needinfo?(bugmail)
I don't really have any suggestions. I think long-term we want to go with (4), correct? If that's the case and that's hard to do in the short-term then I think (1) might be the best way to go as it's simple. But I don't really know.
Flags: needinfo?(bugmail)
Thoughts: 1. Reuse FrameLayerBuilder and BasicLayerManager. - This isn't my favourite but indeed probably the quickest way to a correct solution. I think it's probably worth pursuing this first to see if it can easily become workable. 2. I think this could be workable, but it's harder to know how much work it will be. I think this could end up better and simpler than 1. We should still probably try 1 first though. 3. I don't really want to try this. 4. This would of course be best, but I like the comfort of being able to fallback to something we know works. In summary: I think we should go for 1. to start. Let's see how it turns out and then evaluate whether it makes sense.
Flags: needinfo?(jmuizelaar)
I agree with Jeff's assessment.
Assignee: nobody → mtseng
Attachment #8897689 - Flags: review?(jmuizelaar) → review+
Pushed by mtseng@mozilla.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/ee2d23448326 Support fallback path for nsDisplayFilter. r=jrmuizel
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla57
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: