WM_INPUT message - How modify structure

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
Archimede
Posts: 487
Joined: 25 Nov 2021, 09:49
Location: Switzerland / Italy

WM_INPUT message - How modify structure

Post by Archimede » 09 Aug 2022, 03:06

Hallo.
I am writing a program to modify the structure generates by WM_INPUT message.
When generates a WM_INPUT message (after API RegisterRawInputDevices(...)), automatically generates a lParam parameter: it contain an handle to a structure; I need to modify some things into that structure (a RAWINPUT structure).
To read some thing into the structure I can use GetRawInputData(...) but to modify it I no know if and how it is possible.
My problem is: I need to read the absolute mouse coordinates instead relative mouse coordinates.
Thank you very much

swagfag
Posts: 6222
Joined: 11 Jan 2017, 17:59

Re: WM_INPUT message - How modify structure

Post by swagfag » 11 Aug 2022, 18:32

whether absolute or relative values are reported by the Raw Input APIs depends entirely on the device ure monitoring. though id say its pretty safe to assume most mice would only ever report relative
if u need the absolute position, call into other APIs that report it in response to an arriving Raw Input msg, eg GetCursorPos or simply the equivalent ahk command

Post Reply

Return to “Ask for Help (v1)”