-
Notifications
You must be signed in to change notification settings - Fork 424
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
Update SDL3, bringing in support for Windows Ink pen input, and enable it on desktop platforms once again #6511
Conversation
I was going to come here to mention that I've only deprioritised and no longer looked at ppy/osu#28222 as we still reverted back to using SDL2, but now that it is being enabled back again in this PR, I've went back and tested to see how fullscreen is behaving currently. I was glad to see that apparently I cannot reproduce the yabai issue anymore, so then I wanted to confirm that on SDL's test projects but somehow I still encountered it there. I don't feel interested enough to care about why that happened but I'm giving this PR an i-dont-care approval from me with regards to having SDL3 enabled on macOS. If I get bothered enough, I'll report it out loud. |
used susko's instructions to test the newer sdl3 binary with frenzi's pr + this pr's sdl hints, and it does allow touch tapping with pen aim (with noticeably more latency than regular touch aim and tapping), but it breaks hover input completely (can only drag) (logs if ya need 'em) also summons the touch device mod when using the pen, which isn't quite expected either |
The logs confirm you're using the latest SDL3 👍 When you say that hover is broken, is it broken only in gameplay, or also in menus? If it's only gameplay, try applying this patch and see if the hovering playstyle works. Which device are you using to test this? When you say there's noticeable latency, do you think that is display latency or pen input latency? (I understand that it might be hard to tell.) Could be that there is an overlay display when using the pen, kicking osu! out of exclusive fullscreen. In my testing, I noticed a microstutter when the pen entered or left the hover range (indicative of fullscreen overlay shenanigans), but that might be due to Wacom drivers. |
@Walavouchey this branch ppy/osu@master...Susko3:osu:enable-mouse-hover-touch-click-play-style should work, with and without frenzi's PR. It was build with hovering playstyle in mind, but pressing the pen down shouldn't be too broken. Please give it a test. |
Surface Pro 8
everywhere (immediately noticeable when opening the game and using the pen)
it's not like the framerate suffers or that there are microstutters (no spikes on the frame graph either). pen taps, touch taps, and touch taps while dragging with a finger are fine with no perceived latency, but specifically the touch taps while dragging the pen register later (i get around +50 ms hit error).
no such stutters that i notice. i think windows vs fullscreen might make a few ms difference on my device but it's harder to notice than the latency i'm describing
all with new sdl3 binary
that branch logs-without-modified-framework.zip:
the patch you linked instead of that branch logs-with-frenzy-framework-susko-patch-2.zip:
the patch you linked instead of that branch logs-without-modified-framework-susko-patch-2.zip
in all these cases, TD mod is on while dragging pen and off when hovering |
New SDL3-CS package: https://www.nuget.org/packages/ppy.SDL3-CS/2025.127.0 |
Looks good on my part. Further testing can be done based on this PR, to reduce possible error when setting up the environment. For example, @Walavouchey please give it a test again, this PR + ppy/osu@master...Susko3:osu:enable-mouse-hover-touch-click-play-style, no additional mangling with Also useful is to enable SDL event logging, to check if we're receiving correct events: diff --git a/osu.Framework/Platform/SDL3/SDL3Window.cs b/osu.Framework/Platform/SDL3/SDL3Window.cs
index 8f7783571..70a895b28 100644
--- a/osu.Framework/Platform/SDL3/SDL3Window.cs
+++ b/osu.Framework/Platform/SDL3/SDL3Window.cs
@@ -213,6 +213,7 @@ public virtual void Create()
SDL_SetHint(SDL_HINT_PEN_TOUCH_EVENTS, "0"u8);
SDL_SetHint(SDL_HINT_PEN_MOUSE_EVENTS, "0"u8);
SDL_SetHint(SDL_HINT_IME_IMPLEMENTED_UI, "composition"u8);
+ SDL_SetHint(SDL_HINT_EVENT_LOGGING, "2"u8);
SDLWindowHandle = SDL_CreateWindow(title, Size.Width, Size.Height, flags);
|
logs .osr replay enabled sdl logs
|
Does the above mean this PR is ready to review? |
Yep, ready for review. |
Let's get this in and give ample time for devs to dogfood the change before we roll out the next major release. |
Depends on:
This PR will make SDL3 the default option, see ppy/osu#30641 (comment).
OSU_SDL3=0
can be set to use SDL2.Issues to check after this SDL3 update propagates to osu!: