Closed Bug 482751 Opened 15 years ago Closed 13 years ago

GlobalAlpha ignored when rendering gradients in HTML Canvas.

Categories

(Core :: Graphics: Canvas2D, defect)

1.9.0 Branch
x86
Windows Vista
defect
Not set
major

Tracking

()

RESOLVED INCOMPLETE

People

(Reporter: f1lt3r, Unassigned)

References

()

Details

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 6.0; en-GB; rv:1.9.0.7) Gecko/2009021910 Firefox/3.0.7
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 6.0; en-GB; rv:1.9.0.7) Gecko/2009021910 Firefox/3.0.7

When using a gradient fillStyle with the canvas, the globalAlpha property gets ignored. Safari, Chrome and Opera all render gradients with globalAlpha correctly. FireFox does not.

I built a testcase for you here:
http://hyper-metrix.com/burst/development/doc/tests/globalAlphaGradient/globalAlphaGradient.htm

Reproducible: Always

Steps to Reproduce:
1. Build a canvas and make a gradient with no opacity.
2. Set the globalAlpha to .5
3. Render the canvas.
Actual Results:  
The gradient was rendered as solid, without any alpha.

Expected Results:  
The globalAlpha should affect the gradient causing it to render at .5, allowing you to see the background through the gradient.

I built a testcase for you here:
http://hyper-metrix.com/burst/development/doc/tests/globalAlphaGradient/globalAlphaGradient.htm
This seems fixed in the latest trunk build. Trunk builds:
http://ftp.mozilla.org/pub/mozilla.org/firefox/nightly/latest-mozilla-central/
Component: General → Layout: Canvas
Product: Firefox → Core
QA Contact: general → layout.canvas
Version: unspecified → 1.9.0 Branch
Checking this now... does this mean these changes will get merged into the next official release? Or are there more hoops to jump through first?
I clicked on the link you provided and downloaded the WIN32 version of the latest nightly. It does not appear to be fixed in this version.
Correction, it does work in the win32 installer, but not in the win32 zip.
(In reply to comment #1)
> This seems fixed in the latest trunk build. Trunk builds:
> http://ftp.mozilla.org/pub/mozilla.org/firefox/nightly/latest-mozilla-central/

Will this be fixed in the next release?
Please re-open if this bug isn't fixed.
Status: UNCONFIRMED → RESOLVED
Closed: 13 years ago
Resolution: --- → INCOMPLETE
You need to log in before you can comment on or make changes to this bug.