-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
On emscripten, is delta-x of mousewheel event scaled correctly? #10454
Comments
We probably need to divide the values coming in by 120. Take a look at the WHEEL_DELTA code in SDL_windowsevents.c for reference. |
I'll take a look at this. |
Actually it turns out 100 is the right value for the browser (rather, it's one of three possible units of measurement, and we handle them all). But we were only adjusting the Y value and not the X value, which is why Dear Imgui has a hardcoded CC @ocornut: that extra division on Emscripten can be removed now for SDL3 (and the fix has been applied to SDL2, too, and will be in the 2.30.9 release). |
…iding by 100.0f on Emscripten. (#4019, #6096, #1463) Ref libsdl-org/SDL#10454 (comment)
Thank you Sam, pushed ocornut/imgui@06092a9 for Dear ImGui. |
Whilst looking at imgui's SDL support code, I noticed it scales the wheel delta x of a mouse wheel event by around 100.
link to code
Is the need for this extra scale factor expected?
The text was updated successfully, but these errors were encountered: