Natural gesture finger recognition algorithm
Technical Field
The invention relates to a human-computer interaction interface, in particular to rich input primitives in the human-computer interaction interface and recognition of an operating hand and fingers in a multi-point touch interface.
Background
Multipoint touch screen devices, such as smart phones, tablet computers, and touch screens as large as wall bodies, are widely used in daily work, study, and life of people. A touch screen is both an output device and an input device. Touch screen equipment does not have external input devices such as mouse, keyboard usually, and people adopt bare-handed operation above when using touch screen equipment usually: this provides on the one hand convenience of operation; but on the other hand, the input primitives are not rich enough, so that the interaction performance of people is limited. For example, when people input text on a mobile phone or a tablet computer, the existing method mainly uses a single finger to click a soft keyboard for inputting, and the input mode is generally very inefficient compared with the mode of inputting by two hands through a physical keyboard.
If the fingers touching the screen can be recognized and it is determined whether the operator's hand is left or right, then the characters on the physical keyboard can be assigned to the corresponding fingers according to the correct fingering entered by the person on a standard keyboard (QWERTY keyboard): therefore, people can realize an input mode similar to that on a physical keyboard on the multi-point touch screen, the input efficiency of the multi-point touch screen can be close to that on the physical keyboard, and touch typing input can be carried out similarly. More input primitives can be provided for the multi-touch screen through finger recognition, so that people can obtain more interactive instructions during free-hand operation. The finger recognition algorithm supports people to perform blind operation on the multi-point touch screen, and great convenience is provided for the blind to use the multi-point touch screen.
Typical identification methods currently available require specially-made equipment (e.g., documents "Masson D, Goguey A, Malaria S, et al. Whichfingers: Identifying transistors on Touch Surfaces and keys Using vibrations [ C ]// Proceedings of the 30th Annual ACM Symposium on User Interface Software and technology. Quebec City, QC, Canada: ACM,2017: 41-48."), or a camera specifically positioned relative to the operative surface (e.g., documents "Zheng J, volume D. Finger-Aware Shortcuts [ C ]// Proceedings of the CHI 2016 family J, CA, USA: 2016: 4285): such a condition is not provided in a general touch device. The finger recognition algorithm based on image processing has high operation complexity, and can realize good real-time performance of finger recognition only by equipment with high processing capacity.
Disclosure of Invention
The invention provides a finger recognition algorithm based on the contact points of fingers on a touch screen or other operation surfaces, which comprises that the contact point T which is the largest according to the sum of the distances from one contact point to the other 4 contact points is recognized as a thumb contact point T, and the thumb contact point T is shown in a figure 2 and a figure 3; calculating the distances from the rest contacts to the thumb contact, and identifying the index finger contact I according to the distances; calculating geometric center points C of the 5 contact points, and judging whether the operating hand is a left hand or a right hand according to the positive and negative of the cross product of two vectors respectively taking the point C as a starting point and the thumb contact point T and the forefinger contact point I as an end point; calculate 3 vectors starting at C and ending at the remaining 3 fingers
To
In the rotating direction of the finger, the fingers corresponding to the contact points of the 3 vectors are a middle finger, a ring finger and a little finger in sequence.
And calculating the distances from the rest contact points to the thumb contact point T, wherein the contact point with the minimum distance is the index finger contact point I, and the corresponding finger is the index finger.
Drawings
FIG. 1 is a diagram of the effect of algorithm execution, wherein the fingers and their touch points are identified by the initials of the fingers in English (i.e., thumb-T, index finger-I, middle finger-M, ring finger-R, and little finger-L, the fingers in FIGS. 2 and 3 being identified in the same manner);
FIG. 2 is a schematic diagram of the algorithm principle using a right hand as an example, where C is the geometric center point of 5 finger contacts;
fig. 3 is a schematic diagram of the principle of the algorithm with the left hand as an example (C has the same meaning as in fig. 2).
Detailed Description
When 5 contacts touch the interface, triggering the algorithm to execute, firstly obtaining the coordinates of the 5 contacts, and then circularly calculating the sum of the distances from one contact to the other 4 contacts, wherein the largest contact is the thumb contact T.
And calculating the distances from the rest 4 touch points to the point T, wherein the minimum distance is the index finger touch point I.
Calculating the geometric center point C of 5 contact points
And judging whether the manipulator is a left hand or a right hand according to the positive and negative of the cross product.
Calculate 3 vectors with C as the starting point and the remaining 3 finger touch points as the ending point
To
In the rotating direction of the touch screen, the finger contacts corresponding to the 3 vectors are a middle finger contact M, a ring finger contact R and a small finger contact L in sequence.