Hello,
I believe I've stumbled upon a bug with virtual mouse position provided when the cursor is disabled. I use the feature as follows:
I notice sometimes when I move the mouse and press at the same time (instead of pressing and waiting a little bit before moving) the delta in step 2. is super large and for the first mouse move event is always offset by lastMousePress (i.e. last value from step 1) minus windowSize/2, instead of some low expected value, like a few pixels around the lastMousePress. This gives a super large delta on the first mouse move if the click was done near the borders of the window. I believe the error comes somewhere in ordering of events, whether its WM_INPUT or WM_MOUSEMOVE being triggered in an order where the internal virtual cursor tracking is not properly initialized, but I couldn't find the bug in the library source myself.
Full example for window size [800, 600]:
Platform: Win10
Maybe related to Windows 10 Fall Creators Update mouse issue: https://twitter.com/icculus/status/941912950188765184
I would recommend cloning latest GLFW from master which should use raw input which might circumvent this bug and/or updating Windows
Greetings,
Thanks for the tips.
I've built the lib from master branch and it seems to be working correctly, I couldn't reproduce the error.
I'll close the issue.
Most helpful comment
Maybe related to Windows 10 Fall Creators Update mouse issue: https://twitter.com/icculus/status/941912950188765184
I would recommend cloning latest GLFW from master which should use raw input which might circumvent this bug and/or updating Windows