[Windows] program hangs while window is being moved
On Windows, while moving the application window, the engine's main loop is blocked. Mostly I notice this with the dedicated server that prints "Hitch warning". And the freeze is mostly an actual problem when running a server, since there is an unwanted pause in the gameplay.
Actually it is even worse than just freezing while the window is being moved. The program seemingly stays frozen after the move finishes for an additional time which is linearly proportional to the time spent moving it...
This issue has been present forever but I was motivated to write down the issue since I stumbled across a relevant link. https://stackoverflow.com/questions/3102074/win32-my-application-freezes-while-the-user-resizes-the-window
I think I read a couple days ago that this is supposed to be fixed in SDL 2.30.
I think I read a couple days ago that this is supposed to be fixed in SDL 2.30.
I found that thing that I read: https://github.com/libsdl-org/SDL/issues/1059#issuecomment-1842148648
But it's not a very nice fix. What you have to do is register some sort of callback, which is invoked during the drag operation (how often?). The main loop is still blocked.
Just updating our SDL didn't change anything.
I think I read a couple days ago that this is supposed to be fixed in SDL 2.30.
I found that thing that I read: libsdl-org/SDL#1059 (comment)
But it's not a very nice fix. What you have to do is register some sort of callback, which is invoked during the drag operation (how often?). The main loop is still blocked.
Just updating our SDL didn't change anything.
There's this: https://wiki.libsdl.org/SDL3/README-main-functions, which I think is different from the callbacks in your link, but I haven't looked too closely.