WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED DUPLICATE of
bug 106674
105570
Applying multiple Filter Functions may lead to unexpected results
https://bugs.webkit.org/show_bug.cgi?id=105570
Summary
Applying multiple Filter Functions may lead to unexpected results
eric.lemoine
Reported
2012-12-20 12:54:57 PST
A -webkit-filter with multiple Filter Functions may lead to unexpected results. This is an example that illustrates the issue: #rect { width: 200px; height: 200px; background-color: #ff0000; /* red */ -webkit-filter: brightness(1) brightness(-1); } I would expect the -webkit-filter to be a noop in this case, which means that div should stay red. But, instead, the filter makes it black. It makes it black becasuse the first Filter Function changes the color to #ffffff (white), and the second Filter Function changes the color #000000 (black). In other words clipping occurs each time a Filter Function is applied, instead of on the final result. See
http://jsfiddle.net/jwCgV/
for reproducing.
Attachments
Add attachment
proposed patch, testcase, etc.
Dirk Schulze
Comment 1
2013-01-11 15:34:55 PST
IIRC this is a duplicate. *** This bug has been marked as a duplicate of
bug 106674
***
Dirk Schulze
Comment 2
2013-01-13 09:48:03 PST
(In reply to
comment #0
)
> -webkit-filter: brightness(1) brightness(-1);
Even if webkit would work as specified, a brightness operation can be irreversible since information get lost (when multiplying the amount, the color value can get beyond 255 or 0, where it get truncated).
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug