Closed Bug 970600 Opened 10 years ago Closed 10 years ago

Enable background-blend-mode by default

Categories

(Core :: Web Painting, defect)

x86
All
defect
Not set
normal

Tracking

()

VERIFIED FIXED
mozilla30
Tracking Status
relnote-firefox --- 30+

People

(Reporter: olaru, Assigned: olaru)

References

(Depends on 1 open bug)

Details

(Keywords: dev-doc-complete, feature)

Attachments

(6 files, 3 obsolete files)

Enable the background-blend-mode CSS property be default in Release builds.
Attachment #8373667 - Flags: review?(roc)
Assignee: nobody → olaru
Attachment #8373667 - Attachment is patch: true
Attachment #8373667 - Attachment mime type: message/rfc822 → text/plain
Comment on attachment 8373667 [details] [diff] [review]
enable-background-blend-mode-by-default

Review of attachment 8373667 [details] [diff] [review]:
-----------------------------------------------------------------

Most of your patch removes trailing whitespace from all.js. Please do that in a separate patch :-)
Attachment #8373667 - Flags: review?(roc) → review-
Sorry about that :) Should be better in this patch.

I don't mind adding a patch that removes trailing whitespace later, but isn't that a bit disruptive for source control history?
Attachment #8373667 - Attachment is obsolete: true
Attachment #8373933 - Flags: review?(roc)
(In reply to Horia Iosif Olaru from comment #3)
> I don't mind adding a patch that removes trailing whitespace later, but
> isn't that a bit disruptive for source control history?

We generally don't see that as a problem.
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/01fd47b5eb1d
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla30
Attached image screenshot.png (obsolete) —
Just tested this in latest Nightly windows7 32 bit.
In all the test the purple color is displayed. See attachment.
Attached image screenshot.JPG (obsolete) —
Attached image screenshot.JPG
Attachment #8376310 - Attachment is obsolete: true
Attachment #8376312 - Attachment is obsolete: true
Keywords: feature
(In reply to Peter Kroon from comment #8)
> Created attachment 8376310 [details]
> screenshot.png
> 
> Just tested this in latest Nightly windows7 32 bit.
> In all the test the purple color is displayed. See attachment.

There seems to be a rendering difference for gradients between Firefox and Chrome. The violet you are seeing happens when the gradient goes from a fully transparent color to a fully opaque one. 

The color is violet because the starting point is a fully transparent blue (0, 0, 255, 0). If the color components would be black (0, 0, 0, 0) you would see a grey that appears between the two gradient start points.

I have not looked into which would be the correct behavior. I will attach a test and some screenshots.
Attached image Chorme_result.png
Attached image Firefox_result.png
An interesting observation is when interpolating from or to a transparent color
- Firefox takes the color components of the transparent stop point into account
- Chrome seems to take the color components of the non transparent stop point for both ends when interpolating (it looks like a gradient from (255, 0, 0, 0) to (255, 0, 0, 1))
(In reply to Horia Iosif Olaru from comment #15)
> An interesting observation is when interpolating from or to a transparent
> color
> - Firefox takes the color components of the transparent stop point into
> account
> - Chrome seems to take the color components of the non transparent stop
> point for both ends when interpolating (it looks like a gradient from (255,
> 0, 0, 0) to (255, 0, 0, 1))

This is because the CSS WG defined that gradients should interpolate in premultiplied colorspace (see my objection over this here: http://w3cmemes.tumblr.com/post/34628700024/when-worf-says-transparent-he-means)
Chrome is following the spec here and firefox is not.
(In reply to Rik Cabanier from comment #16)
> (In reply to Horia Iosif Olaru from comment #15)
> > An interesting observation is when interpolating from or to a transparent
> > color
> > - Firefox takes the color components of the transparent stop point into
> > account
> > - Chrome seems to take the color components of the non transparent stop
> > point for both ends when interpolating (it looks like a gradient from (255,
> > 0, 0, 0) to (255, 0, 0, 1))
> 
> This is because the CSS WG defined that gradients should interpolate in
> premultiplied colorspace (see my objection over this here:
> http://w3cmemes.tumblr.com/post/34628700024/when-worf-says-transparent-he-
> means)
> Chrome is following the spec here and firefox is not.

Has this been reported yet?
(In reply to Peter Kroon from comment #17)
> (In reply to Rik Cabanier from comment #16)
> > (In reply to Horia Iosif Olaru from comment #15)
> > > An interesting observation is when interpolating from or to a transparent
> > > color
> > > - Firefox takes the color components of the transparent stop point into
> > > account
> > > - Chrome seems to take the color components of the non transparent stop
> > > point for both ends when interpolating (it looks like a gradient from (255,
> > > 0, 0, 0) to (255, 0, 0, 1))
> > 
> > This is because the CSS WG defined that gradients should interpolate in
> > premultiplied colorspace (see my objection over this here:
> > http://w3cmemes.tumblr.com/post/34628700024/when-worf-says-transparent-he-
> > means)
> > Chrome is following the spec here and firefox is not.
> 
> Has this been reported yet?

Yes - this seems to be the exact same issue:
https://bugzilla.mozilla.org/show_bug.cgi?id=591600
QA Contact: bogdan.maris
QA Contact: bogdan.maris → catalin.varga
Attached image picture
I verified this bug using:

Firefox 30
Build id: 20140228030206
Os Win 7, Ubuntu 12.04 x 32 and Mac Os 10.9

I've used the following test:
http://html.adobe.com/webplatform/graphics/blendmodes/browser-support/?filter=background

During the test I've noticed that most of the images were different and the difference extended on to the circles not just the background. 
My assumption is that due to the bug  https://bugzilla.mozilla.org/show_bug.cgi?id=591600 the backround is changing and those changes in addition to the backround blending and rendering are changing the aspect of the circles.

I've attached and example that shows the differences that I was talking about.
(In reply to Catalin Varga [QA][:VarCat] from comment #19)
> Created attachment 8383724 [details]
> picture
> 
> I verified this bug using:
> 
> Firefox 30
> Build id: 20140228030206
> Os Win 7, Ubuntu 12.04 x 32 and Mac Os 10.9
> 
> I've used the following test:
> http://html.adobe.com/webplatform/graphics/blendmodes/browser-support/
> ?filter=background
> 
> During the test I've noticed that most of the images were different and the
> difference extended on to the circles not just the background. 
> My assumption is that due to the bug 
> https://bugzilla.mozilla.org/show_bug.cgi?id=591600 the backround is
> changing and those changes in addition to the backround blending and
> rendering are changing the aspect of the circles.

I'm unsure if that's the case. The background has no alpha so it should make no difference is the gradient is premultiplied.
 
> I've attached and example that shows the differences that I was talking
> about.

This looks more like a color management issue.
Added in the release note database for 30.
Depends on: 986524
Depends on: 1000907
This is not a bug with blending.
Notice how the gradient itself is rendered differently.
Marking this bug as Verified as the feature was released with Firefox 30.
Status: RESOLVED → VERIFIED
Component: Layout: View Rendering → Layout: Web Painting
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: