aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Reset scroll state on finger configuration changeHenrik Rydberg2010-04-151-0/+6
| | | | | | | | | | | When scrolling, the current code remembers how close the movement is to emitting a scroll button, in order to produce a continuous stepping motion. However, when the finger configuration on the trackpad changes, this state should start over again, or the next scolling gesture may scroll prematurely. This patch resets the scrolling state when a change is detected, which fixes the problem. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Unify detection of finger configuration changesHenrik Rydberg2010-04-152-14/+18
| | | | | | | | | | This patch simplifies and unifies the means by which finger configuration changes are detected. The logic is almost the same, except for the unlikely case of very quickly switching the clicking finger, after first having moved it above the clicking area. This case should now properly be detected as a pointing finger. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Reset accumulated movement at finger configuration changeHenrik Rydberg2010-04-151-0/+2
| | | | | | | | | This bug crept in during the transition of the movement code from position differencing to delta accumulation. If briefly touching the trackpad in motion, then placing the finger calmly at another point, a jittery motion would occur. Fixed with this patch. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* janitor: Use more common row/column namesHenrik Rydberg2010-04-151-10/+10
| | | | Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Multitouch 1.0-alpha2Henrik Rydberg2010-04-151-1/+1
|
* Add memory debug convenience routinesHenrik Rydberg2010-04-153-0/+16
| | | | | | Output parsing memory values, switched off by default. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Extract moving fingersHenrik Rydberg2010-04-152-19/+57
| | | | | | | | | | | | The current code determines the moving, scrolling and swiping gestures based on the number of fingers on the trackpad, including the resting fingers at the bottom of the pad. With information about all fingers at hand, it is possible to determine which fingers on the trackpad are participating in a moving gesture. This patch computes the movement based on the pointing fingers only, and uses that number to determine the type of moving gesture. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Extract pointing fingersArturo Castro2010-04-152-3/+44
| | | | | | | | | | | | | | | Multi-finger clicks and taps are goverened by the number of pointing fingers on the trackpad. This number can be different from the actual number of fingers on the trackpad. For instance, a finger resting at the bottom of an integrated button, or a finger that accidentally touches the pad during a press, are not pointing fingers. This patch introduces extract_pointers(), which computes the number of pointing fingers on the trackpad, and uses that number to determine the logical button state. [rydberg@euromail.se: various cleanups] Signed-off-by: Arturo Castro <arturo@openframeworks.cc> Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Add constant clicking area to capabilitiesHenrik Rydberg2010-04-152-0/+5
| | | | | | | | The trackpads with integrated button have a dedicated clicking area at the bottom of the pad. This patch adds the position of the onset of the clicking area to capabilities. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Add integrated button property to capabilitiesHenrik Rydberg2010-04-152-1/+11
| | | | | | | | | The new Apple unibody macbooks have a trackpad with an integrated button, which needs special treatment. This patch tests the device for an integrated button and keeps the result in the capabilities struture. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Additional device informationHenrik Rydberg2010-04-152-0/+11
| | | | | | | Add information about the device name and device identifier from the EVIO protocol. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Define swipe gesturesHenrik Rydberg2010-04-153-10/+32
| | | | | | | Define three-finger vertical and horizontal scroll as vertical and horizontal swipe gestures. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Define swipe buttonsHenrik Rydberg2010-04-152-2/+13
| | | | | | Define four additional buttons to be used for swiping gestures. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Break out scrolling codeHenrik Rydberg2010-04-151-18/+18
| | | | | | Move the duplicated scrolling code to a function. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Drop movement during gesture decayArturo Castro2010-04-151-2/+7
| | | | | | | | | | | With this patch, finger motion is divided into two phases; one attack phase where fingers are added to the trackpad, and one decay phase, where fingers leave the trackpad. The decay delay is set considerably larger than the attack delay. The prime effect is to ignore accidental pointer movement right after a two-finger scroll. Signed-off-by: Arturo Castro <arturo@openframeworks.cc> Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Add a gesture credits sectionHenrik Rydberg2010-04-151-0/+4
| | | | Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Delay movement after a finger configuration changeArturo Castro2010-04-152-8/+22
| | | | | | | | | | The current code responds to finger movement immediately after a finger has been placed on the trackpad, even if the touch is accidental. This patch delays the effect of the finger by 70 ms, resulting in fewer accidental movements. Signed-off-by: Arturo Castro <arturo@openframeworks.cc> Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Add robust position event filteringHenrik Rydberg2010-04-153-0/+31
| | | | | | | | | | The kernel filtering is bypassed for MT events. This patch reintroduces filtering at the earliest possible point, right after the fingers have been identified. For drivers that do not set proper fuzz parameters, sensible values are derived based on a generic signal-to-noise ratio. The defuzz code is borrowed from the Linux kernel, thanks GPL. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Keep logical buttons separate from the hardware onesHenrik Rydberg2010-04-153-4/+10
| | | | | | | | | The button extraction currently modifies the MTState buttons, upsetting the semantics in a bad way. This patch adds the logical button state to the Memory structure, and uses it to compute the logical button change. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Only extract movement from identical finger configurationsHenrik Rydberg2010-04-151-16/+21
| | | | | | | | | The current code would extract movement from a rapid change from one finger to the next, resulting in unwanted jumps. This patch first checks that the finger configuration is the same before attempting to extract movement. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Reorganize gesture codeHenrik Rydberg2010-04-151-18/+32
| | | | | | | Break out extraction of movement, buttons and type. Only code traversal, no logical changes. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Introduce MemoryHenrik Rydberg2010-04-155-0/+62
| | | | | | Add the Memory structure to hold the multitouch parsing state. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Do not sort HWState fingersHenrik Rydberg2010-04-151-8/+0
| | | | | | | The fingers are currently sorted in tracking id order, for no good reason. This patch removes the sorting. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Add MTState debug outputHenrik Rydberg2010-04-151-0/+3
| | | | Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Introduce the MTStateHenrik Rydberg2010-04-158-86/+159
| | | | | | | | | | | | | | | The HWState keeps, for good reason, both touching fingers and fingers going away. However, this implies that additional logic is needed to keep track of the number of actual touching fingers. In particular the test for touching fingers is somewhat misplaced in hwstate.c. Moreover, HWState should only exist in one instance, since it contains data which does not need to be referred to during gesture extraction. This patch introduces the MTState structure, which keeps more digested data for gesture extraction. In particular, it only keeps the actual touches. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Rename State to HWStateHenrik Rydberg2010-04-156-34/+34
| | | | | | | Rename the hardware state struct State to HWState, to make room for additional state structures. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Reverse the order of the hscroll buttonsArturo Castro2010-04-151-2/+2
| | | | | | | | | | The horizontal three-finger swipe is currently defined in the opposite direction to what is considered normal. This patch reverses the order of the emitted buttons, restoring normality. Signed-off-by: Arturo Castro <arturo@openframeworks.cc> Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Use the event source time instead of the arrival timeHenrik Rydberg2010-04-151-11/+4
| | | | | | | | The SYN_REPORT event time is equal to the time when the collective event was produced in the kernel driver, and thus better represents the actual device timings than the current arrival time. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Third time around (and use the next branch for collaboration)Henrik Rydberg2010-04-151-3/+3
| | | | | | | | | | | | There is (obviously, from the recent commit flaws) a need to keep a volatile branch for collaboration, to allow for digested commits in master. The next branch will rebase occasionally, so one cannot rely on commit ids from that branch. This patch corrects the commit mistake for the third time, to never change that line again. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Multitouch 1.0-alpha1Henrik Rydberg2010-04-151-0/+4
|
* Correct double commit mistakeHenrik Rydberg2010-03-211-1/+2
| | | | | | | | | The recent patch sequence got slightly contaminated with versions of abs15() by mistake. On top of it all, the one committed did the wrong thing. This patch corrects abs15() to do simple clamping of values outside the allowed range. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Add millisecond event timesHenrik Rydberg2010-03-214-0/+17
| | | | | | | | Expand the (x, y) notion of the current hardware events to the more useful (x, y, t) notion. This patch was inspired by a gesture patch from Arturo Castro <arturo@openframeworks.cc>. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Comply with MT syncronization protocolHenrik Rydberg2010-03-213-21/+59
| | | | | | | | | The latest semantic clarifications in the kernel MT protocol allow SYN_MT_REPORT to be sent without actually sending any finger data. Add a mask to the hardware data so that the data actually read can be tracked. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Add support for the ABS_MT_PRESSURE eventHenrik Rydberg2010-03-214-2/+12
| | | | | | | The kernel MT api was recently updated to include the ABS_MT_PRESSURE event. This patch adds it to the hardware structure. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Remove unused min/max definitionsHenrik Rydberg2010-03-211-3/+0
| | | | Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Matcher: convert distance matrix to integerHenrik Rydberg2010-03-214-74/+80
| | | | | | | | In order to reduce the requirements on the cpu environment running the matcher, the floating-point operations are converted to integer. Care is taken as to not overflow the distance matrix. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Matcher: support up to 32 fingersHenrik Rydberg2010-03-212-3/+3
| | | | | | Make the matcher support up to 32 fingers instead of the current 16. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* Introduce convenience function for device dimensionsHenrik Rydberg2010-03-213-6/+15
| | | | | | | The capability names are rather lengthy; this patch adds convenience functions for the dimension capabilities. Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
* janitor: remaining indentation fixedHenrik Rydberg2010-02-021-2/+2
|
* janitor: stick to kernel-style formattingHenrik Rydberg2010-02-0115-201/+73
| | | | | | With this commit, the whole code base complies with the kernel format style, and patches can be checked against the kernel-provided ./scripts/checkpatch.pl
* janitor: match: stick to kernel-style formattingHenrik Rydberg2010-02-013-129/+174
|
* button: simplify property mappingHenrik Rydberg2010-02-012-41/+19
| | | | Janitory changes only.
* button: simplify button handlingHenrik Rydberg2010-02-013-15/+10
| | | | | Make better use of the bit representation, reducing one layer of conversion.
* button: define all buttons used as hardware buttonsHenrik Rydberg2010-02-011-0/+4
|
* common: add some more bit utilitiesHenrik Rydberg2010-02-012-6/+8
|
* Revert "sweep feels better without memory"Henrik Rydberg2010-02-011-6/+5
| | | | | | Really too specialized behavior, so better off without it. This reverts commit e880479ff29e57d8b47f08f620b4bccdd2683aa5.
* dangling pointer breaking resume from suspend; fixedHenrik Rydberg2010-01-301-0/+1
|
* sweep feels better without memoryHenrik Rydberg2010-01-301-5/+6
|
* silence debugging outputHenrik Rydberg2010-01-301-4/+13
| | | | | Running the driver daily produces a lot of debug output, so turn it off by default.
* horizontal and vertical scroll now works againHenrik Rydberg2010-01-302-6/+13
| | | | | The buttons reported to X did not include the scrolling buttons, effectively disabling scrolling alltogether. Fixed.