Bug 142662

Summary: Elements with backdrop-filter cannot be clipped with clip-path or mask
Product: WebKit Reporter: Jer Noble <jer.noble>
Component: Layout and RenderingAssignee: Antoine Quint <graouts>
Status: RESOLVED FIXED    
Severity: Normal CC: buildbot, chrisjshull, commit-queue, dino, eelco, graouts, kristian.matthews, rniwa, ryanhaddad, simon.fraser, thorton, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
backdrop-blur-clip-path testcase
none
Patch
none
Archive of layout-test-results from ews103 for mac-yosemite
none
Archive of layout-test-results from ews107 for mac-yosemite-wk2
none
Archive of layout-test-results from ews115 for mac-yosemite
none
Patch
none
Patch
none
Patch
none
Archive of layout-test-results from ews101 for mac-yosemite
none
Archive of layout-test-results from ews104 for mac-yosemite-wk2
none
Archive of layout-test-results from ews112 for mac-yosemite
none
Patch
none
Patch for landing
none
Archive of layout-test-results from webkit-cq-01 for mac-yosemite
none
Patch
none
Patch for landing none

Description Jer Noble 2015-03-13 01:00:15 PDT
Elements with a backdrop-filter cannot be clipped with border-radius, clip-path, clip, or mask.
Comment 1 Jer Noble 2015-03-13 01:01:07 PDT
Created attachment 248578 [details]
backdrop-blur-clip-path testcase
Comment 2 Radar WebKit Bug Importer 2015-03-13 01:02:12 PDT
<rdar://problem/20150192>
Comment 3 Antoine Quint 2016-05-18 04:56:34 PDT
Created attachment 279233 [details]
Patch
Comment 4 Build Bot 2016-05-18 05:22:43 PDT
Comment on attachment 279233 [details]
Patch

Attachment 279233 [details] did not pass mac-ews (mac):
Output: http://webkit-queues.webkit.org/results/1342414

New failing tests:
css3/filters/backdrop/backdrop-filter-with-clip-path.html
Comment 5 Build Bot 2016-05-18 05:22:51 PDT
Created attachment 279234 [details]
Archive of layout-test-results from ews103 for mac-yosemite

The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews103  Port: mac-yosemite  Platform: Mac OS X 10.10.5
Comment 6 Build Bot 2016-05-18 05:24:04 PDT
Comment on attachment 279233 [details]
Patch

Attachment 279233 [details] did not pass mac-wk2-ews (mac-wk2):
Output: http://webkit-queues.webkit.org/results/1342413

New failing tests:
css3/filters/backdrop/backdrop-filter-with-clip-path.html
Comment 7 Build Bot 2016-05-18 05:24:08 PDT
Created attachment 279235 [details]
Archive of layout-test-results from ews107 for mac-yosemite-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews107  Port: mac-yosemite-wk2  Platform: Mac OS X 10.10.5
Comment 8 Build Bot 2016-05-18 05:54:18 PDT
Comment on attachment 279233 [details]
Patch

Attachment 279233 [details] did not pass mac-debug-ews (mac):
Output: http://webkit-queues.webkit.org/results/1342486

New failing tests:
css3/filters/backdrop/backdrop-filter-with-clip-path.html
Comment 9 Build Bot 2016-05-18 05:54:22 PDT
Created attachment 279236 [details]
Archive of layout-test-results from ews115 for mac-yosemite

The attached test failures were seen while running run-webkit-tests on the mac-debug-ews.
Bot: ews115  Port: mac-yosemite  Platform: Mac OS X 10.10.5
Comment 10 Antoine Quint 2016-05-18 06:16:13 PDT
Created attachment 279239 [details]
Patch
Comment 11 Simon Fraser (smfr) 2016-05-18 09:36:54 PDT
Comment on attachment 279239 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=279239&action=review

> Source/WebCore/platform/graphics/ca/GraphicsLayerCA.cpp:2456
> +    hostLayerForSublayers()->setMask(maskCALayer);

I think using primaryLayer() would be more appropriate.

You also need to fix the code below to do the right thing for layer clones (test with -webkit-box-reflect on something with a backdrop; uknown if this works now).
Comment 12 Dean Jackson 2016-05-18 17:22:41 PDT
Comment on attachment 279239 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=279239&action=review

>> Source/WebCore/platform/graphics/ca/GraphicsLayerCA.cpp:2456
>> +    hostLayerForSublayers()->setMask(maskCALayer);
> 
> I think using primaryLayer() would be more appropriate.
> 
> You also need to fix the code below to do the right thing for layer clones (test with -webkit-box-reflect on something with a backdrop; uknown if this works now).

