SDL_MouseWheelEvent

Mouse wheel event structure (event.wheel.*)

\since This struct is available since SDL 3.2.0.

Members

Variables

direction
SDL_MouseWheelDirection direction;

< Set to one of the SDL_MOUSEWHEEL_* defines. When FLIPPED the values in X and Y will be opposite. Multiply by -1 to change them back

mouse_x
float mouse_x;

< X coordinate, relative to window

mouse_y
float mouse_y;

< Y coordinate, relative to window

reserved
Uint32 reserved;
Undocumented in source.
timestamp
Uint64 timestamp;

< In nanoseconds, populated using SDL_GetTicksNS()

type
SDL_EventType type;

< SDL_EVENT_MOUSE_WHEEL

which
SDL_MouseID which;

< The mouse instance id in relative mode or 0

windowID
SDL_WindowID windowID;

< The window with mouse focus, if any

x
float x;

< The amount scrolled horizontally, positive to the right and negative to the left

y
float y;

< The amount scrolled vertically, positive away from the user and negative toward the user

Meta