Closed ogoffart closed 1 year ago
I've tried to debug to figure out what's wrong.
In the event loop, we get a AboutToWait event, and the next_timer is about to fire so the next_timer is very low value:
We set control flow to ControlFlow with a wait duration of a a few, or 0ms. But we're never woken up. Changing that to ControlFlow::Poll doesn't help.
I think winit uses SetTimer and the minimum resolution of that is around 16ms (USER_TIMER_MINIMUM
). It might make sense for winit to use multimedia timers instead (timeSetEvent with a callback that wakes up winit), they offer a higher resolution. (That’s what Qt defaults to)
Discussed in https://github.com/slint-ui/slint/discussions/3873