CN106325702A - Mouse gesture identification method and apparatus - Google Patents

Mouse gesture identification method and apparatus Download PDF

Info

Publication number
CN106325702A
CN106325702A CN201510397490.8A CN201510397490A CN106325702A CN 106325702 A CN106325702 A CN 106325702A CN 201510397490 A CN201510397490 A CN 201510397490A CN 106325702 A CN106325702 A CN 106325702A
Authority
CN
China
Prior art keywords
mouse
moving direction
moving
cursor
mouse gestures
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201510397490.8A
Other languages
Chinese (zh)
Other versions
CN106325702B (en
Inventor
徐华荣
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201510397490.8A priority Critical patent/CN106325702B/en
Publication of CN106325702A publication Critical patent/CN106325702A/en
Application granted granted Critical
Publication of CN106325702B publication Critical patent/CN106325702B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Position Input By Displaying (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The invention discloses a mouse gesture identification method. The method comprises the steps of receiving a mouse gesture triggering instruction, acquiring a cursor position according to a moving trend of a cursor corresponding to a mouse in a moving period, obtaining at least one sampling point, and taking a moving trend direction of a sampling point as a primary moving direction of the cursor; converting the moving direction into corresponding identification codes, and generating an identification sequence by all the identification codes in the moving period; and searching for operation corresponding to the identification sequence in a database, and executing the operation. The invention furthermore discloses a mouse gesture identification apparatus. According to the method and the apparatus, a mouse gesture is converted into a simple identification sequence, so that a terminal can obtain the identification sequence corresponding to the mouse gesture only by identifying the moving direction of the cursor corresponding to the mouse, and the accuracy of identifying the mouse gesture is effectively improved; and the correlation between the mouse gesture and the operation function is more visual, so that a user does not need to memorize a tedious mapping relationship particularly, and the user operation is more convenient.

Description

The method and apparatus of mouse gestures identification
Technical field
The present invention relates to Internet technical field, the method and apparatus being related specifically to mouse gestures identification.
Background technology
User is when interacting with terminal, and most commonly used input equipment is exactly keyboard and mouse.Especially During the use of application, more operation can by mouse click on menu on application interface and Operational controls realizes various function.In order to make mouse action convenient and diversified, answering in terminal Add mouse gestures in and extend the operating function of mouse.Mouse gestures pins right mouse button exactly, And on the screen of terminal, draw specific track, realize the function of correspondence.But, due to the most eventually It is not the most the highest for holding the recognition accuracy to mouse track, and existing mouse gestures is the most fairly simple, The most to the left, to the right, upwards, downwards, first left back under, first go up rear left etc., although these gestures are simply, But with associating intuitively between operating function, user generally requires the function remembeing that mouse gestures is corresponding, Could realize correct operation, user operation is caused certain trouble by the contrary, has limited to mouse gestures Use.
Summary of the invention
The embodiment of the present invention provides the method and apparatus of a kind of mouse gestures identification, it is possible to identify complicated Mus Mark gesture, make between mouse gestures with operating function associate more directly perceived, user-friendly.
The embodiment of the present invention proposes a kind of mouse gestures and knows method for distinguishing, including step:
Receive mouse gestures triggering command, move according to the light target that mouse is corresponding in a moving period Trend gathers cursor position, it is thus achieved that at least one sampled point, by the mobile trend side of a described sampled point To as described moving direction of smooth target;
Described moving direction is converted to the identification code of correspondence, and by all identifications in described moving period Code generates a recognition sequence;
In data base, search the operation that described recognition sequence is corresponding, and perform described operation.
The embodiment of the present invention also proposes the device of a kind of mouse gestures identification, including:
Command reception module, is used for receiving mouse gestures triggering command;
Tracking module, for gathering according to the light target mobile trend that mouse is corresponding in a moving period Cursor position, it is thus achieved that at least one sampled point, using the mobile trend direction of a described sampled point as institute State moving direction of light target;
Identification module, for being converted to the identification code of correspondence, and by described mobile week by described moving direction All identification codes in phase generate a recognition sequence;
Operation module, for searching the operation that described recognition sequence is corresponding in data base, and performs described Operation.
Mouse gestures is converted to simple recognition sequence by the embodiment of the present invention, and terminal has only to identify mouse Corresponding light target moving direction, i.e. can obtain the recognition sequence corresponding to mouse gestures, no matter mouse hand Gesture is the most complicated, and terminal can obtain the recognition sequence of correspondence, makes the accuracy of mouse gestures identification obtain It is effectively improved;Simultaneously as associating between mouse gestures with operating function is more directly perceived, user need not Remember loaded down with trivial details mapping relations especially, make user more convenient to operate.
Accompanying drawing explanation
Fig. 1 is total line chart of the device place terminal of mouse gestures identification in the embodiment of the present invention;
Fig. 2 is the flow chart that mouse gestures of the present invention knows method for distinguishing first embodiment;
Fig. 3 is the flow chart that mouse gestures of the present invention knows method for distinguishing the second embodiment;
Fig. 4 is the flow chart that mouse gestures of the present invention knows method for distinguishing the 3rd embodiment;
Fig. 5 is the flow chart that mouse gestures of the present invention knows method for distinguishing the 4th embodiment;
Fig. 6 is the flow chart that mouse gestures of the present invention knows method for distinguishing the 5th embodiment;
Fig. 7 is the flow chart that mouse gestures of the present invention knows method for distinguishing sixth embodiment;
Fig. 8 is the module diagram of the device first embodiment of mouse gestures identification of the present invention;
Fig. 9 is the module diagram of device second embodiment of mouse gestures identification of the present invention;
Figure 10 a is the schematic diagram of mouse gestures motion track first embodiment in the embodiment of the present invention;
Figure 10 b is the schematic diagram of mouse gestures motion track the second embodiment in the embodiment of the present invention;
Figure 10 c is the schematic diagram of mouse gestures motion track the 3rd embodiment in the embodiment of the present invention;
Figure 10 d is the schematic diagram of mouse gestures motion track the 4th embodiment in the embodiment of the present invention.
The realization of the object of the invention, functional characteristics and advantage will in conjunction with the embodiments, do referring to the drawings further Explanation.
Detailed description of the invention
Should be appreciated that specific embodiment described herein, only in order to explain the present invention, is not used to limit Determine the present invention.
Total line chart with reference to the device place terminal that Fig. 1, Fig. 1 are mouse gestures identification in the embodiment of the present invention. This terminal may include that at least one processor 101, such as CPU, at least one network interface 104, User interface 103, memorizer 105, at least one communication bus 102.Wherein, communication bus 102 is used for Realize the connection communication between these assemblies.Wherein, user interface 103 can include display screen (Display), Keyboard (Keyboard), it is also possible to include the wireline interface of standard, wave point.Network interface 104 can To include the wireline interface of standard, wave point (such as WIFI interface).Memorizer 105 can be high-speed RAM Memorizer, it is also possible to be non-labile memorizer (non-volatile memory), for example, at least one Disk memory.Memorizer 105 can also is that at least one is located remotely from the storage of aforementioned processor 101 dress Put.As the memorizer 105 of a kind of computer-readable storage medium can include operating system, network service mould Block, Subscriber Interface Module SIM and mouse gestures recognizer.
The mouse gestures identification shown in Fig. 1 device institute in the terminal, network interface 104 is mainly used in Connection Service device or other-end, carry out data communication with server or other-end;And user interface 103 It is mainly used in receiving user instruction, and interacts with user;And processor 101 may be used for calling and deposits The mouse gestures recognizer of storage in reservoir 105, and perform following operation:
Mouse gestures triggering command is received by user interface 103;
Cursor position is gathered according to the light target mobile trend that mouse is corresponding in a moving period, it is thus achieved that At least one sampled point, once moves the mobile trend direction of a described sampled point as described smooth target Dynamic direction;
Described moving direction is converted to the identification code of correspondence, and by all identifications in described moving period Code generates a recognition sequence;
In data base, search the operation that described recognition sequence is corresponding, and perform described operation.
In one embodiment, the mouse gestures recognizer of storage during processor 101 calls memorizer 105 Can also carry out following operation:
The identification code that the most described moving direction is corresponding is searched successively from described data base;
Judge that the identification code that adjacent twice moving direction is corresponding is the most identical;
If it is, any one retained in two same identification codes;
If it is not, then identification code corresponding to adjacent twice moving direction all retains;
The identification code of reservation is arranged in order according to the sequencing of corresponding described moving direction, generates institute State recognition sequence.
In one embodiment, the mouse gestures recognizer of storage during processor 101 calls memorizer 105 Can also carry out following operation:
Described cursor position is gathered according to the sampling time arranged or sampled distance in a moving period, Obtain multiple sampled point;
Using the direction vector of adjacent two sampled points as described moving direction of smooth target.
In one embodiment, the mouse gestures recognizer of storage during processor 101 calls memorizer 105 Can also carry out following operation:
Sampled point and mobile post-sampling point before using adjacent two sampled points as the movement once moved;
Obtain described light be marked on the sample point coordinate before this moves (x1, y1) and this move after adopt Sampling point coordinate (x2, y2);
Judge that whether this sliding distance | x2-x1 | moving in X-axis of described cursor is more than or equal at Y Sliding distance | y2-y1 | on axle;
If it is, as x2-x1 > 0 time, determine that this moving direction of described cursor is for the right;When X2-x1 < when 0, determines that this moving direction of described cursor is for the left;
If it is not, then as y2-y1 > 0 time, determine that this moving direction of described cursor is for upwards;When Y2-y1 < when 0, determines that this moving direction of described cursor is downward.
In one embodiment, the mouse gestures recognizer of storage during processor 101 calls memorizer 105 Can also carry out following operation:
When mouse gestures triggering button is pressed, obtains described light and be marked on the seat of the sampled point before moving first Sample point coordinate (x02, y02) after marking (x01, y01) and moving first;
X-axis sliding distance | x02-x01 | moved first when described cursor or Y-axis sliding distance | y02-y01 | During more than or equal to slip threshold value, generate mouse gestures triggering command, and described movement first is counted institute State in moving period.
In one embodiment, the mouse gestures recognizer of storage during processor 101 calls memorizer 105 Can also carry out following operation:
Mouse gestures custom instruction is received by user interface 103;
Light mark is gathered according to the light target mobile trend that mouse is corresponding in a self-defined moving period Put, it is thus achieved that at least one sampled point, using the mobile trend direction of a described sampled point as described cursor A moving direction;
Described moving direction is converted to the identification code of correspondence, and by the institute in described self-defined moving period Identification code is had to generate a recognition sequence;
Receive the option of operation of typing on option of operation menu;
By operation association corresponding with described option of operation for described recognition sequence, and it is stored in data base.
The device of the mouse gestures identification described by the present embodiment Fig. 1 and place terminal thereof, by mouse gestures Being converted to simple recognition sequence, terminal has only to identify the light target moving direction that mouse is corresponding, Obtaining the recognition sequence corresponding to mouse gestures, no matter mouse gestures is the most complicated, and it is right that terminal can obtain The recognition sequence answered, makes the accuracy of mouse gestures identification effectively improve;Simultaneously as mouse hand Associating between gesture with operating function is more directly perceived, and user need not remember loaded down with trivial details mapping relations especially, makes User operation is convenient.
As in figure 2 it is shown, Fig. 2 is the flow chart that mouse gestures of the present invention knows method for distinguishing first embodiment. The mouse gestures that the present embodiment is mentioned knows method for distinguishing, including:
Step S10, receives mouse gestures triggering command;
In the present embodiment, starting up mouse gesture on user's application interface in terminal, generate mouse gestures Triggering command.Such as user presses the gesture of mouse and triggers button, such as right button or middle key, or presses key Specific keys on dish, and sliding mouse while keeping down state, then terminal judges now to trigger Mouse gestures, enters mouse gestures recognizer.Or mouse is streaked specific region, or click on application Specific operational controls on interface, or the mouse specific track of slip, can serve as triggering mouse hand The entry condition of gesture.
Step S20, gathers light mark according to the light target mobile trend that mouse is corresponding in a moving period Put, it is thus achieved that at least one sampled point, using the mobile trend direction of a described sampled point as described cursor A moving direction;
When user presses mouse gestures triggering button, a moving period starts, mouse continuous moving, and User is always maintained at mouse gestures triggering button and is in down state, then mouse is still a moving period In, until user decontrols the gesture of mouse and triggers button or mouse and leave terminal screen, then a mobile week Phase terminates.During mouse continuous moving, might not move in same direction, user can control mouse Draw various track, such as letter, numeral, circle, polygon etc., the even Chinese on a terminal screen Word can also realize.Certainly, owing to mouse can not leave terminal screen, when utilizing mouse to draw track, Needing continuous print to complete, the stroke order having some letters or Chinese character may not be according to conventional stroke Sequentially, it is only necessary to complete mobile according to user-defined stroke order.For the word that lines are changeable Mother, numeral, word and shape, the direction that cursor of mouse moves is the most various, at a moving period Nei Bao Include the motion track repeatedly changed direction.
In order to identify the figure that mouse is drawn, need first to identify what light target corresponding to mouse moved Direction.When light is marked on mobile, a mobile trend can be there is, for having the movement of identical mobile trend Coordinate points on track, mobile trend direction is the most identical, the most only gathers on this mobile trend one and adopts Sampling point can obtain the direction of this mobile trend.When cursor repeatedly converts moving direction, cursor is current Mobile trend corresponding to coordinate points changes the most therewith, gathers one when cursor being converted each time to mobile trend Individual sampled point, and obtain the mobile trend direction of this sampled point, the mobile trend side that current sampling point is corresponding To can serve as moving direction of light target.To be combined by moving direction each time, paint the most at last Make a complete figure, be the content that user is drawn on a terminal screen by mouse.Such as, In Figure 10 a the moving direction of numeral " 3 " be successively right, under, left and right, under, left, word in Figure 10 b The moving direction of female " G " is left, down, right, upper, left and right successively, letter " A " in Figure 10 c Moving direction is upper right, bottom right, upper left, the right side successively, can also only be controlled by all of moving direction in addition Make in the range of up and down, such as in Figure 10 d the moving direction of letter " A " be successively upper and lower, Left and right or upper and lower, upper, left and right.
Step S30, is converted to the identification code of correspondence by moving direction, and by all identifications in moving period Code generates a recognition sequence;
Being preset with in the terminal and each moving direction identification code one to one, such as left identification code is L, right identification code be R, on identification code be U, under identification code be D, the identification code of upper right is [RU], The identification code of bottom right is [RD], and the identification code of upper left is [LU], and the identification code of lower-left is [LD], by mouse The identification code that gesture moving direction is corresponding sorts according to the sequencing of motion track, constitutes one for table Show that this moves the recognition sequence of gesture, such as the identification sequence that in Figure 10 a, the moving direction of numeral " 3 " is corresponding Recognition sequence corresponding to moving direction being classified as in RDLRDL, Figure 10 b letter " G " is LDRULR, The recognition sequence that in Figure 10 c, the moving direction of letter " A " is corresponding is in [RU] [RD] [LU] R, Figure 10 d The recognition sequence that the moving direction of letter " A " is corresponding is UDLR or UDULR.
Step S40, searches the operation that recognition sequence is corresponding in data base, and performs operation.
Mouse gestures, recognition sequence, the one-to-one relationship of operation content it is preset with in terminal database, When default corresponding relation, can arrange according to the characteristic of operation content and compare mouse gestures intuitively, Such as in the operation " starting google search engine ", characteristic information is " google ", predeterminable letter " G " For the mouse gestures of this operation, then the recognition sequence LDRULR of letter " G " " is started google with operation Search engine " set up corresponding relation intuitively, when the mouse gestures that user slides on screen is " G ", " G " is converted to the recognition sequence LDRULR of correspondence by terminal, and finds correspondence from data base Operation " starts google search engine ", and performs this operation, shows that browser is opened on a terminal screen Google search interface.
Mouse gestures is converted to simple recognition sequence by the present embodiment, and terminal has only to identify that mouse is corresponding Light target moving direction, i.e. can obtain the recognition sequence corresponding to mouse gestures, no matter mouse gestures is many Complicated, terminal can obtain the recognition sequence of correspondence, makes the accuracy of mouse gestures identification obtain effectively Improve;Simultaneously as associating between mouse gestures with operating function is more directly perceived, user need not be special Remember loaded down with trivial details mapping relations, make user more convenient to operate.
As it is shown on figure 3, Fig. 3 is the flow chart that mouse gestures of the present invention knows method for distinguishing the second embodiment. The present embodiment includes the institute in embodiment illustrated in fig. 2 in steps, further detailed to generating recognition sequence Illustrating, step S30 includes:
Step S31, searches the identification code that moving direction is corresponding each time from data base successively;
Step S32, it is judged that the identification code that adjacent twice moving direction is corresponding is the most identical;If it is, hold Row step S33;If it is not, then perform step S34;
Step S33, retains any one in two same identification codes;
Step S34, the identification code that adjacent twice moving direction is corresponding all retains;
Step S35, is arranged in order the identification code of reservation according to the sequencing of corresponding moving direction, raw Become recognition sequence.
The present embodiment is when generating recognition sequence, suitable according to the priority of light target moving direction corresponding to mouse Sequence, successively by corresponding identification code sequence, generates recognition sequence.The mode generating recognition sequence can be After all of moving direction is all identified, change in corresponding identification code simultaneously, sort the most successively; Can also be first to identify first moving direction, it is thus achieved that first identification code, first identification code is put into In recognition sequence, then identify second moving direction, it is thus achieved that second identification code, by second identification code Join in recognition sequence, by that analogy.The mode of recognition sequence is generated, with Figure 10 b for the second As a example by, first moving direction of letter " G " is left, it is thus achieved that first identification code L, adds and identifies sequence In row, now recognition sequence is L;Under second moving direction is, it is thus achieved that second identification code D, add In recognition sequence, now recognition sequence is LD;3rd moving direction is right, it is thus achieved that the 3rd identification code R, adds in recognition sequence, and now recognition sequence is LDR;By that analogy, until user decontrols mouse Or mouse leaves terminal screen, the recognition sequence finally given is LDRULR.
In view of user when controlling mouse and sliding, owing to user's self reason causes cursor of mouse to move not Stable, the situation such as sliding trace shake, therefore the identification code that some repeat can be filtered out.Right In the mode of the first generation recognition sequence above-mentioned, compare the knowledge that former and later two adjacent moving directions are corresponding Other code is the most identical, if identical, then two corresponding moving directions are also identical or approximation, Being possibly due to when gripping mouse there occurs shake, the moving direction causing mouse there occurs a little skew, And then obtain two identical or moving directions of approximation, now only by a guarantor in adjacent two identification codes Stay in recognition sequence.And above-mentioned the second is generated to the mode of recognition sequence, due to identification code It is to add in recognition sequence one by one, then has only to obtaining an identification code corresponding to moving direction After, it is compared with last identification code in recognition sequence, namely once obtains with front The identification code that moving direction is corresponding compares, if both are identical, then abandons this identification code obtained, as Fruit differs, and is just added in recognition sequence by this identification code.
The present embodiment uses simple recognition sequence to replace complicated mouse gestures, makes to identify in recognition sequence The sequencing of the moving direction moving generation with cursor of mouse that puts in order of code keeps consistent, mouse hand The accuracy of gesture identification effectively improves;Simultaneously by one that adjacent two identification codes repeat from identifying sequence Row exclude, it is to avoid the direction skew caused because of mouse shake, further increase mouse gestures and know Other accuracy.
As shown in Figure 4, Fig. 4 is the flow chart that mouse gestures of the present invention knows method for distinguishing the 3rd embodiment. The present embodiment includes the institute in embodiment illustrated in fig. 2 in steps, further corresponding to obtaining mouse light Target moving direction describes in detail, and step S20 includes:
Step S21, gathers light mark according to the sampling time arranged or sampled distance in a moving period Put, it is thus achieved that multiple sampled points;
Step S22, using the direction vector of adjacent two sampled points as moving direction of light target;
The present embodiment, when determining light target moving direction, according to time or the distance of system setting, gathers Cursor of mouse position on a display screen, the multiple mouse focal positions collected are exactly multiple sampled points. The sampling interval arranged or sampling can use equal time interval or distance interval, it is possible to use specific The sampling time of Changing Pattern or sampled distance, or use random sampling time or sampled distance etc. multiple Mode is optional.Exist between adjacent two sampled points and point to later sampled point B from previous sampled point A Direction vector, this direction vector is exactly that cursor of mouse is adopted to later from the position of previous sampled point A The direction that the position of sampling point B is moved, also corresponds to the mobile trend direction of previous sampled point A.This reality Execute example and determine light target moving direction by the direction vector of two sampled points, make moving direction of cursor Determine simpler, convenient, fast.
As it is shown in figure 5, Fig. 5 is the flow chart that mouse gestures of the present invention knows method for distinguishing the 4th embodiment. The present embodiment includes the institute in embodiment illustrated in fig. 4 in steps, and step S22 includes:
Step S23, using adjacent two sampled points as the movement once moved before sampled point and mobile after Sampled point;
In the present embodiment, exist between adjacent two sampled points and point to later sampling from previous sampled point The direction vector of point, this direction vector is exactly that cursor of mouse is sampled to later from previous sampling point position The direction that some position is moved, also corresponds to a moving direction of mouse.Before in adjacent two sampled points One sampled point is as sampled point, the shifting that later sampled point moves as this before this movement moved Dynamic post-sampling point.
Step S24, obtains light and is marked on the sample point coordinate before this moves (x1, y1) and after this moves Sample point coordinate (x2, y2);
Mouse light when terminal have recorded mouse moving direction changes each time in a moving period The sample point coordinate that mark is corresponding.And the sample point coordinate value before and after movement is subtracted each other, obtains this mouse The sliding distance that cursor moves.Sliding distance in X-axis is | x2-x1 |, the sliding distance in Y-axis For | y2-y1 |.
Step S25, it is judged that whether this sliding distance | x2-x1 | moved in X-axis of cursor is more than or equal to Sliding distance | y2-y1 | in Y-axis;If it is, perform step S26;If it is not, then execution step S27;
When cursor of mouse sliding distance in X-axis is more than or equal to the sliding distance in Y-axis, then Judge that mouse moves left and right, when cursor of mouse sliding distance in X-axis is less than the slip in Y-axis During distance, then judge that mouse moves up and down.
Step S26, compares x2-x1>0 or x2-x1<0;
Step S261, as x2-x1 > 0 time, determine that this moving direction of cursor is for the right;
Step S262, when x2-x1 < when 0, determines that this moving direction of cursor is for the left;
After judging cursor of mouse transverse movement, when cursor of mouse sliding distance in X-axis is more than 0, Then judge that mouse moves right, when cursor of mouse sliding distance in X-axis is less than 0, then judge mouse It is moved to the left, when cursor of mouse sliding distance in X-axis is equal to 0, then mouse does not move.
Step S27, compares y2-y1>0 or y2-y1<0;
Step S271, as y2-y1 > 0 time, determine that this moving direction of cursor is for upwards;
Step S272, when y2-y1 < when 0, determines that this moving direction of cursor is downward.
After judging cursor of mouse lengthwise movement, when cursor of mouse sliding distance in Y-axis is more than 0, Then judge that mouse moves up, when cursor of mouse sliding distance in Y-axis is less than 0, then judge mouse Move down, when cursor of mouse sliding distance in Y-axis is equal to 0, then mouse does not move.
In order to make direction discernment simpler, the present embodiment has only to upper and lower, left and right four direction It is identified, the incline directions such as upper left, lower-left, upper right, bottom right are all simplified to upper and lower, left and right In four direction.Such as, if the moving direction of letter " A " is according to complete recognition method, then such as figure Shown in 10c, moving direction is upper right, bottom right, upper left, the right side successively, the recognition sequence that moving direction is corresponding For [RU] [RD] [LU] R, and if letter " A " is according to the recognition method that this embodiment simplifies, the most such as Shown in Figure 10 d, moving direction is upper and lower, left and right successively, and the recognition sequence that moving direction is corresponding is UDLR.Meanwhile, inaccurate situation is moved, such as by water in order to avoid user when drawing mouse gestures Horizontal line or vertical curve are depicted as the situation of oblique line, and therefore the present embodiment is by upper left, lower-left, upper right, bottom right All it is simplified in the four direction of upper and lower, left and right Deng incline direction, direction discernment can be made more accurate.
As shown in Figure 6, Fig. 6 is the flow chart that mouse gestures of the present invention knows method for distinguishing the 5th embodiment. The present embodiment includes the institute in embodiment illustrated in fig. 2 in steps, further to generating mouse gestures triggering Instruction describes in detail, also includes before step S10:
Step S51, when mouse gestures triggering button is pressed, obtains light and is marked on the sampling before moving first Point coordinates (x01, y01) and the sample point coordinate (x02, y02) after moving first;
Step S52, X-axis sliding distance | the x02-x01 | moved first when cursor or Y-axis sliding distance When | y02-y01 | is more than or equal to slip threshold value, generates mouse gestures triggering command, and will move first and count In moving period.
It can be the right button of mouse or middle key that the mouse gestures of the present embodiment triggers button, or clicks on a left side simultaneously Any two or three in key, right button and middle key, or some on keyboard or multiple specific keys.When Mouse gestures triggers button and is pressed, and while being maintained at down state, sliding mouse, terminal record Sample point coordinate before and after mouse moves first in a moving period.For getting rid of, user is touched unintentionally Encountering mouse gestures and trigger the situation of button, terminal has preset slip threshold value, when mouse is in X-axis or Y-axis On sliding distance when reaching slip threshold value, terminal judges now to trigger mouse gestures, enters mouse hand Gesture recognizer, otherwise terminal is judged to user misoperation, does not processes, and is effectively increased mouse gestures The accuracy identified.
As it is shown in fig. 7, Fig. 7 is the flow chart that mouse gestures of the present invention knows method for distinguishing sixth embodiment. The present embodiment includes the institute in embodiment illustrated in fig. 2 in steps, further detailed to self-defined mouse gestures Describe in detail bright, also include before step S10:
Step S61, receives mouse gestures custom instruction;
The terminal database of the present embodiment is preset with between mouse gestures and operating function and maps pass intuitively System, facilitates user to remember and operates.In order to provide the mouse gestures more enriched, terminal also user oriented Provide the approach of self-defined mouse gestures, user can according to the use habit of oneself, voluntarily change or Add mouse gestures.When user clicks on the control adding or changing mouse gestures on application interface, touch Send out mouse gestures custom instruction, enter self-defined pattern.
Step S62, gathers according to the light target mobile trend that mouse is corresponding in a self-defined moving period Cursor position, it is thus achieved that at least one sampled point, using the mobile trend direction of a sampled point as light target Moving direction;
Now in a self-defined moving period, user moves mouse and draws gesture path.Such as, false If right mouse button is mouse gestures triggers button, then, after entering self-defined pattern, user clicks on right mouse Key, and keep right button to be in sliding mouse while down state, track drafting, it is thus achieved that multiple mouse light Target moving direction.
Step S63, is converted to the identification code of correspondence by moving direction, and by the institute in self-defined moving period Identification code is had to generate a recognition sequence;
Moving direction being converted into identification code, and generates recognition sequence, its process can refer to previous embodiment The principle of middle generation recognition sequence, therefore not to repeat here.For ensureing to draw the accuracy of mouse gestures, After completing once to draw, terminal can point out user to repeat to draw, if the mouse gestures of twice drafting is identical, The recognition sequence then obtained is the most identical, then it is assumed that mouse gestures is completed, and otherwise prompts the user whether defeated Enter wrong, mouse gestures please be repaint.
Step S64, receives the option of operation of typing on option of operation menu;
After completing moving direction identification and generating recognition sequence, ejection operation options menu, point out user This mouse gestures is selected to need the operation of association.Multiple behaviour preset is included in option of operation menu Make option, the operation sequence on these option of operation correspondence backstages.
Step S65, by operation association corresponding with option of operation for recognition sequence, and is stored in data base.
User is selecting after option of operation, and click determines, option of operation that user is selected by terminal and mouse The recognition sequence association of gesture.Such as, the mouse gestures that user completes is letter " G ", corresponding identification Sequence is LDRULR, and the option of operation that user selects is " starting google search engine ", then terminal By letter " G ", recognition sequence LDRULR and operation " startup google search engine " one_to_one corresponding, And be stored in data base, complete the self-defined association of mouse gestures.
The present embodiment has provided a user with the approach of self-defined mouse gestures, and user is according to use habit voluntarily Change or add mouse gestures, make between mouse gestures with operating function associate more directly perceived, it is simple to use Family memory and operation, and provided the user more abundant mouse gestures, make the application of mouse gestures more Add extensively.
As shown in Figure 8, Fig. 8 be mouse gestures identification of the present invention device first embodiment module signal Figure.The device of the mouse gestures identification that the present embodiment is mentioned, including:
Command reception module 210, is used for receiving mouse gestures triggering command;
Tracking module 220, for adopting according to the light target mobile trend that mouse is corresponding in a moving period Collection cursor position, it is thus achieved that at least one sampled point, using the mobile trend direction of a described sampled point as Moving direction of described smooth target;
Identification module 230, for being converted to the identification code of correspondence, and by moving period by moving direction All identification codes generate a recognition sequence;
Operation module 240, for searching the operation that recognition sequence is corresponding in data base, and performs operation.
In the present embodiment, starting up mouse gesture on user's application interface in terminal, generate mouse gestures Triggering command.Such as user presses the gesture of mouse and triggers button, such as right button or middle key, or presses key Specific keys on dish, and sliding mouse while keeping down state, then terminal judges now to trigger Mouse gestures, enters mouse gestures recognizer.Or mouse is streaked specific region, or click on application Specific operational controls on interface, or the mouse specific track of slip, can serve as triggering mouse hand The entry condition of gesture.
When user presses mouse gestures triggering button, a moving period starts, mouse continuous moving, and User is always maintained at mouse gestures triggering button and is in down state, then mouse is still a moving period In, until user decontrols the gesture of mouse and triggers button or mouse and leave terminal screen, then a mobile week Phase terminates.During mouse continuous moving, might not move in same direction, user can control mouse Draw various track, such as letter, numeral, circle, polygon etc., the even Chinese on a terminal screen Word can also realize.Certainly, owing to mouse can not leave terminal screen, when utilizing mouse to draw track, Needing continuous print to complete, the stroke order having some letters or Chinese character may not be according to conventional stroke Sequentially, it is only necessary to complete mobile according to user-defined stroke order.For the word that lines are changeable Mother, numeral, word and shape, the direction that cursor of mouse moves is the most various, at a moving period Nei Bao Include the motion track repeatedly changed direction.
In order to identify the figure that mouse is drawn, need first to identify the direction that cursor of mouse moves.Light When being marked on mobile, a mobile trend can be there is, for having on the motion track of identical mobile trend Coordinate points, mobile trend direction is the most identical, the most only gathers a sampled point on this mobile trend Obtain the direction of this mobile trend.When cursor repeatedly converts moving direction, the coordinate points pair that cursor is current The mobile trend answered changes the most therewith, gathers a sampled point when cursor being converted each time to mobile trend, And obtaining the mobile trend direction of this sampled point, the mobile trend direction that current sampling point is corresponding just can be made For moving direction of light target.Will each time moving direction be combined, draw out the most at last one complete Whole figure, is the content that user is drawn on a terminal screen by mouse.Such as, number in Figure 10 a The moving direction of word " 3 " be successively right, under, left and right, under, left, letter " G " in Figure 10 b Moving direction is left, down, right, upper, left and right successively, and in Figure 10 c, the moving direction of letter " A " depends on Secondary is upper right, bottom right, upper left, the right side, can also only control all of moving direction in upper bottom left in addition In right scope, such as in Figure 10 d, the moving direction of letter " A " is upper and lower, left and right successively, or Upper and lower, upper, left and right.
Being preset with in the terminal and each moving direction identification code one to one, such as left identification code is L, right identification code be R, on identification code be U, under identification code be D, the identification code of upper right is [RU], The identification code of bottom right is [RD], and the identification code of upper left is [LU], and the identification code of lower-left is [LD], by mouse The identification code that gesture moving direction is corresponding sorts according to the sequencing of motion track, constitutes one for table Show that this moves the recognition sequence of gesture, such as the identification sequence that in Figure 10 a, the moving direction of numeral " 3 " is corresponding Recognition sequence corresponding to moving direction being classified as in RDLRDL, Figure 10 b letter " G " is LDRULR, The recognition sequence that in Figure 10 c, the moving direction of letter " A " is corresponding is in [RU] [RD] [LU] R, Figure 10 d The recognition sequence that the moving direction of letter " A " is corresponding is UDLR or UDULR.
Mouse gestures, recognition sequence, the one-to-one relationship of operation content it is preset with in terminal database, When default corresponding relation, can arrange according to the characteristic of operation content and compare mouse gestures intuitively, Such as in the operation " starting google search engine ", characteristic information is " google ", predeterminable letter " G " For the mouse gestures of this operation, then the recognition sequence LDRULR of letter " G " " is started google with operation Search engine " set up corresponding relation intuitively, when the mouse gestures that user slides on screen is " G ", " G " is converted to the recognition sequence LDRULR of correspondence by terminal, and finds correspondence from data base Operation " starts google search engine ", and performs this operation, shows that browser is opened on a terminal screen Google search interface.
Mouse gestures is converted to simple recognition sequence by the present embodiment, and terminal has only to identify that mouse is corresponding Light target moving direction, i.e. can obtain the recognition sequence corresponding to mouse gestures, no matter mouse gestures is many Complicated, terminal can obtain the recognition sequence of correspondence, makes the accuracy of mouse gestures identification obtain effectively Improve;Simultaneously as associating between mouse gestures with operating function is more directly perceived, user need not be special Remember loaded down with trivial details mapping relations, make user more convenient to operate.
Further, in order to generate recognition sequence, identification module 230 is additionally operable to:
The identification code that moving direction is corresponding each time is searched successively from data base;
Judge that the identification code that adjacent twice moving direction is corresponding is the most identical;
If it is, any one retained in two same identification codes;
If it is not, then identification code corresponding to adjacent twice moving direction all retains;
The identification code of reservation is arranged in order according to the sequencing of corresponding moving direction, generates and identify sequence Row.
The present embodiment is when generating recognition sequence, suitable according to the priority of light target moving direction corresponding to mouse Sequence, successively by corresponding identification code sequence, generates recognition sequence.The mode generating recognition sequence can be After all of moving direction is all identified, change in corresponding identification code simultaneously, sort the most successively; Can also be first to identify first moving direction, it is thus achieved that first identification code, first identification code is put into In recognition sequence, then identify second moving direction, it is thus achieved that second identification code, by second identification code Join in recognition sequence, by that analogy.The mode of recognition sequence is generated, with Figure 10 b for the second As a example by, first moving direction of letter " G " is left, it is thus achieved that first identification code L, adds and identifies sequence In row, now recognition sequence is L;Under second moving direction is, it is thus achieved that second identification code D, add In recognition sequence, now recognition sequence is LD;3rd moving direction is right, it is thus achieved that the 3rd identification code R, adds in recognition sequence, and now recognition sequence is LDR;By that analogy, until user decontrols mouse Or mouse leaves terminal screen, the recognition sequence finally given is LDRULR.
In view of user when controlling mouse and sliding, owing to user's self reason causes cursor of mouse to move not Stable, the situation such as sliding trace shake, therefore the identification code that some repeat can be filtered out.Right In the mode of the first generation recognition sequence above-mentioned, compare the knowledge that former and later two adjacent moving directions are corresponding Other code is the most identical, if identical, then two corresponding moving directions are also identical or approximation, Being possibly due to when gripping mouse there occurs shake, the moving direction causing mouse there occurs a little skew, And then obtain two identical or moving directions of approximation, now only by a guarantor in adjacent two identification codes Stay in recognition sequence.And above-mentioned the second is generated to the mode of recognition sequence, due to identification code It is to add in recognition sequence one by one, then has only to obtaining an identification code corresponding to moving direction After, it is compared with last identification code in recognition sequence, namely once obtains with front The identification code that moving direction is corresponding compares, if both are identical, then abandons this identification code obtained, as Fruit differs, and is just added in recognition sequence by this identification code.
The present embodiment uses simple recognition sequence to replace complicated mouse gestures, makes to identify in recognition sequence The sequencing of the moving direction moving generation with cursor of mouse that puts in order of code keeps consistent, mouse hand The accuracy of gesture identification effectively improves;Simultaneously by one that adjacent two identification codes repeat from identifying sequence Row exclude, it is to avoid the direction skew caused because of mouse shake, further increase mouse gestures and know Other accuracy.
Further, the light target moving direction corresponding in order to obtain mouse, tracking module 220 is additionally operable to:
Cursor position is gathered according to the sampling time arranged or sampled distance in a moving period, it is thus achieved that Multiple sampled points;
Using the direction vector of adjacent two sampled points as moving direction of light target.
The present embodiment, when determining light target moving direction, according to time or the distance of system setting, gathers Cursor of mouse position on a display screen, the multiple mouse focal positions collected are exactly multiple sampled points. The sampling interval arranged or sampling can use equal time interval or distance interval, it is possible to use specific The sampling time of Changing Pattern or sampled distance, or use random sampling time or sampled distance etc. multiple Mode is optional.Exist between adjacent two sampled points and point to later sampled point B from previous sampled point A Direction vector, this direction vector is exactly that cursor of mouse is adopted to later from the position of previous sampled point A The direction that the position of sampling point B is moved, also corresponds to the mobile trend direction of previous sampled point A.This reality Execute example and determine light target moving direction by the direction vector of two sampled points, make moving direction of cursor Determine simpler, convenient, fast.
Further, tracking module 220 is additionally operable to:
Sampled point and mobile post-sampling point before using adjacent two sampled points as the movement once moved;
Obtain light be marked on the sample point coordinate before this moves (x1, y1) and this move after sampled point Coordinate (x2, y2);
Judge that whether this sliding distance | x2-x1 | moving in X-axis of cursor is more than or equal in Y-axis Sliding distance | y2-y1 |;
If it is, as x2-x1 > 0 time, determine that this moving direction of cursor is for the right;As x2-x1 < 0 Time, determine that this moving direction of cursor is for the left;
If it is not, then as y2-y1 > 0 time, determine that this moving direction of cursor is for upwards;As y2-y1 < 0 Time, determine that this moving direction of cursor is downward.
In the present embodiment, exist between adjacent two sampled points and point to later sampling from previous sampled point The direction vector of point, this direction vector is exactly that cursor of mouse is sampled to later from previous sampling point position The direction that some position is moved, also corresponds to a moving direction of mouse.Before in adjacent two sampled points One sampled point is as sampled point, the shifting that later sampled point moves as this before this movement moved Dynamic post-sampling point.When terminal have recorded mouse moving direction change each time in a moving period Sample point coordinate corresponding to cursor of mouse.And the sample point coordinate value before and after movement is subtracted each other, obtains The sliding distance that this cursor of mouse moves.Sliding distance in X-axis is | x2-x1 |, in Y-axis Sliding distance is | y2-y1 |.The sliding distance being marked in X-axis when light is more than or equal to the slip in Y-axis During distance, then judging that mouse moves left and right, the sliding distance being marked in X-axis when light is less than in Y-axis Sliding distance time, then judge mouse move up and down.After judging cursor of mouse transverse movement, work as Mus The sliding distance that mark light is marked in X-axis more than 0, then judges that mouse moves right, when cursor of mouse is at X Sliding distance on axle is less than 0, then judge that mouse is moved to the left, when cursor of mouse slip in X-axis Distance is equal to 0, then mouse does not move.After judging cursor of mouse lengthwise movement, when cursor of mouse is at Y Sliding distance on axle is more than 0, then judge that mouse moves up, when cursor of mouse slip in Y-axis Distance less than 0, then judges that mouse moves down, when cursor of mouse sliding distance in Y-axis is equal to 0, Then mouse does not move.
In order to make direction discernment simpler, the present embodiment has only to upper and lower, left and right four direction It is identified, the incline directions such as upper left, lower-left, upper right, bottom right are all simplified to upper and lower, left and right In four direction.Such as, if the moving direction of letter " A " is according to complete recognition method, then such as figure Shown in 10c, moving direction is upper right, bottom right, upper left, the right side successively, the recognition sequence that moving direction is corresponding For [RU] [RD] [LU] R, and if letter " A " is according to the recognition method that this embodiment simplifies, the most such as Shown in Figure 10 d, moving direction is upper and lower, left and right successively, and the recognition sequence that moving direction is corresponding is UDLR.Meanwhile, inaccurate situation is moved, such as by water in order to avoid user when drawing mouse gestures Horizontal line or vertical curve are depicted as the situation of oblique line, and therefore the present embodiment is by upper left, lower-left, upper right, bottom right All it is simplified in the four direction of upper and lower, left and right Deng incline direction, direction discernment can be made more accurate.
Further, in order to generate mouse gestures triggering command, tracking module 220 is additionally operable to:
When mouse gestures triggering button is pressed, obtains light and be marked on the sample point coordinate before moving first (x01, y01) and the sample point coordinate (x02, y02) after moving first;
X-axis sliding distance | x02-x01 | or Y-axis sliding distance | y02-y01 | of moving first when cursor are more than Or during equal to slip threshold value, generate mouse gestures triggering command, and will move first and count in moving period.
It can be the right button of mouse or middle key that the mouse gestures of the present embodiment triggers button, or clicks on a left side simultaneously Any two or three in key, right button and middle key, or some on keyboard or multiple specific keys.When Mouse gestures triggers button and is pressed, and while being maintained at down state, sliding mouse, terminal record Sample point coordinate before and after mouse moves first in a moving period.For getting rid of, user is touched unintentionally Encountering mouse gestures and trigger the situation of button, terminal has preset slip threshold value, when mouse is in X-axis or Y-axis On sliding distance when reaching slip threshold value, terminal judges now to trigger mouse gestures, enters mouse hand Gesture recognizer, otherwise terminal is judged to user misoperation, does not processes, and is effectively increased mouse gestures The accuracy identified.
As it is shown in figure 9, the module signal of device the second embodiment that Fig. 9 is mouse gestures identification of the present invention Figure.The present embodiment includes all modules in embodiment illustrated in fig. 8, further for realizing self-defined Mus Mark gesture, also add typing module 250 and relating module 260;
Command reception module 210 is additionally operable to, and receives mouse gestures custom instruction;
Tracking module 220 is additionally operable to, according to the light target that mouse is corresponding in a self-defined moving period Mobile trend gathers cursor position, it is thus achieved that at least one sampled point, the movement of a described sampled point is become Gesture direction is as described moving direction of smooth target;
Identification module 230 is additionally operable to, and moving direction is converted to the identification code of correspondence, and by self-defined shifting All identification codes in the dynamic cycle generate a recognition sequence;
Typing module 250 is used for, and receives the option of operation of typing on option of operation menu;
Relating module 260 is used for, and by operation association corresponding with option of operation for recognition sequence, and is stored in In data base.
The terminal database of the present embodiment is preset with between mouse gestures and operating function and maps pass intuitively System, facilitates user to remember and operates.In order to provide the mouse gestures more enriched, terminal also user oriented Provide the approach of self-defined mouse gestures, user can according to the use habit of oneself, voluntarily change or Add mouse gestures.When user clicks on the control adding or changing mouse gestures on application interface, touch Send out mouse gestures custom instruction, enter self-defined pattern.Now in a self-defined moving period, User moves mouse and draws gesture path.For example, it is assumed that right mouse button is mouse gestures triggers button, then Entering after self-defined pattern, user clicks on right mouse button, and while keeping right button to be in down state Sliding mouse, track drafting, it is thus achieved that the light target moving direction that multiple mouses are corresponding.Moving direction is turned Changing identification code into, and generate recognition sequence, its process can refer to generate in previous embodiment recognition sequence Principle, therefore not to repeat here.For ensureing to draw the accuracy of mouse gestures, after completing once to draw, Terminal can point out user to repeat to draw, if the mouse gestures of twice drafting is identical, then and the identification sequence obtained Arrange the most identical, then it is assumed that mouse gestures is completed, otherwise prompt the user whether to input wrong, the most again Draw mouse gestures.After completing moving direction identification and generating recognition sequence, ejection operation options menu, Prompting user selects this mouse gestures to need the operation of association.Option of operation menu include multiple pre- If good option of operation, the operation sequence on these option of operation correspondence backstages.User is selecting option of operation After, click determines, the option of operation that user is selected by terminal associates with the recognition sequence of mouse gestures.Example As, the mouse gestures that user completes is letter " G ", and corresponding recognition sequence is LDRULR, Yong Huxuan The option of operation selected is " starting google search engine ", then terminal is by letter " G ", recognition sequence LDRULR and operation " startup google search engine " one_to_one corresponding, and be stored in data base, complete Become the self-defined association of mouse gestures.
The present embodiment has provided a user with the approach of self-defined mouse gestures, and user is according to use habit voluntarily Change or add mouse gestures, make between mouse gestures with operating function associate more directly perceived, it is simple to use Family memory and operation, and provided the user more abundant mouse gestures, make the application of mouse gestures more Add extensively.
It should be noted that in this article, term " include ", " comprising " or its any other variant Be intended to comprising of nonexcludability so that include the process of a series of key element, method, article or Person's device not only includes those key elements, but also includes other key elements being not expressly set out, or also Including the key element intrinsic for this process, method, article or device.In the feelings not having more restriction Under condition, statement " including ... " key element limited, it is not excluded that include this key element process, Method, article or device there is also other identical element.
The invention described above embodiment sequence number, just to describing, does not represent the quality of embodiment.
Through the above description of the embodiments, those skilled in the art is it can be understood that arrive above-mentioned Embodiment method can add the mode of required general hardware platform by software and realize, naturally it is also possible to logical Cross hardware, but a lot of in the case of the former is more preferably embodiment.Based on such understanding, the present invention's The part that prior art is contributed by technical scheme the most in other words can be with the form body of software product Revealing to come, this computer software product is stored in a storage medium (such as ROM/RAM, magnetic disc, light Dish) in, including some instructions with so that a station terminal equipment (can be mobile phone, computer, service Device, or the network equipment etc.) perform the method described in each embodiment of the present invention.
The foregoing is only the preferred embodiments of the present invention, not thereby limit the scope of the claims of the present invention, Every equivalent structure utilizing description of the invention and accompanying drawing content to be made or equivalence flow process conversion, or directly Or indirectly it is used in other relevant technical fields, the most in like manner it is included in the scope of patent protection of the present invention.

Claims (12)

1. a mouse gestures knows method for distinguishing, it is characterised in that include step:
Receive mouse gestures triggering command, move according to the light target that mouse is corresponding in a moving period Trend gathers cursor position, it is thus achieved that at least one sampled point, by the mobile trend side of a described sampled point To as described moving direction of smooth target;
Described moving direction is converted to the identification code of correspondence, and by all identifications in described moving period Code generates a recognition sequence;
In data base, search the operation that described recognition sequence is corresponding, and perform described operation.
2. mouse gestures as claimed in claim 1 knows method for distinguishing, it is characterised in that described by described Moving direction is converted to the identification code of correspondence, and all identification codes in described moving period are generated one The step of recognition sequence includes:
The identification code that the most described moving direction is corresponding is searched successively from described data base;
Judge that the identification code that adjacent twice moving direction is corresponding is the most identical;
If it is, any one retained in two same identification codes;
If it is not, then identification code corresponding to adjacent twice moving direction all retains;
The identification code of reservation is arranged in order according to the sequencing of corresponding described moving direction, generates institute State recognition sequence.
3. mouse gestures as claimed in claim 1 or 2 knows method for distinguishing, it is characterised in that described Cursor position is gathered according to the light target mobile trend that mouse is corresponding, it is thus achieved that at least one in one moving period Individual sampled point, using the mobile trend direction of a described sampled point as described moving direction of smooth target Step include:
Described cursor position is gathered according to the sampling time arranged or sampled distance in a moving period, Obtain multiple sampled point;
Using the direction vector of adjacent two sampled points as described moving direction of smooth target.
4. mouse gestures as claimed in claim 3 knows method for distinguishing, it is characterised in that described by adjacent The direction vector of two sampled points includes as the step of a described smooth moving direction of target:
Sampled point and mobile post-sampling point before using adjacent two sampled points as the movement once moved;
Obtain described light be marked on the sample point coordinate before this moves (x1, y1) and this move after adopt Sampling point coordinate (x2, y2);
Judge that whether this sliding distance | x2-x1 | moving in X-axis of described cursor is more than or equal at Y Sliding distance | y2-y1 | on axle;
If it is, as x2-x1 > 0 time, determine that this moving direction of described cursor is for the right;When X2-x1 < when 0, determines that this moving direction of described cursor is for the left;
If it is not, then as y2-y1 > 0 time, determine that this moving direction of described cursor is for upwards;When Y2-y1 < when 0, determines that this moving direction of described cursor is downward.
5. mouse gestures as claimed in claim 4 knows method for distinguishing, it is characterised in that described reception Mus Also include before the step of mark gesture triggering command:
When mouse gestures triggering button is pressed, obtains described light and be marked on the seat of the sampled point before moving first Sample point coordinate (x02, y02) after marking (x01, y01) and moving first;
X-axis sliding distance | x02-x01 | moved first when described cursor or Y-axis sliding distance | y02-y01 | During more than or equal to slip threshold value, generate mouse gestures triggering command, and described movement first is counted institute State in moving period.
6. mouse gestures as claimed in claim 1 or 2 knows method for distinguishing, it is characterised in that described in connect Also include before receiving the step of mouse gestures triggering command:
Receive mouse gestures custom instruction, according to the light that mouse is corresponding in a self-defined moving period Target mobile trend gathers cursor position, it is thus achieved that at least one sampled point, by the shifting of a described sampled point Dynamic trend direction is as described moving direction of smooth target;
Described moving direction is converted to the identification code of correspondence, and by the institute in described self-defined moving period Identification code is had to generate a recognition sequence;
Receive the option of operation of typing on option of operation menu;
By operation association corresponding with described option of operation for described recognition sequence, and it is stored in data base.
7. the device of a mouse gestures identification, it is characterised in that including:
Command reception module, is used for receiving mouse gestures triggering command;
Tracking module, for gathering according to the light target mobile trend that mouse is corresponding in a moving period Cursor position, it is thus achieved that at least one sampled point, using the mobile trend direction of a described sampled point as institute State moving direction of light target;
Identification module, for being converted to the identification code of correspondence, and by described mobile week by described moving direction All identification codes in phase generate a recognition sequence;
Operation module, for searching the operation that described recognition sequence is corresponding in data base, and performs described Operation.
8. the device of mouse gestures identification as claimed in claim 7, it is characterised in that described identification mould Block is additionally operable to:
The identification code that the most described moving direction is corresponding is searched successively from described data base;
Judge that the identification code that adjacent twice moving direction is corresponding is the most identical;
If it is, any one retained in two same identification codes;
If it is not, then identification code corresponding to adjacent twice moving direction all retains;
The identification code of reservation is arranged in order according to the sequencing of corresponding described moving direction, generates institute State recognition sequence.
9. the device of as claimed in claim 7 or 8 mouse gestures identification, it is characterised in that described with Track module is additionally operable to:
Described cursor position is gathered according to the sampling time arranged or sampled distance in a moving period, Obtain multiple sampled point;
Using the direction vector of adjacent two sampled points as described moving direction of smooth target.
10. the device of mouse gestures identification as claimed in claim 9, it is characterised in that described tracking Module is additionally operable to:
Sampled point and mobile post-sampling point before using adjacent two sampled points as the movement once moved;
Obtain described light be marked on the sample point coordinate before this moves (x1, y1) and this move after adopt Sampling point coordinate (x2, y2);
Judge that whether this sliding distance | x2-x1 | moving in X-axis of described cursor is more than or equal at Y Sliding distance | y2-y1 | on axle;
If it is, as x2-x1 > 0 time, determine that this moving direction of described cursor is for the right;When X2-x1 < when 0, determines that this moving direction of described cursor is for the left;
If it is not, then as y2-y1 > 0 time, determine that this moving direction of described cursor is for upwards;When Y2-y1 < when 0, determines that this moving direction of described cursor is downward.
The device of 11. mouse gestures identifications as claimed in claim 10, it is characterised in that described tracking Module is additionally operable to:
When mouse gestures triggering button is pressed, obtains described light and be marked on the seat of the sampled point before moving first Sample point coordinate (x02, y02) after marking (x01, y01) and moving first;
X-axis sliding distance | x02-x01 | moved first when described cursor or Y-axis sliding distance | y02-y01 | During more than or equal to slip threshold value, generate mouse gestures triggering command, and described movement first is counted institute State in moving period.
The device of 12. mouse gestures identifications as claimed in claim 7 or 8, it is characterised in that also wrap Include typing module and relating module;
Described command reception module is additionally operable to, and receives mouse gestures custom instruction;
Described tracking module is additionally operable to, according to the light target that mouse is corresponding in a self-defined moving period Mobile trend gathers cursor position, it is thus achieved that at least one sampled point, the movement of a described sampled point is become Gesture direction is as described moving direction of smooth target;
Described identification module is additionally operable to, and described moving direction is converted to the identification code of correspondence, and by described All identification codes in self-defined moving period generate a recognition sequence;
Described typing module is used for, and receives the option of operation of typing on option of operation menu;
Described relating module is used for, by operation association corresponding with described option of operation for described recognition sequence, And be stored in data base.
CN201510397490.8A 2015-07-08 2015-07-08 Method and device for recognizing mouse gestures Active CN106325702B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510397490.8A CN106325702B (en) 2015-07-08 2015-07-08 Method and device for recognizing mouse gestures

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510397490.8A CN106325702B (en) 2015-07-08 2015-07-08 Method and device for recognizing mouse gestures

Publications (2)

Publication Number Publication Date
CN106325702A true CN106325702A (en) 2017-01-11
CN106325702B CN106325702B (en) 2021-01-08

Family

ID=57725562

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510397490.8A Active CN106325702B (en) 2015-07-08 2015-07-08 Method and device for recognizing mouse gestures

Country Status (1)

Country Link
CN (1) CN106325702B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109101274A (en) * 2018-09-20 2018-12-28 上海施嵌电子科技有限公司 Computer peripheral equipment macroefficiency device and its gesture identification method
CN114518830A (en) * 2022-01-20 2022-05-20 广东迅扬科技股份有限公司 Mouse button-free click control identification and system

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101408824A (en) * 2008-11-18 2009-04-15 广东威创视讯科技股份有限公司 Method for recognizing mouse gesticulation
CN101526861A (en) * 2008-03-06 2009-09-09 郑国书 Mouse with gesture operation function
EP2378395A2 (en) * 2008-01-11 2011-10-19 Sony Computer Entertainment Inc. Gesture cataloguing and recognition
KR20120001711A (en) * 2011-11-21 2012-01-04 엔에이치엔(주) System and method for providing web page including mouse gesture function
CN102332024A (en) * 2011-09-30 2012-01-25 奇智软件(北京)有限公司 Touch control type browser for portable mobile terminal
CN102402361A (en) * 2010-09-08 2012-04-04 腾讯科技(深圳)有限公司 Method and device for controlling computer based on movement track of mouse
US20120194431A1 (en) * 2006-09-27 2012-08-02 Yahoo! Inc. Zero-click activation of an application
CN102662581A (en) * 2012-03-31 2012-09-12 奇智软件(北京)有限公司 Method and system for performing control by mouse input
CN103076918A (en) * 2012-12-28 2013-05-01 深圳Tcl新技术有限公司 Remote control method and system based on touch terminal
CN104484115A (en) * 2014-12-01 2015-04-01 林志均 Mouse gesture recognition method

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120194431A1 (en) * 2006-09-27 2012-08-02 Yahoo! Inc. Zero-click activation of an application
EP2378395A2 (en) * 2008-01-11 2011-10-19 Sony Computer Entertainment Inc. Gesture cataloguing and recognition
CN101526861A (en) * 2008-03-06 2009-09-09 郑国书 Mouse with gesture operation function
CN101408824A (en) * 2008-11-18 2009-04-15 广东威创视讯科技股份有限公司 Method for recognizing mouse gesticulation
CN102402361A (en) * 2010-09-08 2012-04-04 腾讯科技(深圳)有限公司 Method and device for controlling computer based on movement track of mouse
CN102332024A (en) * 2011-09-30 2012-01-25 奇智软件(北京)有限公司 Touch control type browser for portable mobile terminal
KR20120001711A (en) * 2011-11-21 2012-01-04 엔에이치엔(주) System and method for providing web page including mouse gesture function
CN102662581A (en) * 2012-03-31 2012-09-12 奇智软件(北京)有限公司 Method and system for performing control by mouse input
CN103076918A (en) * 2012-12-28 2013-05-01 深圳Tcl新技术有限公司 Remote control method and system based on touch terminal
CN104484115A (en) * 2014-12-01 2015-04-01 林志均 Mouse gesture recognition method

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109101274A (en) * 2018-09-20 2018-12-28 上海施嵌电子科技有限公司 Computer peripheral equipment macroefficiency device and its gesture identification method
CN114518830A (en) * 2022-01-20 2022-05-20 广东迅扬科技股份有限公司 Mouse button-free click control identification and system

Also Published As

Publication number Publication date
CN106325702B (en) 2021-01-08

Similar Documents

Publication Publication Date Title
JP6431119B2 (en) System and method for input assist control by sliding operation in portable terminal equipment
CN102360249B (en) Discrete keyboard layout system and method to set up, corresponding mancarried electronic aid and control method
US8577100B2 (en) Remote input method using fingerprint recognition sensor
CN101149804B (en) Self-adaptive hand-written discrimination system and method
CN106293315A (en) The method and apparatus that floating frame shows
CN103186345A (en) Text segment selecting method and field selecting method, device and terminal
WO2000072300A1 (en) Data entry device recording input in two dimensions
CN105468278A (en) Touch screen operation identification and response method and apparatus based on virtual key, and game manipulation method and apparatus
CN107272881B (en) Information input method and device, input method keyboard and electronic equipment
US11429985B2 (en) Information processing device calculating statistical information
WO2014012484A1 (en) Method and system for retrieving contact in electronic device
CN107329687B (en) A kind of display methods and mobile terminal of virtual input keyboard
CN112989776A (en) Method and device for adjusting table columns, storage medium and terminal equipment
CN103116446B (en) A kind of list interactive method for touch portable device
CN105955507B (en) A kind of display methods and terminal of soft keyboard
CN102830919A (en) Method for switching candidate pages in input method of mobile terminal as well as mobile terminal
CN106325702A (en) Mouse gesture identification method and apparatus
CN107291361A (en) The keyboard layout method to set up and device of a kind of input method
US12013987B2 (en) Non-standard keyboard input system
CN106371644B (en) Method and device for simultaneously writing by multiple persons on screen
CN106066706A (en) A kind of data processing method and intelligent terminal
CN115033170A (en) Input control system and method based on virtual keyboard and related device
CN105653188B (en) A kind of operating method and terminal of terminal
CN111176545B (en) Equipment control method, system, electronic equipment and storage medium
CN103076878B (en) display terminal remote control method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant