Open skogler opened 7 years ago
Dota uses SDL for all pointer operations and doesn't know anything about specific hardware. Maybe the SDL dev knows more?
I'll try to create a minimal SDL2 test application to reproduce this issue, and to see if it really is a SDL2 bug.
Does Dota use SDL_WarpMouseInWindow to set the mouse position within the window? Or does it do SDL_SetRelativeMouseMode and draw the cursor circle in the middle by itself? I'd guess the latter.
When in a game and you don't have some other UI up things should be in relative mouse mode.
Hello @skogler, are you using any launch options with Dota 2?
hi, no I am not using any at the moment.
I can confirm there is a bug in SDL2, where SDL_WarpMouseInWindow does not correctly set the mouse position with the Razer DeathAdder mouse. I discovered this with the following small test program:
https://gist.github.com/skogler/9d9ab1b3e977d25901afe6fa1c2d608f
This just draws a rectangle where the mouse is currently at, according to SDL2. You can hold the middle mouse button to draw a 'Chat wheel' dummy. Then, when you release the mouse, the position of the mouse should be restored. This works for the normal mouse, but not with the DeathAdder.
@skogler it's probably not actual for you anymore, but I just found the root cause of this bug which happened to me and my G600 mouse. It might be not the exact case for you but still.
My mouse has very high dpi and I tweaked it with xinput
, setting Coordinate Transformation Matrix
to something like 1 0 0 0 1 0 0 0 1.6
on every boot. When I reset it back to 1 0 0 0 1 0 0 0 1
, everything became fine.
But what if you want to actually change mouse sensitivity through xinput?
This happens whenever the transformation matrix has values that are not 0 or 1.
Since a few months ago, the chat wheel window center detection is broken for me. It always moves the mouse to the top left corner of the window, approximately one hundred pixels inside. I disconnected every input device except for keyboard and mouse.
Things I have tested so far which do not change this behaviour:
EDIT
The problem is related to the Razer DeathAdder 2013 I am using. With a 'normal' mouse the problem does not occur. This might be related to an odd X11 detection of the mouse, where it has some more devices than usual in xinput. This is not an issue in any other application than Dota 2 though.
xinput output with Razer DeathAdder 2013:
vs. with a simple Logitech mouse:
Steam hardware information: