summaryrefslogtreecommitdiff
path: root/.gitignore
diff options
context:
space:
mode:
authorHans de Goede <hdegoede@redhat.com>2017-07-02 15:15:58 +0200
committerHans de Goede <hdegoede@redhat.com>2017-07-02 15:28:09 +0200
commit5264a3c45c890014dc97ed3698b2c4272d9af2ba (patch)
tree09ee0952b5e7411d819fc6488a2136f695818f5c /.gitignore
parent24ad0082940c9a023f8f8ae66fcabbc5713f96bf (diff)
filter: Add timestamp smoothing support
Some devices, specifically some bluetooth touchpads generate quite unreliable timestamps for their events. The problem seems to be that (some of) these touchpads sample at aprox 90 Hz, but the bluetooth stack only communicates about every 30 ms (*) and then sends mutiple HID input reports in one batch. This results in 2-4 packets / SYNs every 30 ms. With timestamps really close together. The finger coordinate deltas in these packets change by aprox. the same amount between each packet when moving a finger at constant speed. But the time deltas are e.g. 28 ms, 1 ms, 1 ms resulting in calculate_tracker_velocity returning vastly different speeds for the 1st and 2nd packet, which in turn results in very "jerky" mouse pointer movement. *) Maybe it is waiting for a transmit time slot or some such. This commit adds support for a real simple timestamp smoothing algorithm, intended *only* for use with touchpads. Since touchpads will send a contineous stream of events at their sample rate when a finger is down, this filter simply assumes that any events which are under event_delta_smooth_threshold us apart are part of a smooth continuous stream of events with each event being event_delta_smooth_value us apart. Theoritically a very still finger may send the exact same coordinates and pressure twice, but even if this happens that is not a problem because a still finger generates coordinates changes below the hyst treshold so we ignore it anyways. Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Diffstat (limited to '.gitignore')
0 files changed, 0 insertions, 0 deletions