Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Enumerates the groups of lamps on an input device that can be lit by GameInput.
Syntax
enum GameInputLightingGroups
{
GameInputLightingGroupUnknown = 0x00000000,
GameInputLightingGroupLeftThumbstick = 0x00000001,
GameInputLightingGroupRightThumbstick = 0x00000002,
GameInputLightingGroupDPad = 0x00000004,
GameInputLightingGroupFaceButtons = 0x00000008,
GameInputLightingGroupCenterLight = 0x00000010,
GameInputLightingGroupKeyboardKey = 0x00000020,
GameInputLightingGroupLeftHeadset = 0x00000040,
GameInputLightingGroupRightHeadset = 0x00000080,
GameInputLightingGroupAll = 0xFFFFFFFF,
};
const uint32_t GAMEINPUT_LIGHTING_GROUP_ORDER_INDEX_ALL = 0xFFFFFFFF;
Constants
| Constant | Description |
|---|---|
| GameInputLightingGroupUnknown | Lamps that aren't assigned to any named group. |
| GameInputLightingGroupLeftThumbstick | Lamps around or in the left thumbstick. |
| GameInputLightingGroupRightThumbstick | Lamps around or in the right thumbstick. |
| GameInputLightingGroupDPad | Lamps on or around the directional pad. |
| GameInputLightingGroupFaceButtons | Lamps on or around the face buttons. |
| GameInputLightingGroupCenterLight | Lamps in the center of the device, such as a light bar. |
| GameInputLightingGroupKeyboardKey | Per-key lamps on a keyboard. |
| GameInputLightingGroupLeftHeadset | Lamps on the left side of a headset. |
| GameInputLightingGroupRightHeadset | Lamps on the right side of a headset. |
| GameInputLightingGroupAll | All lamps on the device, including lamps that aren't assigned to a named group. |
| GAMEINPUT_LIGHTING_GROUP_ORDER_INDEX_ALL | Order index that selects every lamp in the selected groups. This is the default value of the groupOrderIndex parameter of IGameInputDevice::SetLightingColor. |
Remarks
This enumeration is a set of flags. Named group values may be combined to select the lamps in several groups at once.
IGameInputDevice::GetSupportedLightingGroups returns the named groups in which the device has lamps. It never reports GameInputLightingGroupUnknown, and it returns GameInputLightingGroupUnknown (0) if the device has no lighting that GameInput can control. IGameInputDevice::GetSupportedLightingGroupSize returns the number of lamps in a selection:
GameInputLightingGroupAllselects every lamp on the device.GameInputLightingGroupUnknownselects the lamps that aren't assigned to any named group.- A combination of named groups selects the lamps in all of those groups.
The groupOrderIndex parameter of IGameInputDevice::SetLightingColor selects a single lamp within a selection:
GAMEINPUT_LIGHTING_GROUP_ORDER_INDEX_ALLselects every lamp in the selection.- For
GameInputLightingGroupKeyboardKey, the index is a Set 1 keyboard scan code that identifies the key whose lamp is selected: 0x01 to 0x7F, an extended scan code from 0xE001 to 0xE07F, or 0xE11D. This is the same scan code format that's reported in thescanCodemember of GameInputKeyState. - For other selections, the index is an ordinal that must be less than the value returned by
GetSupportedLightingGroupSizefor the same selection.
A selection that combines GameInputLightingGroupKeyboardKey with other named groups can only use GAMEINPUT_LIGHTING_GROUP_ORDER_INDEX_ALL. Every named group in a selection must be supported by the device. Selections that the device can't satisfy are ignored.
Devices that have lamps that GameInput can control also report GameInputKindLighting in IGameInputDevice::GetSupportedInput. Lighting is output only, so readings never contain lighting data.
Note
Lighting support varies by device and platform. GameInput currently supports Windows Dynamic Lighting (LampArray) devices and the DualSense controller light bar.
Requirements
Header: GameInput.h
Supported platforms: Windows, XBOX One family consoles and XBOX Series consoles
See also
Overview of GameInput
GameInput
GameInputColor
IGameInputDevice::GetSupportedLightingGroups
IGameInputDevice::GetSupportedLightingGroupSize
IGameInputDevice::SetLightingColor
IGameInputDevice::ApplyLightingColors
Version History
| Version | Changes |
|---|---|
| v4 | Introduced. |