Skip to content

Update SDL2 port #20268

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

Closed
wants to merge 2 commits into from
Closed

Update SDL2 port #20268

wants to merge 2 commits into from

Conversation

sbc100
Copy link
Collaborator

@sbc100 sbc100 commented Sep 15, 2023

No description provided.

@sbc100
Copy link
Collaborator Author

sbc100 commented Feb 13, 2024

@Daft-Freak

@sbc100 sbc100 changed the title [WIP] Update SDL2 port Update SDL2 port Feb 13, 2024
@sbc100 sbc100 requested a review from kripken February 13, 2024 21:53
@sbc100
Copy link
Collaborator Author

sbc100 commented Feb 13, 2024

I'm seeing 7 local test failures with this update:

test_sdl2_mixer_wav
test_sdl2_mixer_music
test_sdl2_gl_frames_swap
test_sdl2_pumpevents
test_sdl2_canvas_proxy
test_sdl2_key
test_sdl2_mouse

Lets see if the same failures show up on CI. @Daft-Freak any ideas?

sbc100 added a commit to sbc100/emscripten that referenced this pull request Feb 14, 2024
This is just a minor update to see if its any better than emscripten-core#20268
@sbc100
Copy link
Collaborator Author

sbc100 commented Feb 14, 2024

A smaller update seems to only have issues with mouse and keyboard events: #21337

sbc100 added a commit to sbc100/emscripten that referenced this pull request Feb 14, 2024
This is just a minor update to see if its any better than emscripten-core#20268
sbc100 added a commit to sbc100/emscripten that referenced this pull request Feb 14, 2024
This is just a minor update to see if its any better than emscripten-core#20268
sbc100 added a commit to sbc100/emscripten that referenced this pull request Feb 14, 2024
This is just a minor update to see if its any better than emscripten-core#20268
@Daft-Freak
Copy link
Collaborator

Looks like we need to build joystick/SDL_steam_virtual_gamepad.c from the CI results.

@Daft-Freak
Copy link
Collaborator

Daft-Freak commented Feb 14, 2024

🤔 test_sdl2_canvas_proxy and test_sdl2_gl_frames_swap are both because SDL tries to compile a shader using GL_OES_EGL_image_external then checks the compile status, which returns false and asserts because of --proxy-to-worker.

Edit: the change from previous versions being that the shaders are compiled at init instead of on-demand, I think.

@sbc100
Copy link
Collaborator Author

sbc100 commented Feb 14, 2024

🤔 test_sdl2_canvas_proxy and test_sdl2_gl_frames_swap are both because SDL tries to compile a shader using GL_OES_EGL_image_external then checks the compile status, which returns false and asserts because of --proxy-to-worker.

Edit: the change from previous versions being that the shaders are compiled at init instead of on-demand, I think.

Oh thats good to know, thanks for the tip.

I'm going to try to land #21337 first and then try this one again.

sbc100 added a commit to sbc100/emscripten that referenced this pull request Feb 14, 2024
This is just a minor update to see if its any better than emscripten-core#20268
sbc100 added a commit to sbc100/emscripten that referenced this pull request Feb 14, 2024
This is just a minor update to see if its any better than emscripten-core#20268
Also remove the no-longer-needed `linker_setup` function.  SDL2 now
uses EM_JS_DEPS to achieve this.

Followup to #21337
@ericoporto
Copy link
Contributor

I see you are updating to 2.30.0 release, I advise updating to 2.28.5 instead, as 2.30.0 still has some issues to be ironed out.

@sbc100
Copy link
Collaborator Author

sbc100 commented Feb 24, 2024

I see you are updating to 2.30.0 release, I advise updating to 2.28.5 instead, as 2.30.0 still has some issues to be ironed out.

OK, I'll close this one.

Do you mean emscripten-specific issue? Or is it just not ready yet? Was it not released already?

@sbc100 sbc100 closed this Feb 24, 2024
@sbc100 sbc100 deleted the update_sdl2 branch February 24, 2024 20:10
@ericoporto
Copy link
Contributor

This is weird, I swear I saw an issue in the tracker about Fullscreen not working but it appears it's only in SDL3.

In any case I really need libsdl-org/SDL#9127 fixed (hopefully in 2.30.1) because otherwise we are having problems with audio in SDL2, but I don't know if that issue in particular affects the Emscripten builds.

@connorjclark
Copy link
Contributor

It looks like that issue is about a pre built dll. That would not effect emscripten.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants