cf124b1415
The current system for capturing the mouse and generating motion events on X11 has issues with inaccurate and lopsided input. This is because both XQueryPointer and XWarpPointer work in terms of integer coordinates when the underlying X11 input driver may be tracking the mouse using subpixel coordinates. When warping the pointer, the fractional part of the pointer position is discarded. To work around this issue, the fix uses raw motion events from XInput 2. These events report relative motion and are not affected by pointer warping. Additionally, this means Godot is able to detect motion at a higher resolution under X11. Because this is raw mouse input, it is not affected by the user's pointer speed and acceleration settings. This is the same system as SDL2 uses for its relative motion. Multitouch input on X requires XInput 2.2. Raw motion events require XInput 2.0. Since 2.0 is old enough, this is now the minimum requirement to use Godot on X. |
||
---|---|---|
.. | ||
export | ||
context_gl_x11.cpp | ||
context_gl_x11.h | ||
crash_handler_x11.cpp | ||
crash_handler_x11.h | ||
detect.py | ||
godot_x11.cpp | ||
joypad_linux.cpp | ||
joypad_linux.h | ||
key_mapping_x11.cpp | ||
key_mapping_x11.h | ||
logo.png | ||
os_x11.cpp | ||
os_x11.h | ||
platform_config.h | ||
platform_x11_builders.py | ||
power_x11.cpp | ||
power_x11.h | ||
SCsub |