SharpDX.RawInput The assembly provides managed RawInput API. ms645536 RawInput RawInput Provides access to RawInput methods. Gets the devices. Registers the devices that supply the raw input data. The usage page. The usage id. The flags. Registers the devices that supply the raw input data. The usage page. The usage id. The flags. The target. if set to true register message filter to Application.AddMessageFilter. Handles a RawInput message manually. A pointer to a RawInput message. This method can be used directly when handling RawInput messages from non-WinForms application. Occurs when [keyboard input]. Occurs when [mouse input]. Occurs when [raw input]. Internal RawInput message filtering WM_INPUT Defines the raw input data coming from any device. RID_DEVICE_INFO Initializes a new instance of the class. Initializes a new instance of the class. The raw device info. Name of the device. The device handle. Converts the specified raw device info to the . The raw device info. Name of the device. The device handle. Gets or sets the name of the device. The name of the device. Gets or sets the type of the device. The type of the device. Gets or sets the handle. The handle. No documentation. RAW_DEVICE_FLAGS RAW_DEVICE_FLAGS No documentation. RIDEV_REMOVE RIDEV_REMOVE No documentation. RIDEV_EXCLUDE RIDEV_EXCLUDE No documentation. RIDEV_PAGEONLY RIDEV_PAGEONLY No documentation. RIDEV_NOLEGACY RIDEV_NOLEGACY No documentation. RIDEV_INPUTSINK RIDEV_INPUTSINK No documentation. RIDEV_CAPTUREMOUSE RIDEV_CAPTUREMOUSE No documentation. RIDEV_NOHOTKEYS RIDEV_NOHOTKEYS No documentation. RIDEV_APPKEYS RIDEV_APPKEYS No documentation. RIDEV_EXINPUTSINK RIDEV_EXINPUTSINK No documentation. RIDEV_DEVNOTIFY RIDEV_DEVNOTIFY None. None None No documentation. RAW_DEVICE_TYPE RAW_DEVICE_TYPE No documentation. RIM_TYPEMOUSE RIM_TYPEMOUSE No documentation. RIM_TYPEKEYBOARD RIM_TYPEKEYBOARD No documentation. RIM_TYPEHID RIM_TYPEHID No documentation. RAW_KEY_STATE RAW_KEY_STATE No documentation. WM_VKEYTOITEM WM_VKEYTOITEM No documentation. WM_SETHOTKEY WM_SETHOTKEY No documentation. WM_GETHOTKEY WM_GETHOTKEY No documentation. WM_KEYFIRST WM_KEYFIRST No documentation. WM_KEYDOWN WM_KEYDOWN No documentation. WM_KEYUP WM_KEYUP No documentation. WM_SYSKEYDOWN WM_SYSKEYDOWN No documentation. WM_SYSKEYUP WM_SYSKEYUP No documentation. WM_KEYLAST WM_KEYLAST No documentation. WM_IME_KEYLAST WM_IME_KEYLAST No documentation. WM_IME_KEYDOWN WM_IME_KEYDOWN No documentation. WM_IME_KEYUP WM_IME_KEYUP No documentation. WM_HOTKEY WM_HOTKEY No documentation. RAW_MOUSE_BUTTON_FLAGS RAW_MOUSE_BUTTON_FLAGS No documentation. RI_MOUSE_LEFT_BUTTON_DOWN RI_MOUSE_LEFT_BUTTON_DOWN No documentation. RI_MOUSE_LEFT_BUTTON_UP RI_MOUSE_LEFT_BUTTON_UP No documentation. RI_MOUSE_RIGHT_BUTTON_DOWN RI_MOUSE_RIGHT_BUTTON_DOWN No documentation. RI_MOUSE_RIGHT_BUTTON_UP RI_MOUSE_RIGHT_BUTTON_UP No documentation. RI_MOUSE_MIDDLE_BUTTON_DOWN RI_MOUSE_MIDDLE_BUTTON_DOWN No documentation. RI_MOUSE_MIDDLE_BUTTON_UP RI_MOUSE_MIDDLE_BUTTON_UP No documentation. RI_MOUSE_BUTTON_1_DOWN RI_MOUSE_BUTTON_1_DOWN No documentation. RI_MOUSE_BUTTON_1_UP RI_MOUSE_BUTTON_1_UP No documentation. RI_MOUSE_BUTTON_2_DOWN RI_MOUSE_BUTTON_2_DOWN No documentation. RI_MOUSE_BUTTON_2_UP RI_MOUSE_BUTTON_2_UP No documentation. RI_MOUSE_BUTTON_3_DOWN RI_MOUSE_BUTTON_3_DOWN No documentation. RI_MOUSE_BUTTON_3_UP RI_MOUSE_BUTTON_3_UP No documentation. RI_MOUSE_BUTTON_4_DOWN RI_MOUSE_BUTTON_4_DOWN No documentation. RI_MOUSE_BUTTON_4_UP RI_MOUSE_BUTTON_4_UP No documentation. RI_MOUSE_BUTTON_5_DOWN RI_MOUSE_BUTTON_5_DOWN No documentation. RI_MOUSE_BUTTON_5_UP RI_MOUSE_BUTTON_5_UP No documentation. RI_MOUSE_WHEEL RI_MOUSE_WHEEL None. None None No documentation. RAW_MOUSE_MODE RAW_MOUSE_MODE No documentation. MOUSE_MOVE_RELATIVE MOUSE_MOVE_RELATIVE No documentation. MOUSE_MOVE_ABSOLUTE MOUSE_MOVE_ABSOLUTE No documentation. MOUSE_VIRTUAL_DESKTOP MOUSE_VIRTUAL_DESKTOP No documentation. MOUSE_ATTRIBUTES_CHANGED MOUSE_ATTRIBUTES_CHANGED No documentation. MOUSE_MOVE_NOCOALESCE MOUSE_MOVE_NOCOALESCE No documentation. RAW_INPUT_DATA_TYPE RAW_INPUT_DATA_TYPE No documentation. RID_INPUT RID_INPUT No documentation. RID_HEADER RID_HEADER No documentation. RAW_INPUT_DEVICE_INFO_TYPE RAW_INPUT_DEVICE_INFO_TYPE No documentation. RIDI_PREPARSEDDATA RIDI_PREPARSEDDATA No documentation. RIDI_DEVICENAME RIDI_DEVICENAME No documentation. RIDI_DEVICEINFO RIDI_DEVICEINFO No documentation. RAW_SCAN_CODE_FLAGS RAW_SCAN_CODE_FLAGS No documentation. RI_KEY_MAKE RI_KEY_MAKE No documentation. RI_KEY_BREAK RI_KEY_BREAK No documentation. RI_KEY_E0 RI_KEY_E0 No documentation. RI_KEY_E1 RI_KEY_E1 Functions

Enumerates the raw input devices attached to the system.

An array of structures for the devices attached to the system. If null, the number of devices are returned in *puiNumDevices.

If pRawInputDeviceList is null, the function populates this variable with the number of devices attached to the system; otherwise, this variable specifies the number of structures that can be contained in the buffer to which pRawInputDeviceList points. If this value is less than the number of devices attached to the system, the function returns the actual number of devices in this variable and fails with .

The size of a structure, in bytes.

If the function is successful, the return value is the number of devices stored in the buffer pointed to by pRawInputDeviceList.

On any other error, the function returns (UINT) -1 and GetLastError returns the error indication.

The devices returned from this function are the mouse, the keyboard, and other Human Interface Device (HID) devices.

To get more detailed information about the attached devices, call GetRawInputDeviceInfo using the hDevice from .

ms645598 unsigned int GetRawInputDeviceList([Out, Buffer, Optional] RAWINPUTDEVICELIST* pRawInputDeviceList,[InOut] unsigned int* puiNumDevices,[In] unsigned int cbSize) GetRawInputDeviceList

Retrieves the information about the raw input devices for the current application.

An array of structures for the application.

The number of structures in *pRawInputDevices.

The size, in bytes, of a structure.

If successful, the function returns a non-negative number that is the number of structures written to the buffer.

If the pRawInputDevices buffer is too small or null, the function sets the last error as , returns -1, and sets puiNumDevices to the required number of devices. If the function fails for any other reason, it returns -1. For more details, call GetLastError.

To receive raw input from a device, an application must register it by using RegisterRawInputDevices.

ms645599 unsigned int GetRegisteredRawInputDevices([Out, Buffer, Optional] RAWINPUTDEVICE* pRawInputDevices,[InOut] unsigned int* puiNumDevices,[In] unsigned int cbSize) GetRegisteredRawInputDevices

Retrieves information about the raw input device.

A handle to the raw input device. This comes from the lParam of the WM_INPUT message, from the hDevice member of , or from GetRawInputDeviceList. It can also be null if an application inserts input data, for example, by using SendInput.

Specifies what data will be returned in pData. This parameter can be one of the following values.

ValueMeaning
0x20000007

pData points to a string that contains the device name.

For this uiCommand only, the value in pcbSize is the character count (not the byte count).

0x2000000b

pData points to an structure.

0x20000005

pData points to the previously parsed data.

?

A reference to a buffer that contains the information specified by uiCommand. If uiCommand is , set the cbSize member of to sizeof() before calling GetRawInputDeviceInfo.

The size, in bytes, of the data in pData.

If successful, this function returns a non-negative number indicating the number of bytes copied to pData.

If pData is not large enough for the data, the function returns -1. If pData is null, the function returns a value of zero. In both of these cases, pcbSize is set to the minimum size required for the pData buffer.

Call GetLastError to identify any other errors.

ms645597 unsigned int GetRawInputDeviceInfoW([In, Optional] void* hDevice,[In] RAW_INPUT_DEVICE_INFO_TYPE uiCommand,[Out, Buffer, Optional] void* pData,[InOut] unsigned int* pcbSize) GetRawInputDeviceInfoW

Retrieves the raw input from the specified device.

A handle to the structure. This comes from the lParam in WM_INPUT.

The command flag. This parameter can be one of the following values.

ValueMeaning
0x10000005

Get the header information from the structure.

0x10000003

Get the raw data from the structure.

?

A reference to the data that comes from the structure. This depends on the value of uiCommand. If pData is null, the required size of the buffer is returned in *pcbSize.

The size, in bytes, of the data in pData.

The size, in bytes, of the structure.

If pData is null and the function is successful, the return value is 0. If pData is not null and the function is successful, the return value is the number of bytes copied into pData.

If there is an error, the return value is (UINT)-1.

GetRawInputData gets the raw input one structure at a time. In contrast, GetRawInputBuffer gets an array of structures.

ms645596 unsigned int GetRawInputData([In] HRAWINPUT hRawInput,[In] RAW_INPUT_DATA_TYPE uiCommand,[Out, Buffer, Optional] void* pData,[InOut] unsigned int* pcbSize,[In] unsigned int cbSizeHeader) GetRawInputData

Registers the devices that supply the raw input data.

An array of structures that represent the devices that supply the raw input.

The number of structures pointed to by pRawInputDevices.

The size, in bytes, of a structure.

TRUE if the function succeeds; otherwise, . If the function fails, call GetLastError for more information.

To receive WM_INPUT messages, an application must first register the raw input devices using RegisterRawInputDevices. By default, an application does not receive raw input.

To receive WM_INPUT_DEVICE_CHANGE messages, an application must specify the flag for each device class that is specified by the usUsagePage and usUsage fields of the structure . By default, an application does not receive WM_INPUT_DEVICE_CHANGE notifications for raw input device arrival and removal.

If a structure has the flag set and the hwndTarget parameter is not set to null, then parameter validation will fail.

ms645600 BOOL RegisterRawInputDevices([In, Buffer] const RAWINPUTDEVICE* pRawInputDevices,[In] unsigned int uiNumDevices,[In] unsigned int cbSize) RegisterRawInputDevices

Performs a buffered read of the raw input data.

A reference to a buffer of structures that contain the raw input data. If null, the minimum required buffer, in bytes, is returned in *pcbSize.

The size, in bytes, of a structure.

The size, in bytes, of the structure.

If pData is null and the function is successful, the return value is zero. If pData is not null and the function is successful, the return value is the number of structures written to pData.

If an error occurs, the return value is (UINT)-1. Call GetLastError for the error code.

Using GetRawInputBuffer, the raw input data is buffered in the array of structures. For an unbuffered read, use the GetMessage function to read in the raw input data.

The NEXTRAWINPUTBLOCK macro allows an application to traverse an array of structures.

Note??To get the correct size of the raw input buffer, do not use *pcbSize, use *pcbSize * 8 instead. To ensure GetRawInputBuffer behaves properly on WOW64, you must align the structure by 8 bytes. The following code shows how to align for WOW64.

[StructLayout(LayoutKind.Explicit)]	
            internal struct 	
            { [FieldOffset(0)] public  header; [FieldOffset(16+8)] public  mouse; [FieldOffset(16+8)] public  keyboard; [FieldOffset(16+8)] public  hid;	
            }	
            
ms645595 unsigned int GetRawInputBuffer([Out, Buffer, Optional] RAWINPUT* pData,[InOut] unsigned int* pcbSize,[In] unsigned int cbSizeHeader) GetRawInputBuffer

Defines the raw input data coming from any device.

ms645581 RID_DEVICE_INFO RID_DEVICE_INFO

The size, in bytes, of the structure.

ms645581 unsigned int cbSize unsigned int cbSize

The type of raw input data. This member can be one of the following values.

ValueMeaning
2

Data comes from an HID that is not a keyboard or a mouse.

1

Data comes from a keyboard.

0

Data comes from a mouse.

?

ms645581 RAW_DEVICE_TYPE dwType RAW_DEVICE_TYPE dwType

If dwType is , this is the structure that defines the mouse.

ms645581 RID_DEVICE_INFO_MOUSE mouse RID_DEVICE_INFO_MOUSE mouse

If dwType is , this is the structure that defines the keyboard.

ms645581 RID_DEVICE_INFO_KEYBOARD keyboard RID_DEVICE_INFO_KEYBOARD keyboard

If dwType is , this is the structure that defines the HID device.

ms645581 RID_DEVICE_INFO_HID hid RID_DEVICE_INFO_HID hid

Defines the raw input data coming from the specified Human Interface Device (HID).

ms645584 RID_DEVICE_INFO_HID RID_DEVICE_INFO_HID

The vendor identifier for the HID.

ms645584 unsigned int dwVendorId unsigned int dwVendorId

The product identifier for the HID.

ms645584 unsigned int dwProductId unsigned int dwProductId

The version number for the HID.

ms645584 unsigned int dwVersionNumber unsigned int dwVersionNumber

The top-level collection Usage Page for the device.

ms645584 HID_USAGE_PAGE usUsagePage HID_USAGE_PAGE usUsagePage

The top-level collection Usage for the device.

ms645584 HID_USAGE_ID usUsage HID_USAGE_ID usUsage

Defines the raw input data coming from the specified keyboard.

For the keyboard, the Usage Page is 1 and the Usage is 6.

ms645587 RID_DEVICE_INFO_KEYBOARD RID_DEVICE_INFO_KEYBOARD

The type of the keyboard.

ms645587 unsigned int dwType unsigned int dwType

The subtype of the keyboard.

ms645587 unsigned int dwSubType unsigned int dwSubType

The scan code mode.

ms645587 unsigned int dwKeyboardMode unsigned int dwKeyboardMode

The number of function keys on the keyboard.

ms645587 unsigned int dwNumberOfFunctionKeys unsigned int dwNumberOfFunctionKeys

The number of LED indicators on the keyboard.

ms645587 unsigned int dwNumberOfIndicators unsigned int dwNumberOfIndicators

The total number of keys on the keyboard.

ms645587 unsigned int dwNumberOfKeysTotal unsigned int dwNumberOfKeysTotal

Defines the raw input data coming from the specified mouse.

For the mouse, the Usage Page is 1 and the Usage is 2.

ms645589 RID_DEVICE_INFO_MOUSE RID_DEVICE_INFO_MOUSE

The identifier of the mouse device.

ms645589 unsigned int dwId unsigned int dwId

The number of buttons for the mouse.

ms645589 unsigned int dwNumberOfButtons unsigned int dwNumberOfButtons

The number of data points per second. This information may not be applicable for every mouse device.

ms645589 unsigned int dwSampleRate unsigned int dwSampleRate

TRUE if the mouse has a wheel for horizontal scrolling; otherwise, .

Windows?XP:??This member is only supported starting with Windows?Vista.
ms645589 BOOL fHasHorizontalWheel BOOL fHasHorizontalWheel

Describes the format of the raw input from a Human Interface Device (HID).

Each WM_INPUT can indicate several inputs, but all of the inputs come from the same HID. The size of the bRawData array is dwSizeHid * dwCount.

ms645549 RAWHID RAWHID

The size, in bytes, of each HID input in bRawData.

ms645549 unsigned int dwSizeHid unsigned int dwSizeHid

The number of HID inputs in bRawData.

ms645549 unsigned int dwCount unsigned int dwCount

The raw input data, as an array of bytes.

ms645549 int bRawData int bRawData

Contains the raw input from a device.

The handle to this structure is passed in the lParam parameter of WM_INPUT.

To get detailed information -- such as the header and the content of the raw input -- call GetRawInputData.

To read the in the message loop as a buffered read, call GetRawInputBuffer.

To get device specific information, call GetRawInputDeviceInfo with the hDevice from .

Raw input is available only when the application calls RegisterRawInputDevices with valid device specifications.

ms645562 RAWINPUT RAWINPUT

The raw input data.

ms645562 RAWINPUTHEADER header RAWINPUTHEADER header
mouse

If the data comes from a mouse, this is the raw input data.

keyboard

If the data comes from a keyboard, this is the raw input data.

hid

If the data comes from an HID, this is the raw input data.

ms645562 RAWINPUT_INNER_0 data RAWINPUT_INNER_0 data

Defines information for the raw input devices.

If is set for a mouse or a keyboard, the system does not generate any legacy message for that device for the application. For example, if the mouse TLC is set with , WM_LBUTTONDOWN and related legacy mouse messages are not generated. Likewise, if the keyboard TLC is set with , and related legacy keyboard messages are not generated.

If is set and the hwndTarget member is not set to null, then parameter validation will fail.

ms645565 RAWINPUTDEVICE RAWINPUTDEVICE

Top level collection Usage page for the raw input device.

ms645565 unsigned short usUsagePage unsigned short usUsagePage

Top level collection Usage for the raw input device.

ms645565 unsigned short usUsage unsigned short usUsage

Mode flag that specifies how to interpret the information provided by usUsagePage and usUsage. It can be zero (the default) or one of the following values. By default, the operating system sends raw input from devices with the specified top level collection (TLC) to the registered application as long as it has the window focus.

ValueMeaning
0x00000400

If set, the application command keys are handled. can be specified only if is specified for a keyboard device.

0x00000200

If set, the mouse button click does not activate the other window.

0x00002000

If set, this enables the caller to receive WM_INPUT_DEVICE_CHANGE notifications for device arrival and device removal.

Windows?XP:??This flag is not supported until Windows?Vista
0x00000010

If set, this specifies the top level collections to exclude when reading a complete usage page. This flag only affects a TLC whose usage page is already specified with .

0x00001000

If set, this enables the caller to receive input in the background only if the foreground application does not process it. In other words, if the foreground application is not registered for raw input, then the background application that is registered will receive the input.

Windows?XP:??This flag is not supported until Windows?Vista
0x00000100

If set, this enables the caller to receive the input even when the caller is not in the foreground. Note that hwndTarget must be specified.

0x00000200

If set, the application-defined keyboard device hotkeys are not handled. However, the system hotkeys; for example, ALT+TAB and CTRL+ALT+DEL, are still handled. By default, all keyboard hotkeys are handled. can be specified even if is not specified and hwndTarget is null.

0x00000030

If set, this prevents any devices specified by usUsagePage or usUsage from generating legacy messages. This is only for the mouse and keyboard. See Remarks.

0x00000020

If set, this specifies all devices whose top level collection is from the specified usUsagePage. Note that usUsage must be zero. To exclude a particular top level collection, use .

0x00000001

If set, this removes the top level collection from the inclusion list. This tells the operating system to stop reading from a device which matches the top level collection.

?

ms645565 unsigned int dwFlags unsigned int dwFlags

A handle to the target window. If null it follows the keyboard focus.

ms645565 HWND hwndTarget HWND hwndTarget

Contains information about a raw input device.

ms645568 RAWINPUTDEVICELIST RAWINPUTDEVICELIST

A handle to the raw input device.

ms645568 void* hDevice void hDevice

The type of device. This can be one of the following values.

ValueMeaning
2

The device is an HID that is not a keyboard and not a mouse.

1

The device is a keyboard.

0

The device is a mouse.

?

ms645568 unsigned int dwType unsigned int dwType

Contains the header information that is part of the raw input data.

To get more information on the device, use hDevice in a call to GetRawInputDeviceInfo.

ms645571 RAWINPUTHEADER RAWINPUTHEADER

The type of raw input. It can be one of the following values.

ValueMeaning
2

Raw input comes from some device that is not a keyboard or a mouse.

1

Raw input comes from the keyboard.

0

Raw input comes from the mouse.

?

ms645571 RAW_DEVICE_TYPE dwType RAW_DEVICE_TYPE dwType

The size, in bytes, of the entire input packet of data. This includes plus possible extra input reports in the variable length array.

ms645571 unsigned int dwSize unsigned int dwSize

A handle to the device generating the raw input data.

ms645571 void* hDevice void hDevice

The value passed in the wParam parameter of the WM_INPUT message.

