RawInput for Devices in RDS-based Session

I’ve created a virtual HID device which works fine in a remote Console session when using RawInput APIs, but when using an RDS-based session (think RDP) GetRawInputDeviceList() never sees the device, or any device, ever. (Other APIs successfully interact with the device).

Does anyone have experience or ideas about RawInput in an RDS-based session?

Stepping on the kernel side I see win32kfull!NtUserGetRawInputDeviceList() iterates a global linked list which might explain why the API seems disabled (multiple sessions and a single global conflict architecturally), but is very unfortunate because increasingly I see software wants to use RawInput (e.g. Blender).

-Nathan

Nobody’s had a problem with RawInput not seeing devices?

You can understand the difficulties, right? Your raw device belongs to the host, not to any individual session. They all have to share access to the device through the very fat layer of abstraction, and that prevents a device from being available in “raw” mode to any single session. I guess I would expect the session-specific fake input device to be visible, however.

You’re right, of course, that it would be difficult to map any physically connected device into RDS sessions. I’m only considering devices that are already per-session (e.g. hung off a virtual USB hub) – they don’t show up with GetRawInputDeviceList(), but it seems RawInput could iterate a per-session list.

I guess I was hoping to entice Doron into saying “Yeah, I wrote that subsystem back in the day and the PM at the time said” A) “we never will care about anything but Console”, or B) “Wait till customers ask to bother with per-session devices” or C) … :slight_smile:

Sorry, never dealt with rds. My involvement stopped at the raw input device layer and those fun abstractions above were mostly magic to me.

1 Like