Skip to main content
Retrieves the mouse properties of the device, such as its supported buttons, sample rate, and scroll wheels.

Syntax

Parameters

info   _Out_
Type: GameInputMouseInfo*
Pointer to a GameInputMouseInfo structure that receives the mouse properties of the device. If the device doesn’t support mouse input, every member of the structure is set to zero.

Return value

Type: bool true if the device supports mouse input and info was filled in; otherwise, false.

Remarks

The GetMouseInfo method copies the mouse properties of the device into the caller-provided structure. A device supports mouse input when the value returned by GetSupportedInput includes GameInputKindMouse. If the device doesn’t support mouse input, GetMouseInfo zero-initializes info and returns false. The supportedButtons member reports which GameInputMouseButtons the mouse has, and the hasWheelX and hasWheelY members report whether the mouse has horizontal and vertical scroll wheels. Mouse state is read from readings by using IGameInputReading::GetMouseState. The properties returned by this method are fixed for the lifetime of the device, so you can query them once (for example, when the device connects) and cache the result. The following example shows how to query the mouse properties of a device.
In GameInput v3 and earlier, this information was available from the mouseInfo member of the GameInputDeviceInfo structure returned by IGameInputDevice::GetDeviceInfo.

Requirements

Header: GameInput.h Library: gameinput.lib Supported platforms: Windows, XBOX One family consoles and XBOX Series consoles

See also

Overview of GameInput
GameInputMouseInfo
GetSupportedInput
GameInputKind
GameInputMouseButtons
IGameInputReading::GetMouseState
IGameInputDevice

Version History

Last modified on November 5, 2026