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
SDL3 #8638
base: master
Are you sure you want to change the base?
SDL3 #8638
Conversation
This sounds interesting. Unfortunate that there's breaking changes for SDL_RWops. Might this help with SDL dependencies for things like #6826? |
The minimum requirement for that one is only 2.0.18, so this wouldn't really be relevant for that PR. |
It seems a bit odd to me that the script changes for example About "SDL_RWops": iirc the main reason why they were needed in the first place was to support non-utf-8 filepaths for windows 7 (especially for some bug in sdl-mixer that called different version of the windows api). Since it seemed like we mostly dropped support for windows 7, we can in the worst case also just skip the SDL_RWOps part and use the "normal" api the takes paths. |
The normal API being what's in |
The normal api being |
Ah, alright. Looks like the new ones are |
I guess that works too, i don't really see the advntage of that though. |
It has an argument for whether to close the file before it returns with the data, which is probably a good thing to do (and the current functions all set that argument to true). |
Got it compiling, though it's pretty broken at the moment too. |
5278808
to
8522b7d
Compare
Broken how? Things not displaying properly? |
It seems mostly input related actually - tooltips only display for a split second after your mouse moves rather than for the entire duration the mouse is hovering over the element, the help can be opened, but it's impossible to click anything in it other than the Close button, scrolling around the map doesn't work, etc. |
Got the input fixed. So yeah, at this point it seems like everything is working. Looked in-game, in the editor, went online, looked at the list of add-ons in the add-ons manager, and it all worked and looked like expected. |
I still think the change from |
Well, it'd just mean that the macro isn't defined, which by itself wouldn't cause a build failure. Trying to compile code for the wrong platform obviously might, but I don't have a macOS machine and CI can't run until there's actually an SDL3 release made available on the various platforms. |
Oh, also, there's this bit of Windows-specific code that I'm not sure what to do with: The non-Windows bit was removed since the function it calls is empty anyway, but on Windows it actually does something. |
Did you set-up SDL3 manually? Looks like my distribution doesn't package sdl3 yet. |
Yes - SDL3, SDL3_image, and SDL3_mixer. The latter two don't actually have any sort of release yet either - I just took the current code from their git repository. |
Some initial work seeing what moving to SDL3 will take. The first commit is from running the recommended
rename_*
scripts from https://github.com/libsdl-org/SDL/blob/main/docs/README-migration.md. Second commit is simpler things I was able to easily fix - main thing with this was more things are taking floats instead of ints as arguments.