> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# GameInput

> GameInput

# GameInput

GameInput APIs are used to capture human input from a wide range of devices, such as game controllers, flight sticks, racing wheels, and touch input.

<Note>This page documents the current (latest) GameInput API. Version history for each member is noted in the individual reference pages. Members that existed only in older API versions are listed in the [Removed Members](#removed-members) section below. Note newer runtimes for the API support all available versions of the API, so removed members can still be used with the headers for olders versions.</Note>

## Interfaces

| Interface                                                                                                                          | Description                                                                                |
| ---------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------ |
| [IGameInputDevice](/reference/input/gameinput/interfaces/igameinputdevice/igameinputdevice)                                        | Defines an input device.                                                                   |
| [IGameInputDispatcher](/reference/input/gameinput/interfaces/IGameInputDispatcher/igameinputdispatcher)                            | Provides manual control over scheduling the background tasks managed by the GameInput API. |
| [IGameInputForceFeedbackEffect](/reference/input/gameinput/interfaces/igameinputforcefeedbackeffect/igameinputforcefeedbackeffect) | Describes a force feedback effect on a compatible input device.                            |
| [IGameInputMapper](/reference/input/gameinput/interfaces/igameinputmapper/igameinputmapper)                                        | Provides information on how GameInput maps a device.                                       |
| [IGameInputRawDeviceReport](/reference/input/gameinput/interfaces/igameinputrawdevicereport/igameinputrawdevicereport)             | Represents a raw byte buffer passed to or from an input device.                            |
| [IGameInputReading](/reference/input/gameinput/interfaces/igameinputreading/igameinputreading)                                     | Contains the data for a single input update.                                               |
| [IGameInput](/reference/input/gameinput/interfaces/igameinput/igameinput)                                                          | A per-process singleton that provides access to the device input stream.                   |

## Functions

| Function                                                                                                | Description                                                            |
| ------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------- |
| [GameInputCreate](/reference/input/gameinput/functions/gameinputcreate)                                 | Retrieves an instance of the IGameInput interface.                     |
| [GameInputDeviceCallback](/reference/input/gameinput/functions/gameinputdevicecallback)                 | Defines a callback for device connection and disconnection events.     |
| [GameInputKeyboardLayoutCallback](/reference/input/gameinput/functions/gameinputkeyboardlayoutcallback) | Defines a callback for keyboard layout change events.                  |
| [GameInputReadingCallback](/reference/input/gameinput/functions/gameinputreadingcallback)               | Defines a callback for new reading arrival events.                     |
| [GameInputSystemButtonCallback](/reference/input/gameinput/functions/gameinputsystembuttoncallback)     | Defines a callback for Guide or Share button press and release events. |

## Structures

| Structure                                                                                                         | Description                                                            |
| ----------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------- |
| [GameInputArcadeStickInfo](/reference/input/gameinput/structs/gameinputarcadestickinfo)                           | Details the characteristics of an arcade stick.                        |
| [GameInputArcadeStickState](/reference/input/gameinput/structs/gameinputarcadestickstate)                         | Provides the current status of an arcade stick.                        |
| [GameInputAxisMapping](/reference/input/gameinput/structs/gameinputaxismapping)                                   | Describes how an axis maps to the controller.                          |
| [GameInputButtonMapping](/reference/input/gameinput/structs/gameinputbuttonmapping)                               | Describes how a button maps to the controller.                         |
| [GameInputControllerInfo](/reference/input/gameinput/structs/gameinputcontrollerinfo)                             | Details the characteristics of a controller.                           |
| [GameInputControllerSwitchInfo](/reference/input/gameinput/structs/gameinputcontrollerswitchinfo)                 | Specifies a switch on an input device.                                 |
| [GameInputDeviceInfo](/reference/input/gameinput/structs/gameinputdeviceinfo)                                     | Contains comprehensive information about an input device.              |
| [GameInputFlightStickInfo](/reference/input/gameinput/structs/gameinputflightstickinfo)                           | Details the characteristics of a flight stick.                         |
| [GameInputFlightStickState](/reference/input/gameinput/structs/gameinputflightstickstate)                         | Provides the current status of a flight stick.                         |
| [GameInputForceFeedbackConditionParams](/reference/input/gameinput/structs/gameinputforcefeedbackconditionparams) | Defines certain physical aspects of a force-feedback effect.           |
| [GameInputForceFeedbackConstantParams](/reference/input/gameinput/structs/gameinputforcefeedbackconstantparams)   | Defines a constant physical aspect of a force-feedback effect.         |
| [GameInputForceFeedbackEnvelope](/reference/input/gameinput/structs/gameinputforcefeedbackenvelope)               | Defines an envelope that modifies a force-feedback effect.             |
| [GameInputForceFeedbackMagnitude](/reference/input/gameinput/structs/gameinputforcefeedbackmagnitude)             | Defines the magnitude of the force exerted by a force-feedback effect. |
| [GameInputForceFeedbackMotorInfo](/reference/input/gameinput/structs/gameinputforcefeedbackmotorinfo)             | Provides information about the force-feedback motor.                   |
| [GameInputForceFeedbackParams](/reference/input/gameinput/structs/gameinputforcefeedbackparams)                   | Defines the API-supported attributes of a force-feedback effect.       |
| [GameInputForceFeedbackPeriodicParams](/reference/input/gameinput/structs/gameinputforcefeedbackperiodicparams)   | Defines the parameters for a periodic force-feedback effect.           |
| [GameInputForceFeedbackRampParams](/reference/input/gameinput/structs/gameinputforcefeedbackrampparams)           | Defines the parameters for a ramp force-feedback effect.               |
| [GameInputGamepadInfo](/reference/input/gameinput/structs/gameinputgamepadinfo)                                   | Details the characteristics of a gamepad.                              |
| [GameInputGamepadState](/reference/input/gameinput/structs/gameinputgamepadstate)                                 | Provides the current status of a gamepad input device.                 |
| [GameInputHapticInfo](/reference/input/gameinput/structs/gameinputhapticinfo)                                     | Details the characteristics of a haptic feedback motor.                |
| [GameInputKeyState](/reference/input/gameinput/structs/gameinputkeystate)                                         | Provides the current state of a key on a keyboard.                     |
| [GameInputKeyboardInfo](/reference/input/gameinput/structs/gameinputkeyboardinfo)                                 | Details the characteristics of a keyboard.                             |
| [GameInputMouseInfo](/reference/input/gameinput/structs/gameinputmouseinfo)                                       | Details the characteristics of a mouse.                                |
| [GameInputMouseState](/reference/input/gameinput/structs/gameinputmousestate)                                     | Provides the current status of a mouse.                                |
| [GameInputRacingWheelInfo](/reference/input/gameinput/structs/gameinputracingwheelinfo)                           | Details the characteristics of a racing wheel.                         |
| [GameInputRacingWheelState](/reference/input/gameinput/structs/gameinputracingwheelstate)                         | Provides the current status of a racing wheel.                         |
| [GameInputRawDeviceReportInfo](/reference/input/gameinput/structs/gameinputrawdevicereportinfo)                   | Describes a raw device report.                                         |
| [GameInputRumbleParams](/reference/input/gameinput/structs/gameinputrumbleparams)                                 | Describes a rumble effect produced by a controller.                    |
| [GameInputSensorsInfo](/reference/input/gameinput/structs/gameinputsensorsinfo)                                   | Details the characteristics of the available sensors.                  |
| [GameInputSensorsState](/reference/input/gameinput/structs/gameinputsensorsstate)                                 | Provides the current status of a device's sensors.                     |
| [GameInputUsage](/reference/input/gameinput/structs/gameinputusage)                                               | Describes a specific HID usage.                                        |
| [GameInputVersion](/reference/input/gameinput/structs/gameinputversion)                                           | Describes a four-part version number.                                  |

## Enumerations

| Enumeration                                                                                           | Description                                                                                     |
| ----------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- |
| [GameInputArcadeStickButtons](/reference/input/gameinput/enums/gameinputarcadestickbuttons)           | Enumerates inputs from an arcade stick.                                                         |
| [GameInputDeviceFamily](/reference/input/gameinput/enums/gameinputdevicefamily)                       | Enumerates families of input devices.                                                           |
| [GameInputDeviceStatus](/reference/input/gameinput/enums/gameinputdevicestatus)                       | Enumerates the states that an input device can be in.                                           |
| [GameInputElementKind](/reference/input/gameinput/enums/gameinputelementkind)                         | Enumerates the element kind of a given input.                                                   |
| [GameInputEnumerationKind](/reference/input/gameinput/enums/gameinputenumerationkind)                 | Enumerates types of behavior for enumerating input devices.                                     |
| [GameInputFeedbackAxes](/reference/input/gameinput/enums/gameinputfeedbackaxes)                       | Enumerates direction types of force feedback motors available on an input device.               |
| [GameInputFeedbackEffectState](/reference/input/gameinput/enums/gameinputfeedbackeffectstate)         | Enumerates states of a force feedback effect.                                                   |
| [GameInputFlightStickAxes](/reference/input/gameinput/enums/gameinputflightstickaxes)                 | Enumerates flight stick axes.                                                                   |
| [GameInputFlightStickButtons](/reference/input/gameinput/enums/gameinputflightstickbuttons)           | Enumerates flight stick buttons.                                                                |
| [GameInputFocusPolicy](/reference/input/gameinput/enums/gameinputfocuspolicy)                         | Enumerates focus policies for an input device.                                                  |
| [GameInputForceFeedbackEffectKind](/reference/input/gameinput/enums/gameinputforcefeedbackeffectkind) | Enumerates types of magnitude over time effects that can be applied to a force feedback effect. |
| [GameInputGamepadAxes](/reference/input/gameinput/enums/gameinputgamepadaxes)                         | Enumerates gamepad axes.                                                                        |
| [GameInputGamepadButtons](/reference/input/gameinput/enums/gameinputgamepadbuttons)                   | Enumerates gamepad buttons, including the directional pad (D-pad).                              |
| [GameInputKeyboardKind](/reference/input/gameinput/enums/gameinputkeyboardkind)                       | Enumerates keyboard types by key layout.                                                        |
| [GameInputKind](/reference/input/gameinput/enums/gameinputkind)                                       | Enumerates valid GameInput device types.                                                        |
| [GameInputLabel](/reference/input/gameinput/enums/gameinputlabel)                                     | Enumerates supported button labels.                                                             |
| [GameInputMouseButtons](/reference/input/gameinput/enums/gameinputmousebuttons)                       | Enumerates mouse buttons.                                                                       |
| [GameInputMousePositions](/reference/input/gameinput/enums/gameInputmousepositions)                   | Enumerates mouse positioning modes.                                                             |
| [GameInputRacingWheelAxes](/reference/input/gameinput/enums/gameinputracingwheelaxes)                 | Enumerates axes on a racing wheel.                                                              |
| [GameInputRacingWheelButtons](/reference/input/gameinput/enums/gameinputracingwheelbuttons)           | Enumerates buttons on a racing wheel.                                                           |
| [GameInputRawDeviceReportKind](/reference/input/gameinput/enums/gameinputrawdevicereportkind)         | Enumerates kinds of raw device reports.                                                         |
| [GameInputRumbleMotors](/reference/input/gameinput/enums/gameinputrumblemotors)                       | Enumerates the API supported rumble motors for an input device.                                 |
| [GameInputSensorAccuracy](/reference/input/gameinput/enums/gameinputsensoraccuracy)                   | Enumerates levels of accuracy for sensors.                                                      |
| [GameInputSensorsKind](/reference/input/gameinput/enums/gameinputsensorskind)                         | Enumerates valid GameInput sensor types.                                                        |
| [GameInputSwitchKind](/reference/input/gameinput/enums/gameinputswitchkind)                           | Enumerates types of switches supported by an input device.                                      |
| [GameInputSwitchPosition](/reference/input/gameinput/enums/gameinputswitchposition)                   | Enumerates positions of a switch on an input device.                                            |
| [GameInputSystemButtons](/reference/input/gameinput/enums/gameinputsystembuttons)                     | Enumerates buttons used for controlling the system.                                             |

## Removed Members

The following members were present in older API versions but have been removed from the current API. For full documentation on each removed member, see [Deprecated GameInput API members](/reference/input/gameinput/deprecated/gameinput_deprecated_members).

### Removed Interfaces

No interfaces have been permanently removed. `IGameInputRawDeviceReport` was absent in v1 and v2 but has been re-introduced in the current API.

### Removed Functions

| Function                                                                                                     | Last version | Description                                                                                  |
| ------------------------------------------------------------------------------------------------------------ | ------------ | -------------------------------------------------------------------------------------------- |
| [GameInputGuideButtonCallback](/reference/input/gameinput/deprecated/functions/gameinputguidebuttoncallback) | v0           | Title-defined callback for Guide button events. Replaced by `GameInputSystemButtonCallback`. |

### Removed Structures

| Structure                                                                                                                  | Last version | Description                                                                               |
| -------------------------------------------------------------------------------------------------------------------------- | ------------ | ----------------------------------------------------------------------------------------- |
| [GameInputBatteryState](/reference/input/gameinput/deprecated/structs/gameinputbatterystate)                               | v0           | Described the battery state of an input device.                                           |
| [GameInputControllerAxisInfo](/reference/input/gameinput/deprecated/structs/gameinputcontrolleraxisinfo)                   | v2           | Described an axis on an input device. Superseded by fields in `GameInputControllerInfo`.  |
| [GameInputControllerButtonInfo](/reference/input/gameinput/deprecated/structs/gameinputcontrollerbuttoninfo)               | v2           | Described a button on an input device. Superseded by fields in `GameInputControllerInfo`. |
| [GameInputHapticFeedbackMotorInfo](/reference/input/gameinput/deprecated/structs/gameinputhapticfeedbackmotorinfo)         | v0           | Described a haptic feedback motor. Superseded by `GameInputHapticInfo`.                   |
| [GameInputHapticFeedbackParams](/reference/input/gameinput/deprecated/structs/gameinputhapticfeedbackparams)               | v0           | Described a haptic feedback effect.                                                       |
| [GameInputHapticWaveformInfo](/reference/input/gameinput/deprecated/structs/gameinputhapticwaveforminfo)                   | v0           | Described characteristics of a haptic feedback effect.                                    |
| [GameInputMotionInfo](/reference/input/gameinput/deprecated/structs/gameinputmotioninfo)                                   | v0           | Described measurable properties for a motion-enabled input device.                        |
| [GameInputMotionState](/reference/input/gameinput/deprecated/structs/gameinputmotionstate)                                 | v0           | Described the state of motion input.                                                      |
| [GameInputRawDeviceItemCollectionInfo](/reference/input/gameinput/deprecated/structs/gameinputrawdeviceitemcollectioninfo) | v0           | Described a collection of raw device items.                                               |
| [GameInputRawDeviceReportItemInfo](/reference/input/gameinput/deprecated/structs/gameinputrawdevicereportiteminfo)         | v0           | Described a raw device report item.                                                       |
| [GameInputString](/reference/input/gameinput/deprecated/structs/gameinputstring)                                           | v0           | Described a string containing information about an input device.                          |
| [GameInputTouchSensorInfo](/reference/input/gameinput/deprecated/structs/gameinputtouchsensorinfo)                         | v0           | Described a touch sensor for an input device.                                             |
| [GameInputTouchState](/reference/input/gameinput/deprecated/structs/gameinputtouchstate)                                   | v0           | Described the state of a touch input device.                                              |
| [GameInputUiNavigationInfo](/reference/input/gameinput/deprecated/structs/gameinputuinavigationinfo)                       | v2           | Specified the labels of navigation buttons in the UI.                                     |
| [GameInputUiNavigationState](/reference/input/gameinput/deprecated/structs/gameinputuinavigationstate)                     | v2           | Provided the current status of UI navigation input.                                       |

### Removed Enumerations

| Enumeration                                                                                                              | Last version | Description                                             |
| ------------------------------------------------------------------------------------------------------------------------ | ------------ | ------------------------------------------------------- |
| [GameInputBatteryStatus](/reference/input/gameinput/deprecated/enums/gameinputbatterystatus)                             | v0           | Enumerated battery states for an input device.          |
| [GameInputDeviceCapabilities](/reference/input/gameinput/deprecated/enums/gameinputdevicecapabilities)                   | v0           | Enumerated certain capabilities of an input device.     |
| [GameInputLocation](/reference/input/gameinput/deprecated/enums/gameinputlocation)                                       | v0           | Enumerated the parts of an input device.                |
| [GameInputMotionAccuracy](/reference/input/gameinput/deprecated/enums/gameinputmotionaccuracy)                           | v0           | Enumerated levels of accuracy for motion sensors.       |
| [GameInputRawDeviceItemCollectionKind](/reference/input/gameinput/deprecated/enums/gameinputrawdeviceitemcollectionkind) | v0           | Enumerated types of collections of raw device items.    |
| [GameInputRawDevicePhysicalUnitKind](/reference/input/gameinput/deprecated/enums/gameinputrawdevicephysicalunitkind)     | v0           | Enumerated physical units associated with device input. |
| [GameInputRawDeviceReportItemFlags](/reference/input/gameinput/deprecated/enums/gameinputrawdevicereportitemflags)       | v0           | Enumerated types of raw device-report items.            |
| [GameInputTouchShape](/reference/input/gameinput/deprecated/enums/gameinputtouchshape)                                   | v0           | Enumerated shapes of a touch sensor.                    |
| [GameInputUiNavigationButtons](/reference/input/gameinput/deprecated/enums/gameinputuinavigationbuttons)                 | v2           | Enumerated UI navigation buttons.                       |

## Version History

| Version | Changes                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **v3**  | Added `IGameInputMapper` interface. Re-introduced `IGameInputRawDeviceReport` interface (was absent in v1/v2). Added `GameInputAxisMapping`, `GameInputButtonMapping`, `GameInputControllerInfo`, `GameInputHapticInfo` structs. Re-introduced `GameInputRawDeviceReportInfo` struct and `GameInputRawDeviceReportKind` enum (absent in v1/v2). Re-introduced `GameInputVersion` struct (absent in v1/v2). Added `GameInputElementKind`, `GameInputFlightStickAxes`, `GameInputGamepadAxes`, `GameInputRacingWheelAxes` enums. Removed `GameInputControllerAxisInfo`, `GameInputControllerButtonInfo`, `GameInputUiNavigationInfo`, `GameInputUiNavigationState` structs. Removed `GameInputUiNavigationButtons` enum. |
| **v2**  | Added `GameInputSensorsInfo`, `GameInputSensorsState` structs. Added `GameInputSensorsKind`, `GameInputSensorAccuracy` enums. Added `IGameInputDevice::DirectInputEscape`, `IGameInputDevice::GetHapticInfo`. Added `IGameInputReading::GetSensorsState`. Re-introduced `GameInputVersion` struct (was absent in v1).                                                                                                                                                                                                                                                                                                                                                                                                  |
| **v1**  | Removed `IGameInputRawDeviceReport` interface, `GameInputRawDeviceReportInfo` struct, `GameInputRawDeviceReportKind` enum. Removed `GameInputVersion` struct. Added `GameInputMousePositions` enum. Removed v0-only unimplemented haptics, motion, and touch types (`GameInputBatteryState`, `GameInputHapticFeedbackMotorInfo`, `GameInputHapticFeedbackParams`, `GameInputHapticWaveformInfo`, `GameInputMotionInfo`, `GameInputMotionState`, `GameInputTouchSensorInfo`, `GameInputTouchState`, `GameInputString`, `GameInputRawDeviceItemCollectionInfo`, `GameInputRawDeviceReportItemInfo`).                                                                                                                     |
| **v0**  | Introduced.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |

## Conceptual documentation

* [Input overview](/build/core-features/common/input/overviews/input-overview)
* [Input fundamentals](/build/core-features/common/input/overviews/input-fundamentals)
* [Input devices](/build/core-features/common/input/overviews/input-devices)

## See also

[Input API reference](/reference/input/gc-reference-input-toc)


## Related topics

- [Porting from Windows.XBOX.Input to GameInput](/build/core-features/common/input/porting/input-porting-wxi.md)
- [Input](/build/core-features/common/input/gc-input-toc.md)
- [Overview of GameInput](/build/core-features/common/input/overviews/input-overview.md)
- [GameInput readings](/build/core-features/common/input/overviews/input-readings.md)
- [GameInput callbacks](/build/core-features/common/input/advanced/input-callbacks.md)
