Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 37acf6e3 authored by Yeabkal Wubshit's avatar Yeabkal Wubshit
Browse files

Make VelocityTracker 1D

Currently, VelocityTracker is strictly tied to X and Y axes. It's APIs
act on both axes, and its component structs (e.g. Position, Estimator)
are tied to both X and Y axes. As a step towards supporting more axes
for velocity tracking, this change:
- removes the Position struct: stores/processes data as pure floats, one
  axis at a time
- makes Estimator and Strategy specific to a single axis, instead of
  dealing with both/only X and Y at the same time
Furthermore, we have pulled into VelocityTracker the logic to compute
all velocity. This helps making the immediate JNI layer light-weight in
addition to allowing us to test the logic (which is non-trivial and
benefits from tests).

Bug: 32830165
Test: VelocityTracker_test unaffected (atest libinput_tests)

Change-Id: I181af7a033eb647e9cb97db9b86a36ae972290a5
parent 89eca324
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment