Summary: | compositing/webgl/webgl-nonpremultiplied-blend.html is flaky on Lion | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Dirk Pranke <dpranke> | ||||||
Component: | WebGL | Assignee: | Kenneth Russell <kbr> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Normal | CC: | cc-bugs, enne, jamesr, jbauman, kbr, mazda, nduca, senorblanco, twiz, vangelis, webkit.review.bot, zmo | ||||||
Priority: | P2 | ||||||||
Version: | 528+ (Nightly build) | ||||||||
Hardware: | Unspecified | ||||||||
OS: | Unspecified | ||||||||
Attachments: |
|
Description
Dirk Pranke
2012-03-27 18:43:46 PDT
Note that there is a separate bug 55968 filed for this failing on mac and win in debug mode ... From the flakiness dashboard results it looks to me like it's failing all the time rather than flaky. Needs investigation. important note about the flakiness dashboard: if we retry the test and it passes, *that does not show up in the dashboard* :). That's a whole separate, confusing issue that I'm working on w/ Ojan. Another bug was filed for Snow Leopard (https://bugs.webkit.org/show_bug.cgi?id=89998). This test started failing on Snow Leopard as well after http://trac.webkit.org/changeset/121267, so maybe this workaround (https://bugs.webkit.org/show_bug.cgi?id=79735) is causing this failure? I think I see the problem. Because of how the premultiplied blend function of (ONE, ONE_MINUS_SRC_ALPHA) works, the premultipliedAlpha=false case for compositing of WebGL canvases is generally the first time the compositor will output anything except 1.0 for the alpha channel -- even when WebGL content is rendered with an alpha channel less than 1.0! A solution to this problem which seems correct to me is to disable writes to the alpha channel when drawing these canvases' output. This should cause the layout test results to be completely opaque on all platforms and fix any problems with weird content showing up blended behind them. *** Bug 55968 has been marked as a duplicate of this bug. *** Created attachment 150842 [details]
Patch
Comment on attachment 150842 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=150842&action=review > Source/WebCore/platform/graphics/chromium/LayerRendererChromium.cpp:1024 > + GLC(context(), context()->colorMask(true, true, true, false)); We used to do this for the opaque root layer, due to problems with native Windows controls having bad alpha values due to GDI. However, this caused performance problems on ChromeOS and Android (see bug 72452) and so we switched to using a shader that always output an alpha value of 1. I think glBlendFuncSeparate might be a better option here. Created attachment 151572 [details]
Patch
Redid patch in terms of blendFuncSeparate and re-tested. I have a feeling the CQ might reject this because the diff to LayoutTests/ChangeLog doesn't start at line 1, but I tried "git diff --precise" and it still didn't do the right thing. Comment on attachment 151572 [details]
Patch
R=me.
Comment on attachment 151572 [details] Patch Clearing flags on attachment: 151572 Committed r122306: <http://trac.webkit.org/changeset/122306> All reviewed patches have been landed. Closing bug. |