I'm not sure it works.
Comment 13 Antoine Quint 2016-05-20 05:02:43 PDT
(In reply to comment #12)
> Comment on attachment 279239 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=279239&action=review
> 
> >> Source/WebCore/platform/graphics/ca/GraphicsLayerCA.cpp:2456
> >> +    hostLayerForSublayers()->setMask(maskCALayer);
> > 
> > I think using primaryLayer() would be more appropriate.
> > 
> > You also need to fix the code below to do the right thing for layer clones (test with -webkit-box-reflect on something with a backdrop; uknown if this works now).
> 
> I'm not sure it works.

It doesn't work, before or after this patch. No reflections are drawn when a clip-path is applied. I think this falls outside the scope of this particular bug.
Comment 14 Antoine Quint 2016-05-24 06:15:06 PDT
Created attachment 279647 [details]
Patch
Comment 15 Antoine Quint 2016-05-24 06:49:38 PDT
Created attachment 279649 [details]
Patch
Comment 16 Build Bot 2016-05-24 07:17:08 PDT
Comment on attachment 279649 [details]
Patch

Attachment 279649 [details] did not pass mac-ews (mac):
Output: http://webkit-queues.webkit.org/results/1374690

New failing tests:
css3/filters/backdrop/backdrop-filter-with-clip-path.html
Comment 17 Build Bot 2016-05-24 07:17:13 PDT
Created attachment 279650 [details]
Archive of layout-test-results from ews101 for mac-yosemite

The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews101  Port: mac-yosemite  Platform: Mac OS X 10.10.5
Comment 18 Build Bot 2016-05-24 07:18:12 PDT
Comment on attachment 279649 [details]
Patch

Attachment 279649 [details] did not pass mac-wk2-ews (mac-wk2):
Output: http://webkit-queues.webkit.org/results/1374688

New failing tests:
css3/filters/backdrop/backdrop-filter-with-clip-path.html
Comment 19 Build Bot 2016-05-24 07:18:17 PDT
Created attachment 279651 [details]
Archive of layout-test-results from ews104 for mac-yosemite-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews104  Port: mac-yosemite-wk2  Platform: Mac OS X 10.10.5
Comment 20 Build Bot 2016-05-24 07:47:10 PDT
Comment on attachment 279649 [details]
Patch

Attachment 279649 [details] did not pass mac-debug-ews (mac):
Output: http://webkit-queues.webkit.org/results/1374765

New failing tests:
css3/filters/backdrop/backdrop-filter-with-clip-path.html
Comment 21 Build Bot 2016-05-24 07:47:15 PDT
Created attachment 279652 [details]
Archive of layout-test-results from ews112 for mac-yosemite

The attached test failures were seen while running run-webkit-tests on the mac-debug-ews.
Bot: ews112  Port: mac-yosemite  Platform: Mac OS X 10.10.5
Comment 22 Antoine Quint 2016-05-24 12:04:04 PDT
Created attachment 279682 [details]
Patch
Comment 23 Antoine Quint 2016-05-24 12:37:38 PDT
Created attachment 279691 [details]
Patch for landing
Comment 24 WebKit Commit Bot 2016-05-24 13:12:46 PDT
Comment on attachment 279691 [details]
Patch for landing

Rejecting attachment 279691 [details] from commit-queue.

Number of test failures exceeded the failure limit.
Full output: http://webkit-queues.webkit.org/results/1376363
Comment 25 WebKit Commit Bot 2016-05-24 13:12:50 PDT
Created attachment 279695 [details]
Archive of layout-test-results from webkit-cq-01 for mac-yosemite

The attached test failures were seen while running run-webkit-tests on the commit-queue.
Bot: webkit-cq-01  Port: mac-yosemite  Platform: Mac OS X 10.10.5
Comment 26 WebKit Commit Bot 2016-05-24 14:01:05 PDT
Comment on attachment 279691 [details]
Patch for landing

Clearing flags on attachment: 279691

Committed r201349: <http://trac.webkit.org/changeset/201349>
Comment 27 WebKit Commit Bot 2016-05-24 14:01:12 PDT
All reviewed patches have been landed.  Closing bug.
Comment 28 Ryan Haddad 2016-05-24 15:02:26 PDT
Reverted r201349 for reason:

This change caused compositing tests to assert on iOS simulator

Committed r201357: <http://trac.webkit.org/changeset/201357>
Comment 29 Ryan Haddad 2016-05-24 15:02:53 PDT
(In reply to comment #28)
> Reverted r201349 for reason:
> 
> This change caused compositing tests to assert on iOS simulator
> 
> Committed r201357: <http://trac.webkit.org/changeset/201357>

<https://build.webkit.org/builders/Apple%20iOS%209%20Simulator%20Debug%20WK2%20%28Tests%29/builds/2138>
Comment 30 Antoine Quint 2016-05-25 01:39:19 PDT
Created attachment 279747 [details]
Patch
Comment 31 Antoine Quint 2016-05-25 02:19:00 PDT
Created attachment 279750 [details]
Patch for landing
Comment 32 WebKit Commit Bot 2016-05-25 02:48:24 PDT
Comment on attachment 279750 [details]
Patch for landing

Clearing flags on attachment: 279750

Committed r201374: <http://trac.webkit.org/changeset/201374>
Comment 33 WebKit Commit Bot 2016-05-25 02:48:30 PDT
All reviewed patches have been landed.  Closing bug.