twinejs
twinejs copied to clipboard
2.4.0 Significant visual bug on pasage editor (OSX)
Describe the bug.
In some cases, the passage editor area becomes bugged, with windows constantly flickering and areas of each passage dialog re-drawing
https://user-images.githubusercontent.com/4206142/178777301-dec4a784-466c-44fd-888a-7428b831c7be.mov
Steps to reproduce:
I am not sure what triggered this. The only change I made was to enlarge the window size. Making the window smaller did appear to reduce/eliminate the flicker. Also notable is that the passage map did not fully draw at the larger size
Expected behavior:
The screen should stay stable regardless of size.
Additional context on this problem.
No response
Twine version number
2.4.0
Does this problem occur with the web version of Twine or the desktop app?
Desktop app
What operating system does this problem occur on?
macOS
If this problem is occurring with the web version of Twine, what browser does it occur on?
No response
Presubmission checklist
- [ ] I am interested in working on code that would fix this bug. (This is not required to submit a bug report.)
- [X] I have done a search and believe that an issue does not already exist for this bug in the GitHub repository.
- [X] I have read and agree to abide by this project's Code of Conduct.
A little more testing shows that this only happens on the lowest zoom level, so I suspect it's a memory issue to do with the load on the renderer? But it happens even when nothing is being interacted with, which suggests that the editor is re-rendering even on idle.
As a further test, I opened the same stories on the browser version, set them to the same map scale and window size, and opened the same passage, and did not suffer either the flickering, repainting errors, or blank areas on the passage map, so this seems to be restricted to the app version only.
The following screenshot shows the app window at large size and maximum zoom-out, showing both the errors in the map and the editors. This appears to be consistent. Opening any story to this size/zoom will have errors regardless of the number of passages.
On this second screenshot the title-bar area has also vanished, this is on a 2-passage story, and only one editor window is open.
In the second example (the 2-passage story), opening a single editor dialog (by double-clicking on a passage) was enough to make the dialog, the menu bar, the zoom controls, and chunks of the story map all vanish!
I suspect that it's tied to 2.4 leaning harder on the GPU. Scaling the entire passage map is done via CSS transform (it used to only be used for the link arrows). Could you...
- Go to Help > Troubleshooting > Show Debug Console in the menu bar
- Press command-shift-P and type "fps". An item labeled "Show frames per second (FPS) meter" should appear. Select this.
- Try to repro the problem and take a screenshot when it happens. I'm interested in the GPU memory reading more than the FPS in this case.
Sorry, covid made me rather slow to reply.
I think it's as I suspected, it's maxing out the GPU and you're seeing weird behavior as a result. (I don't know for sure this is true, just a strong guess.) First thing I want to try is upgrade Electron to the latest to see if that fixes the problem. If not, we can explore getting Twine to ask for more GPU memory... though I'm not sure what the right number is, and how asking for more will affect users.