Daniel Kurtz [Mon, 23 May 2011 17:02:07 +0000 (10:02 -0700)]
UPSTREAM: Four finger swipes in multitouch
I think four finger swipes are useful, attached is a very
simple patch enabling that.
Signed-off-by: Daniel Landau <daniel.landau@helsinki.fi>
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
(cherry picked from commit
4d87c041f6a232aa30528d70d4b9946d1824b4ed)
Change-Id: I8ebd875cb2ef7171c5d8be311d09ca6603dc9933
Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>
Reviewed-on: http://gerrit.chromium.org/gerrit/1361
Reviewed-by: Andrew de los Reyes <adlr@chromium.org>
Diego Elio Pettenò [Tue, 15 Mar 2011 17:52:49 +0000 (18:52 +0100)]
Export symbols as it's done by xf86-input-evdev.
Based on the suggestion by Andrew de los Reyes.
Diego Elio Pettenò [Thu, 10 Mar 2011 19:59:13 +0000 (20:59 +0100)]
build-sys: use autotools build system derived from xf86-input-evdev.
Instead of using a custom-tailored Makefile, this brings multitouch up to
speed with the input drivers from FreeDesktop.org and allows it to
cross-compile just fine.
Harald Hoyer [Thu, 3 Mar 2011 11:12:11 +0000 (12:12 +0100)]
Makefile: make LIBDIR configurable
On Fedora /usr/lib64 is used for 64 bit architectures.
[rydberg@euromail.se: removed extra slash]
Signed-off-by: Harald Hoyer <harald@redhat.com>
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Dennis Jarosch [Thu, 10 Feb 2011 07:57:38 +0000 (08:57 +0100)]
Add missing thumb reset at state extraction
Fixes the bug that stopped tapped clicks from working when two thumbs
were detected, by initializing the thumb variable for every new state.
Signed-off-by: Dennis Jarosch <dennis.jarosch@gmx.de>
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Dennis Jarosch [Thu, 10 Feb 2011 07:51:02 +0000 (08:51 +0100)]
Fix event flood in tap handling
Fixes the bug that flooded the X server with button events, by
initializing the Gestures struct before handling taps.
Signed-off-by: Dennis Jarosch <dennis.jarosch@gmx.de>
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sun, 13 Feb 2011 08:54:06 +0000 (09:54 +0100)]
Support XINPUT 12
The version 12 input ABI brings substantial changes to driver
handling. This patch makes the driver compile and run under the
upcoming X server 1.10.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 21 Oct 2010 17:49:31 +0000 (19:49 +0200)]
xf86-input-multitouch v1.0-rc2
Henrik Rydberg [Thu, 21 Oct 2010 18:48:44 +0000 (20:48 +0200)]
Package as xf86-input-multitouch
Refresh the debian packaging, changing name and version to match
current project.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sat, 16 Oct 2010 14:13:59 +0000 (16:13 +0200)]
Increase vscroll speed by a factor of two
The default two-finger scroll is somewhat slow; double it.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sat, 16 Oct 2010 14:04:42 +0000 (16:04 +0200)]
Support palm detection for trackpads without width support
The Magic Trackpad does not report both touch and width of a finger,
making thumb/palm detection less reliable. Approximate thumb detection
as a large oval object, restoring some of the thumb functionality.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sat, 16 Oct 2010 12:45:57 +0000 (14:45 +0200)]
Turn tapping on by default
The current lack of configuration possibilities makes it reasonable to
turn tapping on by default, if nothing else for discoverability
reasons. Turn turn off, just change the value in src/memory.c.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sat, 16 Oct 2010 12:43:22 +0000 (14:43 +0200)]
Do not grab by default
Grabbing the device has some historic virtues, but to simplify
experimentation with devices and multitouch data, turn the device
grabbing of by default.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sat, 16 Oct 2010 14:26:20 +0000 (16:26 +0200)]
Adjust thumb detection based on kernel touch width alignment
Recently, a set of kernel drivers were updated to align the
reported touch size with actual physical size. Consequently,
the thumb detection, which contains an absolute size component,
needs to be updated. Remedied with this patch.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sat, 16 Oct 2010 09:32:41 +0000 (11:32 +0200)]
Enable integrated button support for the Magic Trackpad
The magic trackpad has an integrated button. This patch detects
the integrated button which enables the special logic for those devices.
Signed-off-by: Henrik Rydberg <rydberg@bitmath.org>
Henrik Rydberg [Tue, 12 Oct 2010 13:42:47 +0000 (15:42 +0200)]
Remove usage of deprecated xalloc/xfree
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 24 Jun 2010 09:33:22 +0000 (11:33 +0200)]
Remove credits now found in the mtdev library
Henrik Rydberg [Thu, 17 Jun 2010 23:57:33 +0000 (01:57 +0200)]
Use a non-blocking example instead of blocking
The non-blocking example is more interesting in the X applications.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 17 Jun 2010 23:47:41 +0000 (01:47 +0200)]
Improve error handling in mtouch open and close
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 17 Jun 2010 23:51:34 +0000 (01:51 +0200)]
Only check delayed gestures when queue is empty
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Tue, 12 Oct 2010 13:38:43 +0000 (15:38 +0200)]
Same version, but using the mtdev library.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Mon, 21 Jun 2010 16:56:49 +0000 (18:56 +0200)]
Simplify event reading
This patch puts the reading code more in line with the upcoming
mtdev library, and should remove some spurious input behavior.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 17 Jun 2010 13:20:49 +0000 (15:20 +0200)]
Move tapping parameter to memory.c
The tapping was not properly turned off by the parameter, resulting
in spurious clicks when typing. This patch moves the tapping parameter
logic to memory.c, which fixes the problem.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 17 Jun 2010 11:17:27 +0000 (13:17 +0200)]
Make MT_ABS_SIZE available for all kernel versions
The code erroneously had MT_ABS_SIZE defined only for kernels
before 2.6.36. Fixed with this patch.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Wed, 16 Jun 2010 16:58:06 +0000 (18:58 +0200)]
Multitouch 1.0-beta1
Henrik Rydberg [Wed, 16 Jun 2010 16:48:53 +0000 (18:48 +0200)]
Add tapping logic
This patch adds tap-to-click, tap-and-hold for dragging, two-finger
and three-finger taps. Turned on by default for touch screens only;
switch on in gestures.c.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Wed, 16 Jun 2010 08:24:09 +0000 (10:24 +0200)]
Correct mtdev API names
The mtdev queue api functions had wrong names. This patch changes
them to the familiar put and get.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Tue, 15 Jun 2010 20:57:38 +0000 (22:57 +0200)]
Increase stability against thumb and edge touches
Sliding a thumb along the upper edge of the pad results in
spurious pointer motion. This patch increases the delays before
moving close to the pad edges, and increase the relaxation time
after a thumb detection, reducing the effect somewhat.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Tue, 15 Jun 2010 20:29:37 +0000 (22:29 +0200)]
Increase event buffer size
The MT devices produce a lot of data. This patch increases the
buffer size to a value empirically found working well for up to
ten fingers.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Tue, 15 Jun 2010 20:07:31 +0000 (22:07 +0200)]
Control grabbing by parameter
Add a parameter to control whether the underlying device
should be grabbed or not. Default to yes.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Wed, 16 Jun 2010 00:32:51 +0000 (02:32 +0200)]
janitor: Simplify gesture handling
Use the bit traversal functions where possible.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Tue, 15 Jun 2010 20:01:02 +0000 (22:01 +0200)]
janitor: Simplify gesture tracing
It is more convenient to print out the gesture at will than
having trace commands all over the code.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Wed, 16 Jun 2010 00:30:41 +0000 (02:30 +0200)]
refactor: Replace hwdata by mtdev
This patch makes the switch, from using hwdata and the associated
type A parser, to using mtdev and the associated type B parser.
A command-line gesture test program is included.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Tue, 15 Jun 2010 19:05:52 +0000 (21:05 +0200)]
refactor: Introduce mtdev
With the addition of the kernel MT slots, the MT event protocol
is capable of efficiently propagating changes to a set of tracked
contacts. At the same time, the need to treat a variety of different
kernel drivers is increased. This patch introduces the mtdev, an
abstract MT device which converts all valid MT event formats into
a uniform, slotted type B event stream. A command-line test program
is included.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Tue, 15 Jun 2010 18:32:14 +0000 (20:32 +0200)]
refactor: Use the bitmask_t type
Use the bitmask_t for all bitfields, to simplify future expansions
to larger bit fields.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Tue, 15 Jun 2010 18:24:14 +0000 (20:24 +0200)]
refactor: Simplify capabilities
Use the generated abs2mt mapping to simplify the MT device
capabilities.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Tue, 15 Jun 2010 17:40:34 +0000 (19:40 +0200)]
refactor: Generate code for ABS_MT mapping
Use the kernel-provided list MT_SLOT_ABS_EVENTS to generate
code mappings between ABS_MT space and MT space. This patch
adds the program mapgen that does the mapping, and adds two
include files generated with it.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Wed, 16 Jun 2010 00:27:32 +0000 (02:27 +0200)]
refactor: Move files
Move all headers into include, separate source files into modules
match, mtdev, src and driver, move some common definitions to
common.h, and include define support for the MT slot protocol.
This patch does not introduce any logical changes.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sun, 16 May 2010 22:32:26 +0000 (00:32 +0200)]
Allow ABI_XINPUT versions greater than 7
The current code does not allow ABI_XINPUT versions above 7,
although the relevant parts are still good. This patch makes
all new versions behave as version 7, until proven otherwise.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 13 May 2010 21:21:37 +0000 (23:21 +0200)]
Add rotation gesture
Moving two fingers around a center point will trigger the gesture.
This patch computes the rotation gesture and maps it to mouse buttons
14 and 15.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 13 May 2010 21:21:37 +0000 (23:21 +0200)]
Add scale gesture
Moving two fingers apart or closer together will trigger the gesture.
This patch computes the scaling gesture and maps it to mouse buttons
12 and 13.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 13 May 2010 21:21:37 +0000 (23:21 +0200)]
Hold movement while clicking
In particular for trackpads with integrated button, freezing the mouse
movement while clicking is important for pointer precision. This
patch holds the movement while clicking, obtaining the desired effect.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 13 May 2010 21:21:37 +0000 (23:21 +0200)]
Disable motion with resting thumbs
Disable motion gestures whenever one of the pointing fingers is a
thumb. Movement is skipped rather than held, minimizing unpredictable
movement after thumb release.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 13 May 2010 23:30:05 +0000 (01:30 +0200)]
Add resting thumb detection to MTFinger
Robust thumb detection is essential for more advanced gestures, thumbs
being responsible for many false positives. One major feature of the
thumb is that its shape is oval, regardless of applied pressure. An
index finger pressed hard against the surface also turns oval, but the
touch/width ratio then increases significantly. This suggests that it
is possible to uniquely identify a resting thumb as a finger with oval
shape and normal touch/with ratio.
This patch adds detection of resting thumbs to the MTFinger structure.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 13 May 2010 23:29:38 +0000 (01:29 +0200)]
Refactor parsor memory usage
Add the bitmasks "fingers" and "added" to parsor memory, and extend
time handling to use a hold time and a forget time.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 13 May 2010 23:29:05 +0000 (01:29 +0200)]
janitor: Split gesture code into memory refresh and parse
Split the gesture code into a lexical part, which updates the filtered
motion state, and a parsing part, which translates the motion state to
gestures.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 13 May 2010 23:15:14 +0000 (01:15 +0200)]
Add convenience methods for distance to capability center point
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 13 May 2010 23:14:04 +0000 (01:14 +0200)]
Introduce MTFinger structure
Switch from the FingerData structure to the MTFinger structure, making
room for more computed finger details in MTState.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 13 May 2010 23:10:17 +0000 (01:10 +0200)]
janitor: Move min/max and dist functions up to common.h
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 13 May 2010 23:09:42 +0000 (01:09 +0200)]
Simplify bit bookkeeping
In preparation of adding several additional finger bit registers,
remove the redundant bit-counting variables and introduce fast
bit-traversal functions instead.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 13 May 2010 23:09:42 +0000 (01:09 +0200)]
Add a README
The github likes readme files, so add a rudimentary one.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Mon, 19 Apr 2010 11:16:54 +0000 (13:16 +0200)]
Increase touch/width signal-to-noise ratio
The current signal-to-noise ratio for the touch size is much too low,
making the pointer feel too insensitive. This patch increases the
ratio from 15 to 100.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sun, 18 Apr 2010 14:25:54 +0000 (16:25 +0200)]
Only emit multi-finger button events for real button events
The current implementation will emit additional multi-finger click
events if, for instance, one finger is removed before releasing the
button. This patch makes sure logical buttons events are only emitted
as a result of a real button event.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sun, 18 Apr 2010 14:22:56 +0000 (16:22 +0200)]
Hold MT data during pure button events
Some devices send button events through a separate device, causing the
driver to temporarily lose the MT state. As a result, spurious button
events are emitted in conjunction with multi-finger clicks.
This patch makes sure that the MT state is updated only after
receiving MT data, restoring click normality.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sun, 18 Apr 2010 07:10:36 +0000 (09:10 +0200)]
Filter non-zero finger width events
Add filtering also to touch/width events, but be careful to treat a zero
touch exactly as zero.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sun, 18 Apr 2010 07:54:06 +0000 (09:54 +0200)]
Make all movement computations work on pointing subset
In the current implementation this patch has no effect, but with
any change to the logic, it will. Add the lines missing in order
to loop over pointing fingers.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sat, 17 Apr 2010 19:42:52 +0000 (21:42 +0200)]
Do not reuse tracking ids after a no-touch event
The fingers going away are important in the matching algorithm,
to correctly detect new fingers when placed close to a finger
in the process of leaving the surface. However, once a no-touch
has been confirmed, the tracking id should not be reused, should
a new finger appear close to the removal point.
This patch clears the tracking id of all removed or no-touch state
fingers, thereby reducing accidental jumps on touch to a minimum.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sat, 17 Apr 2010 18:45:31 +0000 (20:45 +0200)]
Correctly report zero fingers
This bug has been around since before alpha1, and yet the topic
of commit c7ed4c, prior to alpha1, was about precisely this; With
the bug, the last tracking id will sometimes be continued with a
new touch, resulting in a cursor jump.
This patch correctly sets zero fingers in HWData after receiving
a zero-finger event.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 15 Apr 2010 19:37:24 +0000 (21:37 +0200)]
Reset scroll state on finger configuration change
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>
Henrik Rydberg [Thu, 15 Apr 2010 19:29:30 +0000 (21:29 +0200)]
Unify detection of finger configuration changes
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>
Henrik Rydberg [Thu, 15 Apr 2010 17:33:39 +0000 (19:33 +0200)]
Reset accumulated movement at finger configuration change
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>
Henrik Rydberg [Thu, 15 Apr 2010 17:44:39 +0000 (19:44 +0200)]
janitor: Use more common row/column names
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 15 Apr 2010 04:08:42 +0000 (06:08 +0200)]
Multitouch 1.0-alpha2
Henrik Rydberg [Wed, 14 Apr 2010 13:41:39 +0000 (15:41 +0200)]
Add memory debug convenience routines
Output parsing memory values, switched off by default.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Wed, 14 Apr 2010 13:39:44 +0000 (15:39 +0200)]
Extract moving fingers
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>
Arturo Castro [Wed, 14 Apr 2010 13:34:46 +0000 (15:34 +0200)]
Extract pointing fingers
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>
Henrik Rydberg [Wed, 14 Apr 2010 09:23:01 +0000 (11:23 +0200)]
Add constant clicking area to capabilities
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>
Henrik Rydberg [Sun, 11 Apr 2010 13:27:11 +0000 (15:27 +0200)]
Add integrated button property to capabilities
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>
Henrik Rydberg [Sun, 11 Apr 2010 13:24:28 +0000 (15:24 +0200)]
Additional device information
Add information about the device name and device identifier from the
EVIO protocol.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Wed, 14 Apr 2010 14:07:17 +0000 (16:07 +0200)]
Define swipe gestures
Define three-finger vertical and horizontal scroll as vertical and
horizontal swipe gestures.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sun, 11 Apr 2010 12:15:09 +0000 (14:15 +0200)]
Define swipe buttons
Define four additional buttons to be used for swiping gestures.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sun, 11 Apr 2010 12:19:04 +0000 (14:19 +0200)]
Break out scrolling code
Move the duplicated scrolling code to a function.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Arturo Castro [Sun, 11 Apr 2010 09:06:24 +0000 (11:06 +0200)]
Drop movement during gesture decay
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>
Henrik Rydberg [Sat, 10 Apr 2010 22:30:33 +0000 (00:30 +0200)]
Add a gesture credits section
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Arturo Castro [Sat, 10 Apr 2010 22:21:38 +0000 (00:21 +0200)]
Delay movement after a finger configuration change
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>
Henrik Rydberg [Sat, 10 Apr 2010 23:25:50 +0000 (01:25 +0200)]
Add robust position event filtering
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>
Henrik Rydberg [Sat, 10 Apr 2010 21:18:02 +0000 (23:18 +0200)]
Keep logical buttons separate from the hardware ones
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>
Henrik Rydberg [Sat, 10 Apr 2010 21:16:29 +0000 (23:16 +0200)]
Only extract movement from identical finger configurations
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>
Henrik Rydberg [Sat, 10 Apr 2010 21:14:06 +0000 (23:14 +0200)]
Reorganize gesture code
Break out extraction of movement, buttons and type. Only code
traversal, no logical changes.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sat, 10 Apr 2010 21:11:59 +0000 (23:11 +0200)]
Introduce Memory
Add the Memory structure to hold the multitouch parsing state.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sat, 10 Apr 2010 19:06:14 +0000 (21:06 +0200)]
Do not sort HWState fingers
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>
Henrik Rydberg [Sat, 10 Apr 2010 21:03:46 +0000 (23:03 +0200)]
Add MTState debug output
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sat, 10 Apr 2010 20:57:26 +0000 (22:57 +0200)]
Introduce the MTState
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>
Henrik Rydberg [Mon, 29 Mar 2010 21:50:05 +0000 (23:50 +0200)]
Rename State to HWState
Rename the hardware state struct State to HWState, to make
room for additional state structures.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Arturo Castro [Sun, 28 Mar 2010 08:22:34 +0000 (10:22 +0200)]
Reverse the order of the hscroll buttons
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>
Henrik Rydberg [Sun, 28 Mar 2010 11:29:51 +0000 (13:29 +0200)]
Use the event source time instead of the arrival time
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>
Henrik Rydberg [Tue, 23 Mar 2010 08:56:21 +0000 (09:56 +0100)]
Third time around (and use the next branch for collaboration)
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>
Henrik Rydberg [Thu, 15 Apr 2010 04:07:08 +0000 (06:07 +0200)]
Multitouch 1.0-alpha1
Henrik Rydberg [Sun, 21 Mar 2010 14:27:36 +0000 (15:27 +0100)]
Correct double commit mistake
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>
Henrik Rydberg [Sun, 21 Mar 2010 13:54:15 +0000 (14:54 +0100)]
Add millisecond event times
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>
Henrik Rydberg [Sun, 21 Mar 2010 13:18:56 +0000 (14:18 +0100)]
Comply with MT syncronization protocol
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>
Henrik Rydberg [Sun, 21 Mar 2010 13:57:42 +0000 (14:57 +0100)]
Add support for the ABS_MT_PRESSURE event
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>
Henrik Rydberg [Sat, 20 Mar 2010 13:20:51 +0000 (14:20 +0100)]
Remove unused min/max definitions
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Sat, 20 Mar 2010 13:18:16 +0000 (14:18 +0100)]
Matcher: convert distance matrix to integer
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>
Henrik Rydberg [Sat, 20 Mar 2010 12:39:50 +0000 (13:39 +0100)]
Matcher: support up to 32 fingers
Make the matcher support up to 32 fingers instead of the current 16.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Thu, 18 Mar 2010 20:14:48 +0000 (21:14 +0100)]
Introduce convenience function for device dimensions
The capability names are rather lengthy; this patch adds convenience
functions for the dimension capabilities.
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Henrik Rydberg [Tue, 2 Feb 2010 17:27:40 +0000 (18:27 +0100)]
janitor: remaining indentation fixed
Henrik Rydberg [Mon, 1 Feb 2010 21:03:33 +0000 (22:03 +0100)]
janitor: stick to kernel-style formatting
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
Henrik Rydberg [Mon, 1 Feb 2010 21:00:55 +0000 (22:00 +0100)]
janitor: match: stick to kernel-style formatting
Henrik Rydberg [Mon, 1 Feb 2010 19:31:05 +0000 (20:31 +0100)]
button: simplify property mapping
Janitory changes only.