-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Screenshot in sim menu not capturing graphs #259
Comments
@catherinecarter We need more info about your computer. Please choose PhET Menu > Report A Problem in the sim, and copy the full unedited info into this issue. |
I have no idea what could be causing this, and I have no familiarity with the Screenshot feature implementation. This sim is using bamboo throughout. Interesting that the curves for the radio buttons are showing up, because they are also bamboo. The only place we're explicitly setting |
Test device Troubleshooting information: |
I reproduced on macOS 13.2.1 with all browsers: Chrome Version 110.0.5481.177, Safari 16.3, and Firefox 110.0.1. So it's not browser specific. |
@pixelzoom - This has happened in other sims ... e.g. Greenhouse photons not appearing: This is what Sam said there: phetsims/greenhouse-effect#255 (comment)
|
This sim is not using canvas. |
fourier-making-waves also uses bamboo, and does not exhibit this problem. It uses canvas - CanvasLinePlot, ChartCanvasNode, etc. |
And @zepumph said here: phetsims/my-solar-system#52 (comment) |
If those aren't helpful then consult with @jonathanolson |
@kathy-phet said:
We are indeed using |
Maybe @jonathanolson would recommend just listening for Screenshot and then changing the boundsMethod for that particular context to keep it speedy otherwise. Not sure. |
@pixelzoom, you and I both seemed to have the same, incomplete understanding of Basically just supply a |
In phetsims/my-solar-system#52 (comment), @zepumph said:
@jonathanolson is there any chance that this bug can be fixed, instead of having to add this localBounds workaround? We have many places in calculus-grapher where this workaround would need to be applied. |
The conversation I had with @jonathanolson made me realize that in fact the We spoke briefly in the conversation about hard coding a closer connection to those two steps, perhaps with assertions, but it is kinda challenging to know, so instead we made sure the doc was up to date and loud about boundsMethod: https://github.com/phetsims/scenery/blob/e528fceb850b87bf29c53ce979efdcad9b0915ac/js/nodes/Path.ts#L61-L63 I hope that is helpful, and I'm happy to talk next steps with you in person if that is best. |
It sure would be nice to have some input from @jonathanolson here. |
OK. And it's not possible to let the programmer know that they've done that? Or document it somewhere? So that we don't find out weeks later when Screenshot is broken? |
…cal (TangentArrowNode and AreaUnderCurvePlot), #259
We moved the documentation to where
|
@zepumph noted that it seems important to have assertions to catch cases like this. I agree (we don't want things cut off, whether they are CanvasNode/WebGLNode/boundsMethod:none, etc.) This is on me, when I recommended boundsMethod:none, (a) I didn't consider the screenshot handling or Canvas render path, (b) I didn't have assertions on to protect against this, and (c) I didn't have documentation recommending this. Especially with WebGL rendering more in the future, I think it's important to have the bounds constraint be satisfied in general in our code. Any thoughts/objections on that path (adding assertions to detect bad bounds cases)? |
Sounds like an improvement. |
Issue in phetsims/scenery#1546 for the assertions |
I'm having no luck using the |
Not sure, I'll look into it tomorrow. My understanding is that (a) it should be something finite, and (b) it should be on the Path itself with boundsMethod:none. |
Implemented above. I'm not quite sure what was going wrong. Can you see how this implementation looks? (Also the clip area for the curveLayer in GraphNode is using |
Thanks @jonathanolson, changes look great. And I confirmed that everything is present in Screenshots. We may ultimately switch to bamboo Canvas implementation for performance. But thi issue can be consider "done" and closed. |
In Calculus Grapher, the screenshot tool from the PhET menu in the nav bar isn't capturing the graphs. See screenshots below. The first screenshot is the one taken using the sim menu. The second screenshot I took with my computer and reveals what was actually there.
Screenshot with sim tool shows no graph lines:
These are the graph lines that it should be showing:
The text was updated successfully, but these errors were encountered: