Closed Bug 1427778 Opened 6 years ago Closed 6 years ago

Using an svg linear gradient as a mask no longer works

Categories

(Core :: SVG, defect, P3)

57 Branch
Unspecified
Windows
defect

Tracking

()

RESOLVED FIXED
Tracking Status
firefox-esr52 --- unaffected
firefox-esr60 --- wontfix
firefox57 --- wontfix
firefox58 --- wontfix
firefox59 --- wontfix
firefox60 --- wontfix
firefox61 --- fixed
firefox62 --- unaffected
firefox63 --- unaffected
firefox64 --- unaffected
firefox65 --- unaffected

People

(Reporter: johnattanbarona, Assigned: bas.schouten)

References

Details

(Keywords: regression)

Attachments

(1 file, 1 obsolete file)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/63.0.3239.84 Safari/537.36

Steps to reproduce:

Implemented an svg linear gradient as mask to give a faded look to part of shape.


<svg width= "660" height="220">
<defs>
<linearGradient id="gradient">
<stop offset="0" stop-color="white" stop-opacity="0.25"/>
<stop offset="1" stop-color="white" stop-opacity="1"/>
</linearGradient>

<mask id="gradientMask">
<rect x="0" y="0" width="210" height="210" fill="url(#gradient)"/>
</mask>
</defs>

<circle cx="110" cy="110" r="100" fill="#9c6" mask="url(#gradientMask)"/>

<svg>


Actual results:

Image is completely opaque.


Expected results:

Image was suppose to be 25% opaque on the left and fully opaque on the right.
Example can be found at vanseodesign.com/web-design/svg-masking-examples-1
Attached file reporter's testcase (obsolete) —
Attachment #8939611 - Attachment mime type: text/plain → image/svg+xml
Attachment #8939611 - Attachment mime type: image/svg+xml → text/plain
Attached image reporter's testcase
Attachment #8939611 - Attachment is obsolete: true
Attachment #8939616 - Attachment mime type: text/plain → image/svg+xml
Seems fine on a Mac on Firefox 57. We may need a windows regression range
OS: Unspecified → Windows
Status: UNCONFIRMED → NEW
Ever confirmed: true
Erm, I only reviewed part of this, but since Mason is gone and Jeff is busy I'll try to have a look.
Assignee: nobody → bas
Status: NEW → ASSIGNED
Flags: needinfo?(bas)
[ Triage 2017/02/20: P3 ]
Priority: -- → P3
Fwiw, the testcase looks fine to me on Linux.
Does the bug still occur on Windows?
Flags: needinfo?(alice0775)
yes, it is fixed.  No longer reproduce the issue since Firefox61 windows10.
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Flags: needinfo?(alice0775)
Resolution: --- → FIXED
Great, thanks Alice.

We should try to add a WPT / reftest for this so we catch it if it breaks again.
Flags: in-testsuite?
Fixed by :
458c07cbe94b	Lee Salzman — Bug 1448667 - use ColorMatrix effect instead of LuminanceToAlpha effect for DrawTargetD2D1::IntoLuminanceSource. r=bas
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: