Mouse motion event structure (event.motion.*)
Defined in <SDL3/SDL_events.h>
typedef struct SDL_MouseMotionEvent
{/**< SDL_EVENT_MOUSE_MOTION */
SDL_EventType type;
Uint32 reserved;/**< In nanoseconds, populated using SDL_GetTicksNS() */
Uint64 timestamp; /**< The window with mouse focus, if any */
SDL_WindowID windowID; /**< The mouse instance id or SDL_TOUCH_MOUSEID */
SDL_MouseID which; /**< The current button state */
SDL_MouseButtonFlags state; float x; /**< X coordinate, relative to window */
float y; /**< Y coordinate, relative to window */
float xrel; /**< The relative motion in the X direction */
float yrel; /**< The relative motion in the Y direction */
} SDL_MouseMotionEvent;
This struct is available since SDL 3.1.3.