Firefox Screenshots Fail to Capture Canvas Elements
Categories
(Core :: Graphics, defect, P2)
Tracking
()
Tracking | Status | |
---|---|---|
firefox-esr68 | --- | unaffected |
firefox-esr78 | --- | unaffected |
firefox-esr91 | 94+ | verified |
firefox79 | --- | wontfix |
firefox80 | --- | wontfix |
firefox81 | --- | wontfix |
firefox82 | --- | wontfix |
firefox83 | --- | wontfix |
firefox84 | --- | wontfix |
firefox85 | --- | wontfix |
firefox86 | --- | wontfix |
firefox92 | --- | wontfix |
firefox93 | + | wontfix |
firefox94 | + | verified |
People
(Reporter: artemx100, Assigned: jgilbert)
References
(Regression, )
Details
(Keywords: regression)
Attachments
(2 files)
190.07 KB,
image/png
|
Details | |
48 bytes,
text/x-phabricator-request
|
RyanVM
:
approval-mozilla-esr91+
|
Details | Review |
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:82.0) Gecko/20100101 Firefox/82.0
Steps to reproduce:
- Visit https://teemo.gg/model-viewer?skinid=nami-15&model-type=champions
- Scroll down and try to take a screenshot of the canvas element
Actual results:
The canvas element is invisible in the screenshot
Expected results:
The canvas element should appear in the screenshot.
For what it matters, I tested and it works properly in Firefox 66.0.5, however it does not work in Firefox 79.0, meaning the regression happened somewhere between those two versions.
Comment 2•4 years ago
|
||
Bugbug thinks this bug should belong to this component, but please revert this change in case of error.
Comment 3•4 years ago
|
||
I can reproduce the problem on Nightly82.0a1 Win10.
Regression window:
https://hg.mozilla.org/integration/autoland/pushloghtml?fromchange=4879dea5cdd64080b5ae0c6c877bd87d76d06fda&tochange=7ba2f2cf6bdedd2cafd4e8717fa548e5b54dd184
Updated•4 years ago
|
Comment 5•4 years ago
|
||
Hi Kris, can you set the severity for this bug, please?
Assignee | ||
Updated•4 years ago
|
Updated•4 years ago
|
Comment 9•4 years ago
|
||
Any particular reason? The regressor identified dates back to July 9, and this wasn't found until 2 months later, so it doesn't look like this is frequently hit. Maybe we can make an argument that it should go before trying to fix the perf issues, perhaps.
Updated•4 years ago
|
Updated•4 years ago
|
Comment 10•4 years ago
|
||
Hey :artemx100, thanks for reporting this. Are you still seeing this issue?
I believe this may have been fixed by Bug 1660651, as I can no longer reproduce
Reporter | ||
Comment 11•4 years ago
|
||
(In reply to Emma Malysz from comment #10)
Hey :artemx100, thanks for reporting this. Are you still seeing this issue?
I believe this may have been fixed by Bug 1660651, as I can no longer reproduce
Yes, I still can. The issue is still unsolved in the most recent nightly build.
Tested with both my current and a fresh profile.
Version 84.0a1
Build ID 20201103095421
Comment 12•4 years ago
|
||
Thanks! It looks like this issue does not affect Mac, but I was able to reproduce on Windows
Comment 13•3 years ago
|
||
This feels like a regression that should be getting on someone's radar rather than slipping release after release. Any chance we can revisit the prioritization here?
Updated•3 years ago
|
Comment 14•3 years ago
|
||
This still trivially reproduces for me on any WebGL content on Windows 10, even simple content like the MDN page below:
https://developer.mozilla.org/en-US/docs/Web/API/WebGL_API/By_example/Clearing_with_colors
Jim, does a simpler testcase make this easier to prioritize?
Updated•3 years ago
|
Updated•3 years ago
|
Comment 16•3 years ago
|
||
I just noticed this bug impacts taking screenshots of Google Maps. Seems kinda bad. Do we have any idea what's broken here and how to fix it? I might be able to find someone to work on it if JeffG is too busy.
Comment 17•3 years ago
|
||
Jim, I think Jeff tried to debug this, and then ran into the bug this depends on, i.e. that the feature is completely broken in debug mode, which complicated things. I think he was going to look again when that gets fixed...but we can't seem to get traction in that team.
If you feel it's urgent and have availability, feel free to take it.
Comment 18•3 years ago
|
||
Hmm, there's at least a WIP patch in the other bug now.
Comment 20•3 years ago
|
||
Thank you very much Emma! That will probably help whoever ends up tackling that bug.
Comment 21•3 years ago
|
||
I ran into this today taking a screenshot of google maps. I'd like to try and figure out what's going wrong here and get it fixed.
Updated•3 years ago
|
Comment 22•3 years ago
|
||
Reproducible in 91.0.1 x64. Check Google Maps or, for example, Johns Hopkins University's COVID-19 statistics page.
https://www.arcgis.com/apps/dashboards/bda7594740fd40299423467b48e9ecf6
Unfortunately, cannot tell exactly when it started but a few releases ago (~ v85.x) it worked well.
Comment 26•3 years ago
|
||
This is not an S3 bug if it affects major sites like Google Maps. We need to bump this up in priority and figure out a path forward.
Comment 27•3 years ago
|
||
Since I believe this is an issue with browser.tabs.captureTab
, I want to point out that the API is also used to report a site issue (https://searchfox.org/mozilla-central/rev/4d90ff4537330d6b17cb956c0fadf759086d9bb7/browser/extensions/report-site-issue/background.js#106-109).
Maybe triggering from that flow will unblock this bug from Bug 1685388.
Regardless, I'm going to be prioritizing the screenshots work. Waiting on another debug build, hopefully this time I'll be able to reproduce
Comment 28•3 years ago
|
||
We weren't able to reproduce the issue in Bug 1685388. Provided no one is having the issue with screenshots in a debug build, I think this bug is considered unblocked and can be worked on
Assignee | ||
Comment 29•3 years ago
|
||
Here's an instant-loading example that screenshotting fails on: https://jdashg.github.io/misc/webgl/ping-pong.html
Assignee | ||
Comment 30•3 years ago
|
||
For WebGL canvases with preserveDrawingBuffer:false, frontbuffer
snapshotting was not working properly.
If the frontbuffer had no user-fb associated with it,
was inexplicably calling BindDefaultFBForRead, which binds
webgl's default FB, not gl's default FB 0.
This caused frontbuffer snappshotting to actually snapshot the (cleared)
backbuffer instead of the visible frontbuffer contents.
Updated•3 years ago
|
Comment 31•3 years ago
|
||
Pushed by jgilbert@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/6b9c61565d44 Fix screenshotting of WebGL canvases. r=gfx-reviewers,lsalzman
Comment 32•3 years ago
|
||
bugherder |
Comment 33•3 years ago
|
||
Is there any way we can land a test for this? Also, please nominate for Beta and ESR91 approval when you get a chance.
Assignee | ||
Comment 34•3 years ago
|
||
Yeah, in two stages I think:
- Test the related functionality via canvas.toDataURL()
- Add actual Screenshots test here: https://searchfox.org/mozilla-central/source/browser/extensions/screenshots/test/browser/browser.ini
Comment 35•3 years ago
|
||
The patch landed in nightly and beta is affected.
:jgilbert, is this bug important enough to require an uplift?
If not please set status_beta
to wontfix
.
For more information, please visit auto_nag documentation.
Comment 36•3 years ago
|
||
Jeff, are you planning an uplift into our last beta or should we mark it wontfix for 93? Thanks
Assignee | ||
Comment 37•3 years ago
|
||
[Tracking Requested - why for this release]:
It sucks for users when screenshotting inexplicably doesn't work for some content, which users may not even realize is webgl.
Comment 38•3 years ago
|
||
Per discussion with Jeff, better to let this bake more given where we are in the cycle. Let's aim to get this into 91.3esr next cycle.
Updated•3 years ago
|
Assignee | ||
Comment 42•3 years ago
|
||
Comment on attachment 9241879 [details]
Bug 1661869 - Fix screenshotting of WebGL canvases.
ESR Uplift Approval Request
- If this is not a sec:{high,crit} bug, please state case for ESR consideration: Fix screenshotting of webgl canvases, such as Google Maps
- User impact if declined: Screenshotting of some canvases will continue to be broken.
- Fix Landed on Version: 94
- Risk to taking this patch: Low
- Why is the change risky/not risky? (and alternatives if risky): It has baked in 94 now, and few changes have happened between 91 and 94 in this area.
- String or UUID changes made by this patch: none
Updated•3 years ago
|
Comment 43•3 years ago
|
||
Reproduced the issue in Release 92, on google maps, using Win10.
Verified - Fixed in Beta 94.0b2 (build id: 20211005185813) and latest Nightly 95.0a1 (build id: 20211005094529). The screenshots are displayed accordingly, using google maps.
Comment 44•3 years ago
|
||
Comment on attachment 9241879 [details]
Bug 1661869 - Fix screenshotting of WebGL canvases.
Approved for 91.4esr.
Comment 45•3 years ago
|
||
bugherder uplift |
Comment 46•3 years ago
|
||
Verified - Fixed in 91.3.0esr (build id: 20211007190139) (https://hg.mozilla.org/releases/mozilla-esr91/rev/2d2658a85cef) on Win10. The screenshots are displayed correctly, using google maps.
Description
•