Menu

#302 Bad input lag in GNOME Wayland when run in fullscreen

v0.9.35
open
nobody
None
1
6 days ago
6 days ago
No

Hi,

Tux Paint exhibits unusable input lag on GNOME (Wayland) when painting with the brush or any tool with a dynamically updated cursor. The problem happens only in fullscreen.

Every mouse motion event during painting triggers brush_draw() and finishes with SDL_RendererPresent() to update the screen. Unfortunately, each call to SDL_RendererPresent() waits for VSync and this produces the horrible lag.

I've tried to use the following without success:

  • Disabling VSync in SDL using SDL_SetHint(SDL_HINT_RENDER_VSYNC, "0")and SDL_RenderSetVSync(renderer, 0);
  • Switching the SDL video driver between X11 and Wayland

Moving forward, I think Tux Paint's responsiveness could be improved by completing moving away from the rendering assumptions made in SDL 1.2 and decoupling frame rate from input rate.

Discussion


Log in to post a comment.

MongoDB Logo MongoDB