Changeset 148117 in webkit


Ignore:
Timestamp:
Apr 10, 2013 11:48:01 AM (11 years ago)
Author:
Alexandru Chiculita
Message:

Layers with opacity and blur filters are reported as opaque to the compositor
https://bugs.webkit.org/show_bug.cgi?id=114295

Reviewed by Simon Fraser.

Source/WebCore:

Test: compositing/contents-opaque/filter.html

Some filters like opacity and blur might still trigger transparency in the layer, even though the
background is opaque. I've added the special case in RenderLayer::backgroundIsKnownToBeOpaqueInRect to check
for filters that might have transparency. Note that this special case is required only for software drawn
filters, as the transparency is going to be backed in the GraphicsLayer content. Composited filters can
figure it out in the compositor.

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::backgroundIsKnownToBeOpaqueInRect):

LayoutTests:

Added test to check for blur and opacity filters drawn in software mode which needs
to force the layer report non-opaque to the compositor.

  • compositing/contents-opaque/filter-expected.txt: Added.
  • compositing/contents-opaque/filter.html: Added.
Location:
trunk
Files:
2 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r148115 r148117  
     12013-04-10  Alexandru Chiculita  <achicu@adobe.com>
     2
     3        Layers with opacity and blur filters are reported as opaque to the compositor
     4        https://bugs.webkit.org/show_bug.cgi?id=114295
     5
     6        Reviewed by Simon Fraser.
     7
     8        Added test to check for blur and opacity filters drawn in software mode which needs
     9        to force the layer report non-opaque to the compositor.
     10
     11        * compositing/contents-opaque/filter-expected.txt: Added.
     12        * compositing/contents-opaque/filter.html: Added.
     13
    1142013-04-10  Noam Rosenthal  <noam@webkit.org>
    215
  • trunk/Source/WebCore/ChangeLog

    r148115 r148117  
     12013-04-10  Alexandru Chiculita  <achicu@adobe.com>
     2
     3        Layers with opacity and blur filters are reported as opaque to the compositor
     4        https://bugs.webkit.org/show_bug.cgi?id=114295
     5
     6        Reviewed by Simon Fraser.
     7
     8        Test: compositing/contents-opaque/filter.html
     9
     10        Some filters like opacity and blur might still trigger transparency in the layer, even though the
     11        background is opaque. I've added the special case in RenderLayer::backgroundIsKnownToBeOpaqueInRect to check
     12        for filters that might have transparency. Note that this special case is required only for software drawn
     13        filters, as the transparency is going to be backed in the GraphicsLayer content. Composited filters can
     14        figure it out in the compositor.
     15
     16        * rendering/RenderLayer.cpp:
     17        (WebCore::RenderLayer::backgroundIsKnownToBeOpaqueInRect):
     18
    1192013-04-10  Noam Rosenthal  <noam@webkit.org>
    220
  • trunk/Source/WebCore/rendering/RenderLayer.cpp

    r147940 r148117  
    55675567        return false;
    55685568
     5569#if ENABLE(CSS_FILTERS)
     5570    if (paintsWithFilters() && renderer()->style()->filter().hasFilterThatAffectsOpacity())
     5571        return false;
     5572#endif
     5573
    55695574    // FIXME: Handle simple transforms.
    55705575    if (paintsWithTransform(PaintBehaviorNormal))
Note: See TracChangeset for help on using the changeset viewer.