Bug 146784

Summary: Brightness filter on image with transition ignores border radius clipping on ancestor
Product: WebKit Reporter: Amaury Bauzac <amaury.bauzac>
Component: CSSAssignee: Simon Fraser (smfr) <simon.fraser>
Status: RESOLVED DUPLICATE    
Severity: Normal CC: commit-queue, dino, freezindevil, sabouhallawa, simon.fraser, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
WIP none

Amaury Bauzac
Reported 2015-07-09 06:56:35 PDT
Version : 537.36 Reproduced on Chrome 43 and Safari Hello, I encounter a CSS problem using the brightness filter and transition filter on an image. Here is a simple example : <style> div { border: 4px solid #fff; border-radius: 50%; overflow: hidden; } img { -webkit-filter: brightness(0.8); -webkit-transition: -webkit-filter 1s ease-out; width: 100%; } img:hover { -webkit-filter: brightness(0.6); } </style> <div> <img src="http://i0.kym-cdn.com/photos/images/facebook/000/581/722/7bc.jpg"> </div> Or see directly : http://codepen.io/bqlou/pen/rVvLXK Expected result : when hovering the image, brightness applies to the image Actual result : when hovering the image, brightness applies to the image without repainting the whole picture during the transition
Attachments
WIP (24.02 KB, patch)
2016-05-09 08:41 PDT, Simon Fraser (smfr)
no flags
Simon Fraser (smfr)
Comment 1 2015-07-10 08:54:16 PDT
The bug here is that we're not taking the border-radius into account for the composited clip while the transition is running. I think we have another bug on this.
Radar WebKit Bug Importer
Comment 2 2015-07-10 08:54:45 PDT
Simon Fraser (smfr)
Comment 3 2016-05-07 10:43:22 PDT
The problem is more general. Any layer that has an "ancestor clipping layer" that's affected by corner radius doesn't take the radius into account.
Simon Fraser (smfr)
Comment 4 2016-05-09 08:41:10 PDT
WebKit Commit Bot
Comment 5 2016-05-09 08:44:46 PDT
Attachment 278406 [details] did not pass style-queue: ERROR: Source/WebCore/rendering/RenderLayer.h:817: The parameter name "context" adds no information, so it should be removed. [readability/parameter_name] [5] Total errors found: 1 in 14 files If any of these errors are false positives, please file a bug against check-webkit-style.
Simon Fraser (smfr)
Comment 6 2019-10-30 12:06:22 PDT
*** Bug 203558 has been marked as a duplicate of this bug. ***
Simon Fraser (smfr)
Comment 7 2022-08-31 14:40:20 PDT
*** This bug has been marked as a duplicate of bug 68196 ***
Note You need to log in before you can comment on or make changes to this bug.