We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 1095

Summary: SDL_MouseWheelEvent doesn't report small negative scroll events
Product: SDL Reporter: Vern Jensen <vern>
Component: eventsAssignee: Sam Lantinga <slouken>
Status: RESOLVED FIXED QA Contact: Sam Lantinga <slouken>
Severity: normal    
Priority: P2    
Version: HG 2.0   
Hardware: x86   
OS: Mac OS X 10.6   

Description Vern Jensen 2011-01-19 12:20:56 UTC
SDL_MouseWheelEvent reports positive (upward) scroll events just fine, even when the wheel is barely moved. However, when the wheel is moved downward, it must be moved with slightly more force. If moved too small an amount per movement, nothing will be reported. 

I can verify that this is an SDL problem, not a problem with my mouse's scroll wheel, as scrolling windows in the Finder or Safari work just fine, even when going downward at the smallest movement possible.

This is using a Logitech mouse, but that shouldn't affect anything.

My guess is it's some sort of rounding error that affects values between 0 and -1 being rounded down to 0 instead of "up" to -1. Hence why values between 0 and 1 get reported as 1 properly.
Comment 1 Sam Lantinga 2011-01-24 16:22:25 UTC
I believe this is fixed in the latest snapshot, can you retest?
http://www.libsdl.org/tmp/SDL-1.3.zip

Thanks!
Comment 2 Vern Jensen 2011-01-24 16:43:24 UTC
Yes, the scroll wheel now works perfectly!
Comment 3 Sam Lantinga 2011-01-24 17:48:55 UTC
Great! :)