Page MenuHome

Blender ignores xinput mouse sensitivity (as a result, mouse cursor randomly jumps when I attempt to navigate, move objects, etc.)
Closed, InvalidPublicTO DO


System Information
Linux, Debian Sid, GTX 680

Short description of error
This is what happens: if mouse sensitivity is default, everything works fine. If mouse sensitivity is, for example, 0.9 instead of 1, and I try to rotate view by holding middle mouse button, when I release it, mouse cursor jumps to position it would reach with default sensitivity. Automatic cursor wrapping in Blender also ignores xinput sensitivity, so if it happens, mouse cursor will jump unexpectedly even before I release mouse button. The same thing happens when I try to rotate or move objects. When sensitivity is set to low value, for example, 0.3, mouse cursor jumps to edge of the screen almost every time I release mouse button or move/rotate some object with mouse. And because of this, mouse does not wrap around from one edge of the screen to another seemlessly, it just starts behaving crazy, like rotating view at extreme speed.

I have very sensitive mouse, and I cannot change its hardware sensitivity. So I have to adjust it with xinput, otherwise cursor will be "flying" too fast. This used to work with Blender in older distros where it was possible to adjust "Device Accel Constant Deceleration" to change mouse sensitivity. However, this seems to be not possible for a while now because this xinput property was removed. Instead, to change mouse sensitivity I have to adjust Coordinate Transformation Matrix. This works everywhere except in Blender. In case somebody does not know this, in Linux I have to use xinput to adjust sensitivity, because as far as I know there is no other way to do it (for example, in KDE systemsettings I can adjust only acceleration, and even if I set it below 1x, even to minimum 0.1x, it does not do much, and this is expected, since acceleration and sensitivity are completely different settings).

Exact steps for others to reproduce the error
Set mouse sensitivity to anything but 1. For example:

id="pointer:Mouseemu virtual mouse"; speed=0.3; xinput set-prop $id "Coordinate Transformation Matrix" $speed, 0, 0, 0, $speed, 0, 0, 0, 1

Of course, you need to replace pointer name (text after "pointer:" prefix) with your own (if you do not know it, see output from "xinput list"). Then try to rotate view with middle button. You will see cursor to jump unexpectedly when you release mouse button or if you hit edge of the screen.

As far as I can tell, it feels like Blender always assumes default "Coordinate Transformation Matrix", and ignores real one. And as a result, Blender does not calculate mouse position correctly. This pretty much makes Blender practically unusable with mouse which needs xinput sensitivity adjustment. So far I was not able to found any workaround, and it is very hard to work with default sensitivity in my case. If you need more information, please let me know.

Revisions and Commits

Event Timeline

Campbell Barton (campbellbarton) lowered the priority of this task from 90 to 50.Jul 21 2016, 7:06 PM

Confirmed, note that this feature probably isn't very widely used, since we've had cursor warping on X11 for ~7 years, and this is the first time the problems been reported.

From checking on this, it seems we need to call XIGetKnownProperty(XI_PROP_TRANSFORM), see:

Note that for cursor speed its common to use: xinput --set-prop $id 'Device Accel Constant Deceleration' 1.3
(where $id is you're device id).

Set as TODO:

Campbell Barton (campbellbarton) changed the task status from Unknown Status to Unknown Status.Jul 21 2016, 7:07 PM
Campbell Barton (campbellbarton) edited a custom field.

The reason why it was not reported yet probably because in the past it was possible to use "Device Accel Constant Deceleration" but some time ago this property was removed from xinput (as I have already mention in the previous message).

The command you have suggested in Debian Sid will return error: "property 'Device Accel Constant Deceleration' doesn't exist, you need to specify its type and format".

Please note I have used Constant Deceleration for many years in the past. But after upgrading my distro I cannot use it because Constant Deceleration is not supported by xinput anymore. So I am forced to use "Coordinate Transformation Matrix" instead. I do not have a choice unfortunately. Unless I'm missing something, everyone who uses Debian Sid will be affected by this bug if they attempt to change mouse sensitivity.

Thanks for looking into this issue.

The fix for this caused T50383, so this has been reverted.

Since this is a limit of xorg, setting this as a TODO.

Fix can be reinstated once is resolved.

Campbell Barton (campbellbarton) changed the task status from Resolved to Unknown Status.Jan 15 2019, 7:02 AM