Mir-on-X mouse input is jerky/stuttery compared to Mir-on-KMS
Bug #1576600 reported by
Daniel van Vugt
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Mir |
Fix Released
|
Medium
|
Daniel van Vugt | ||
mir (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
Mir-on-X mouse input is irregular and stutters a bit, compared to Mir-on-KMS.
Test case:
env MIR_CLIENT_
Related branches
lp://staging/~vanvugt/mir/remove-input-resampling-standalone
- Mir CI Bot: Approve (continuous-integration)
- Andreas Pokorny (community): Approve
- Alan Griffiths: Abstain
- Chris Halse Rogers: Approve
-
Diff: 522 lines (+48/-274)7 files modifiedexamples/fingerpaint.c (+0/-6)
examples/target.c (+0/-6)
src/client/input/android/android_input_receiver.cpp (+26/-98)
src/client/input/android/android_input_receiver.h (+3/-12)
tests/acceptance-tests/test_client_input.cpp (+0/-64)
tests/acceptance-tests/test_confined_pointer.cpp (+0/-1)
tests/unit-tests/client/input/test_android_input_receiver.cpp (+19/-87)
Changed in mir: | |
status: | New → Triaged |
summary: |
- Mir-on-X mouse input is irregular compared to Mir-on-KMS + Mir-on-X mouse input is jerky/stuttery compared to Mir-on-KMS |
Changed in mir: | |
milestone: | none → 0.26.0 |
assignee: | nobody → Daniel van Vugt (vanvugt) |
status: | Triaged → In Progress |
Changed in mir: | |
milestone: | 0.26.0 → 1.0.0 |
Changed in mir: | |
milestone: | 1.0.0 → 0.26.0 |
Changed in mir: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
It appears Xorg uses CLOCK_MONOTONIC _COARSE for its (input) timestamps. And Mir generally uses CLOCK_MONOTONIC for its input resampling code (via systemTime and libinput). On top of that, a lot of precision is lost in Xorg only keeping millisecond accuracy by design :(
So those two issues probably explain the jerkiness completely, and especially explains why it's only visible when input resampling is active (because that's the only time we need the clocks to match up).
Brandon has also mentioned he has delay issues with key events (which I am not seeing). But that could also be explained by the above timing problems.
We should try to at least convert X's input event timestamps into CLOCK_MONOTONIC in case the epoch and/or frequencies are different. And as a last resort might want to try just synthesising timestamps in the x11 input platform.