Implement `CanvasRenderingContext2D.createConicGradient`
Categories
(Core :: Graphics: Canvas2D, enhancement, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox86 | --- | fixed |
People
(Reporter: ntim, Assigned: aryanagal98, Mentored)
References
Details
(Keywords: dev-doc-complete, good-first-bug, Whiteboard: [lang=c++])
Attachments
(1 file, 2 obsolete files)
Not officially speced yet, but:
see https://github.com/whatwg/html/issues/5431
and
https://github.com/fserb/canvas2D/blob/master/spec/conic-gradient.md
Updated•5 years ago
|
Reporter | ||
Comment 1•5 years ago
|
||
Updated•5 years ago
|
Updated•4 years ago
|
Reporter | ||
Updated•4 years ago
|
Reporter | ||
Updated•4 years ago
|
Comment 2•4 years ago
|
||
What needs to be done here:
- Basically, checking out https://phabricator.services.mozilla.com/D69465, and rebasing it to trunk (or doing the same changes on top of trunk).
- Adding a new pref near here. It has to be a
RelaxedAtomicBool
pref, and name should probably becanvas.createConicGradient.enabled
or such. Default value should betrue
, andmirror
can bealways
, I think it's fine as long as we send an intent email as per the exposure guidelines (I can take care of that bit once the patch is ready to land). - Changing the
[Pref="..."]
on top of the new function inCanvasRenderingContext2D.webidl
to use[Pref="canvas.createConicGradient.enabled"]
. - Running the
html/canvas/element/fill-and-stroke-styles/2d.gradient.conic.html
test, and ensure it passes with your changes. You can do this with./mach wpt html/canvas/element/fill-and-stroke-styles/2d.gradient.conic.html
- Since it should start passing,
testing/web-platform/meta/html/canvas/element/fill-and-stroke-styles/2d.gradient.conic.html.ini
should be removed. - Check whether we need to do the same with
html/canvas/offscreen/fill-and-stroke-styles/2d.gradient.conic.html
, and the similar metadata (not sure off-hand what's the state of ourOffscreenCanvas
implementation.
I think that should be it. Feel free to ask questions if you get stuck or something doesn't work as expected. Tim, can you sanity-check and confirm I haven't missed anything?
Reporter | ||
Comment 3•4 years ago
|
||
(In reply to Emilio Cobos Álvarez (:emilio) from comment #2)
I think that should be it. Feel free to ask questions if you get stuck or something doesn't work as expected. Tim, can you sanity-check and confirm I haven't missed anything?
Sounds fine to me. I'm unsure what graphics backend canvas is using, but should be fine as long as it's not Cairo.
Assignee | ||
Comment 4•4 years ago
|
||
Added an option to use ConicGradient API as a preference and removed the corresponding expected FAILing test, over @ntim's implementation.
Updated•4 years ago
|
Updated•4 years ago
|
Updated•4 years ago
|
Assignee | ||
Comment 5•4 years ago
|
||
Added an option to use ConicGradient API as a preference and removed the
corresponding expected FAILing test, over @ntim's implementation.
Updated•4 years ago
|
Comment 7•4 years ago
|
||
bugherder |
Comment 8•4 years ago
|
||
Rumyra documented this, and her work looks fantastic! See
- https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/createConicGradient
- See https://github.com/mdn/content/issues/1724 for the wider discussion of the work
Please let us know if you think anything else is needed here.
Description
•