ms645571 UINT_PTR wParam UINT_PTR wParam
No documentation. RAWINPUT_INNER_0 RAWINPUT_INNER_0 No documentation. RAWMOUSE mouse RAWMOUSE mouse No documentation. RAWKEYBOARD keyboard RAWKEYBOARD keyboard No documentation. RAWHID hid RAWHID hid

Contains information about the state of the keyboard.

ms645575 RAWKEYBOARD RAWKEYBOARD

The scan code from the key depression. The scan code for keyboard overrun is KEYBOARD_OVERRUN_MAKE_CODE.

ms645575 unsigned short MakeCode unsigned short MakeCode

Flags for scan code information. It can be one or more of the following.

ValueMeaning
1

The key is up.

2

This is the left version of the key.

4

This is the right version of the key.

0

The key is down.

?

ms645575 RAW_SCAN_CODE_FLAGS Flags RAW_SCAN_CODE_FLAGS Flags

Reserved; must be zero.

ms645575 unsigned short Reserved unsigned short Reserved

Windows message compatible virtual-key code. For more information, see Virtual Key Codes.

ms645575 unsigned short VKey unsigned short VKey

The corresponding window message, for example , , and so forth.

ms645575 RAW_KEY_STATE Message RAW_KEY_STATE Message

The device-specific additional information for the event.

ms645575 unsigned int ExtraInformation unsigned int ExtraInformation
Defines the raw input data coming from the specified Human Interface Device (HID). Initializes a new instance of the class. Initializes a new instance of the class. The raw device info. Name of the device. The device handle. Gets or sets the vendor id. The vendor id. unsigned int dwVendorId Gets or sets the product id. The product id. unsigned int dwProductId Gets or sets the version number. The version number. unsigned int dwVersionNumber Gets or sets the usage page. The usage page. HID_USAGE_PAGE usUsagePage Gets or sets the usage. The usage. HID_USAGE_ID usUsage Describes the format of the raw input from a Human Interface Device (HID). RawInput event arguments base. Gets or sets the RawInput device. The device. Initializes a new instance of the class. Initializes a new instance of the class. The raw input. Gets or sets the number of Hid structure in the . The count. Gets or sets the size of the Hid structure in the . The size of the data. Gets or sets the raw data. The raw data. Defines the raw input data coming from the specified keyboard. RID_DEVICE_INFO_KEYBOARD Initializes a new instance of the class. Initializes a new instance of the class. The raw device info. Name of the device. The device handle. Gets or sets the type of the keyboard. The type of the keyboard. unsigned int dwType Gets or sets the subtype. The subtype. unsigned int dwSubType Gets or sets the keyboard mode. The keyboard mode. unsigned int dwKeyboardMode Gets or sets the function key count. The function key count. unsigned int dwNumberOfFunctionKeys Gets or sets the indicator count. The indicator count. unsigned int dwNumberOfIndicators Gets or sets the total key count. The total key count. unsigned int dwNumberOfKeysTotal RawInput Keyboard event. Initializes a new instance of the class. Initializes a new instance of the class. The raw input. Gets or sets the key. The key. Gets or sets the make code. The make code. Gets or sets the scan code flags. The scan code flags. Gets or sets the state. The state. Gets or sets the extra information. The extra information. Defines the raw input data coming from the specified mouse. RID_DEVICE_INFO_MOUSE Initializes a new instance of the class. Initializes a new instance of the class. The raw device info. Name of the device. The device handle. Gets or sets the id. The id. unsigned int dwId Gets or sets the button count. The button count. unsigned int dwNumberOfButtons Gets or sets the sample rate. The sample rate. unsigned int dwSampleRate Gets or sets a value indicating whether this instance has horizontal wheel. true if this instance has horizontal wheel; otherwise, false. BOOL fHasHorizontalWheel RawInput Mouse event. Initializes a new instance of the class. Initializes a new instance of the class. The raw input. Gets or sets the mode. The mode. Gets or sets the button flags. The button flags. Gets or sets the extra information. The extra information. Gets or sets the raw buttons. The raw buttons. Gets or sets the wheel delta. The wheel delta. Gets or sets the X. The X. Gets or sets the Y. The Y. The namespace provides a managed RawInput API. ms645536 RawInput RawInput Contains information about the state of the mouse. The mouse state. Raw button data. The motion in the X direction. This is signed relative motion or absolute motion, depending on the value of usFlags. The motion in the Y direction. This is signed relative motion or absolute motion, depending on the value of usFlags. The device-specific additional information for the event. Flags for the event. If the mouse wheel is moved, this will contain the delta amount.