SDL
SDL copied to clipboard
Window resize issue
From Andreas Grabher: I think I found another issue. This time it is not a regression, as it also happens with earlier versions of SDL2. I first thought it was an issue within Previous but after checking everything seems to be fine there. Again this only happens when two windows are open. If Previous is paused, either by hitting ctrl+alt+p or by activating the main dialog using F12, resizing the main window causes distortion to the contents. This does not happen if only one window is open and also does not happen if Previous is running. While being paused, screen is only re-drawn once after resize, while when running screen is continuously re-drawn at about 60 Hz. When resizing while running distortion seems also to happen, but goes away due to continuous re-draw.
Resize triggers these functions to be executed once: SDL_UpdateTexture SDL_RenderClear SDL_RenderCopy SDL_RenderPresent
Code is here: https://sourceforge.net/p/previous/code/HEAD/tree/branches/branch_softfloat/src/fast_screen.c#l268
Resize triggers screen re-draw by setting blitUI to 1 (see line 465). Maybe you have an idea what might be wrong.
https://user-images.githubusercontent.com/2100061/165994784-24157a67-12c0-449c-a615-9bff08ca0d49.mov
I'll take this while I'm messing around with KDE anyhow. :)
Bumping to 2.26 since this isn't a regression and we're out of time.
I managed to get Previous built and running on a Mac, but I can't figure out how to coerce it to create a second window, which this reproduction case apparently requires; there's something about a NextDimension display (this app is a NeXT emulator), but I couldn't get it to work.
I guess we're bumping this one.
Go to Graphics options, add a Board and select for Displays „All“. It will then open a second window.
Thanks, @andreasgrabher, that got the second window created...but it doesn't reproduce for me here, even with SDL 2.0.20:
https://user-images.githubusercontent.com/673562/202361348-967ed3ee-abf5-4e4b-8d43-a299feb76234.mov
Maybe it's a hardware/driver difference; what kind of Mac is this running on? I'm on an M1 Mac Mini with macOS Monterey 12.6.
The problem occured on an iMac early 2009. I upgraded to a Mac mini M1 a few weeks ago and I can confirm that the problem is not present there. The window shrinking bug remains (#6243).
I saw this has been closed. I think the problem might still be present on older systems, althogh I can‘t test it anymore. But maybe the issue is not that important.
Am 17.11.2022 um 21:02 schrieb Ryan C. Gordon @.***>:
Closed #5588 as completed.
— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you were mentioned.
My take is it probably worked itself out on newer systems.
The oldest I have is a 2012 MacBook running Mojave, and for the sake of completeness, I'll try it there (but I'm not blocking the milestone for it either way).
I'm going to remove this from the 2.28.0 milestone, since a lot of window management stuff is getting reworked for SDL3, and we'll want to revisit it then.