Skip to content
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

Screen shaking with Photorealistic theme #807

Open
EESchneider opened this issue Aug 6, 2021 · 6 comments
Open

Screen shaking with Photorealistic theme #807

EESchneider opened this issue Aug 6, 2021 · 6 comments

Comments

@EESchneider
Copy link

EESchneider commented Aug 6, 2021

The board shakes rapidly when the window is maximized. When the board is shrunk at all (either/both from shrinking the window vertically or horizontally, and from enlarging the move-tree or engines-menu until it shrinks takes space away from the board), the issue disappears (this is sometimes a little inconsistent). Enabling coordinates also tends to make the issue go away (but again, occasionally doesn't). I have not experienced this issue with the default theme. My monitor is 1920x1080px, running on Windows 10, and using Sabaki v0.52.0.

Here is an example (where enabling coordinates did not help): https://giphy.com/gifs/EFDyACdVwfTr2I1nME/fullscreen

@sente361
Copy link

sente361 commented Aug 6, 2021

When I tried v0.52.0 I experienced a similar issue. The goban display was perfect when maximised to Full Screen. However when I reduced the size of the Sabaki window to part-screen the goban jittered annoyingly. I am using Windows 10 with the default theme. (I am surprised that this is the first time this issue has been raised; perhaps it is a Win10 issue and most people use linux?)

(I switched back to v0.51.1 due to this issue and also the fact that I prefer the way that version, in Edit Mode, handles comments in the "comments box" when moving between nodes in the game tree. I often reuse the same comment for different nodes; in V0.51.1 I can do this without having to use Copy & Paste by simply clicking from node to node, etc.)

@apetresc apetresc added the bug label Aug 6, 2021
@billhails
Copy link
Contributor

billhails commented Sep 12, 2021

Confirm I see this occasionally on a Mac too, not specific to full-screen, and not specific to a theme. Resizing usually stops it, guess it's some rounding error. FWIW I've only seen it when an engine is running.

[edit]
Just seen it again, so have a bit more info, at least in my case I notice the background and the last placed stone remain stationary while the board, grid and remaining stones wobble rapidly from side to side, much as in the video posted above. Also this time while engines were attached they were idle.

While it was happening I went through preferences and toggled each of the options in the main section, nothing had any effect on the movement.

@billhails
Copy link
Contributor

billhails commented Sep 12, 2021

More info, with developer tools open, I inspect the main goban div.

[edited]
Then on dragging the developer panel left and right I can provoke the bug. Jittering occurs while that inline style is being coloured white on purple, whatever that means. If the bug persists the style element remains white on purple, in this video it fades as the window is resized again and jittering stops. It seems very dependant on screen display because without attempting screen recording the computed values in the bottom panel also flicker in and out, in the video they just aren't visible until the issue clears.

https://www.dropbox.com/s/xz8xvybk1o0m3y3/Sabaki%202021-09-12%20at%2018.06.56.mov?dl=0

billhails added a commit to billhails/Sabaki that referenced this issue Sep 13, 2021
fix issue SabakiHQ#807

element offsetWidth and offsetHeight are rounded to integers,
which was causing off by one errors when further rounded to
calculate top and left values. This fix uses the raw floating
point width and height from getBoundingClientRect().

The jittering described in the issue is easily reproduced by
resizing the developer window to squash the goban, certain
sizes are problematic. I've not been able to reproduce the issue
with this fix in place.
@billhails billhails mentioned this issue Sep 13, 2021
@apetresc
Copy link
Member

Hey all; @billhails has opened a PR that hopefully fixes the issue, but I'm completely unable to reproduce the problem even on precisely Windows 10 with a variety of different themes and visual settings. Maybe it's specific to certain resolutions and/or scaling levels - can anyone let me know which ones they're using when they encounter this issue?

Alternatively, @EESchneider and/or @sente361 - can you guys check out #825 and try to see if that build fixes it for you as well? (Let me know if you're not sure how to produce a build from a branch yourselves, I can send builds to you!) If it does, I'm happy to merge even without being able to reproduce myself, since the change doesn't seem to cause any regressions either as far as I can tell.

Thanks!

@sente361
Copy link

sente361 commented Sep 14, 2021

I'm happy with v0.51.1 as explained in my last post (I prefer that editing mode). My set-up is completely standard Win10 and hardware. The jitter problem appeared with the new version. (So caused by some change made in the new version.) My experience was that full screen is fine but jittering starts when the window is reduced to less than full screen. At present I'd prefer not to play around with building a branch (which is foreign territory for me).

Note that when I experienced the jittering problem I was using Sabaki's Default theme, not Photorealistic (though I imagine that makes no difference to anything).

@billhails
Copy link
Contributor

If it helps I'm on a macbook pro (from work) 2880 x 1800

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

4 participants