CN113741750A - Cursor position updating method and device and electronic equipment - Google Patents

Cursor position updating method and device and electronic equipment Download PDF

Info

Publication number
CN113741750A
CN113741750A CN202110998460.8A CN202110998460A CN113741750A CN 113741750 A CN113741750 A CN 113741750A CN 202110998460 A CN202110998460 A CN 202110998460A CN 113741750 A CN113741750 A CN 113741750A
Authority
CN
China
Prior art keywords
cursor
current
determining
angle variation
coordinate
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
CN202110998460.8A
Other languages
Chinese (zh)
Other versions
CN113741750B (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.)
Beijing ByteDance Network Technology Co Ltd
Original Assignee
Beijing ByteDance Network Technology 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 Beijing ByteDance Network Technology Co Ltd filed Critical Beijing ByteDance Network Technology Co Ltd
Priority to CN202110998460.8A priority Critical patent/CN113741750B/en
Publication of CN113741750A publication Critical patent/CN113741750A/en
Application granted granted Critical
Publication of CN113741750B publication Critical patent/CN113741750B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0481Interaction techniques based on graphical user interfaces [GUI] based on specific properties of the displayed interaction object or a metaphor-based environment, e.g. interaction with desktop elements like windows or icons, or assisted by a cursor's changing behaviour or appearance
    • G06F3/04812Interaction techniques based on cursor appearance or behaviour, e.g. being affected by the presence of displayed objects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • G06F3/04847Interaction techniques to control parameter settings, e.g. interaction with sliders or dials

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Position Input By Displaying (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The embodiment of the disclosure discloses a cursor position updating method and device and electronic equipment. One embodiment of the method comprises: determining the displacement to be moved of the cursor according to the current attitude angle variation of the cursor control equipment; determining a first position by offsetting the displacement to be moved from the current position of the cursor; determining a second position coordinate based on a weighted coordinate sum of the first position coordinate and the current position coordinate; and moving the cursor to a second position indicated by the second position coordinate. The embodiment updates the position of the cursor by comprehensively considering the current position of the cursor and the influence proportion of the posture change of the cursor control device.

Description

Cursor position updating method and device and electronic equipment
Technical Field
The embodiment of the disclosure relates to the technical field of computers, and in particular relates to a cursor position updating method and device and electronic equipment.
Background
A cursor may be presented on some display devices and the position of the cursor may be moved. In some scenarios, first, a cursor may be moved to a location on a display device where an object is presented, and then a corresponding operation (e.g., a double-click operation) may be performed on the object.
It will be appreciated that moving the position of the cursor in different ways may give the user a different user experience.
Disclosure of Invention
This disclosure is provided to introduce concepts in a simplified form that are further described below in the detailed description. This disclosure is not intended to identify key features or essential features of the claimed subject matter, nor is it intended to be used to limit the scope of the claimed subject matter.
The embodiment of the disclosure provides a cursor position updating method and device and electronic equipment, and the position of a cursor is updated by comprehensively considering the influence proportion of the current position of the cursor and the posture change of cursor control equipment.
In a first aspect, an embodiment of the present disclosure provides a cursor position updating method, including: determining the displacement to be moved of the cursor according to the current attitude angle variation of the cursor control equipment; determining a first position by offsetting the displacement to be moved from the current position of the cursor; determining a second position coordinate based on a weighted coordinate sum of the first position coordinate and the current position coordinate; and moving the cursor to a second position indicated by the second position coordinate.
In a second aspect, an embodiment of the present disclosure provides a cursor position updating apparatus, including: the first determining unit is used for determining the displacement to be moved of the cursor according to the current attitude angle variation of the cursor control equipment; a second determination unit configured to determine the first position by shifting the displacement to be moved from the current position of the cursor; a third determination unit configured to determine a second position coordinate based on a weighted coordinate sum of the first position coordinate and the current position coordinate; and the moving unit is used for moving the cursor to a second position indicated by the second position coordinate.
In a third aspect, an embodiment of the present disclosure provides an electronic device, including: one or more processors; storage means for storing one or more programs which, when executed by the one or more processors, cause the one or more processors to implement the cursor position updating method according to the first aspect.
In a fourth aspect, an embodiment of the present disclosure provides a computer-readable medium, on which a computer program is stored, which when executed by a processor, implements the steps of the cursor position updating method according to the first aspect.
According to the cursor position updating method and device and the electronic device provided by the embodiment of the disclosure, firstly, the displacement to be moved of the cursor can be determined according to the current attitude angle variation of the cursor control device, then, the first position can be determined by offsetting the displacement to be moved from the current position of the cursor, further, the second position coordinate can be determined based on the weighted coordinate sum of the first position coordinate and the current position coordinate, and finally, the cursor can be moved to the second position indicated by the second position coordinate.
The first position coordinates are determined based on the displacement to be moved, and the displacement to be moved may represent a change in a posture of the cursor control device (i.e., an operation of the cursor control device by the user). Therefore, in this embodiment, the position of the cursor can be updated by comprehensively considering the current position of the cursor and the influence ratio of the posture change of the cursor control device.
Drawings
The above and other features, advantages and aspects of various embodiments of the present disclosure will become more apparent by referring to the following detailed description when taken in conjunction with the accompanying drawings. Throughout the drawings, the same or similar reference numbers refer to the same or similar elements. It should be understood that the drawings are schematic and that elements and features are not necessarily drawn to scale.
FIG. 1 is a flow diagram of some embodiments of a cursor position update method of the present disclosure;
FIG. 2 is a schematic illustration of an azimuth and elevation angle in some embodiments of the cursor position update method of the present disclosure;
FIG. 3 is a flow diagram of a cursor position update method of the present disclosure in determining second position coordinates in some embodiments;
FIG. 4 is a flow diagram of a cursor position update method of the present disclosure in determining a first weight in some embodiments;
FIGS. 5A and 5B are schematic diagrams of moving cursor position;
FIG. 6 is a schematic block diagram of some embodiments of a cursor position updating apparatus of the present disclosure;
FIG. 7 is an exemplary system architecture to which the cursor position update method of the present disclosure may be applied in some embodiments;
fig. 8 is a schematic diagram of a basic structure of an electronic device provided in accordance with some embodiments of the present disclosure.
Detailed Description
Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While certain embodiments of the present disclosure are shown in the drawings, it is to be understood that the present disclosure may be embodied in various forms and should not be construed as limited to the embodiments set forth herein, but rather are provided for a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the disclosure are for illustration purposes only and are not intended to limit the scope of the disclosure.
It should be understood that the various steps recited in the method embodiments of the present disclosure may be performed in a different order, and/or performed in parallel. Moreover, method embodiments may include additional steps and/or omit performing the illustrated steps. The scope of the present disclosure is not limited in this respect.
The term "include" and variations thereof as used herein are open-ended, i.e., "including but not limited to". The term "based on" is "based, at least in part, on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". Relevant definitions for other terms will be given in the following description.
It should be noted that the terms "first", "second", and the like in the present disclosure are only used for distinguishing different devices, modules or units, and are not used for limiting the order or interdependence relationship of the functions performed by the devices, modules or units.
It is noted that references to "a", "an", and "the" modifications in this disclosure are intended to be illustrative rather than limiting, and that those skilled in the art will recognize that "one or more" may be used unless the context clearly dictates otherwise.
The names of messages or information exchanged between devices in the embodiments of the present disclosure are for illustrative purposes only, and are not intended to limit the scope of the messages or information.
Referring to FIG. 1, a flow diagram of some embodiments of a cursor position update method according to the present disclosure is shown. As shown in fig. 1, the cursor position updating method includes the following steps:
step 101, determining the displacement to be moved of the cursor according to the current attitude angle variation of the cursor control device.
In this embodiment, the executing body of the cursor position updating method may determine the displacement to be moved of the cursor according to the current attitude angle variation of the cursor control device.
The cursor manipulation device may be various devices that manipulate a cursor displayed on the display device. The cursor manipulation device may include, but is not limited to, a remote control, a smart phone, a mouse (e.g., an air mouse), and the like.
In practical applications, the executing body may change the direction and the amplitude (i.e., the operation direction and the operation amplitude of the cursor control device by the user) based on the posture of the cursor control device, and move the position of the cursor. Generally, the greater the magnitude of change in the posture of the cursor control device, the greater the magnitude of movement of the cursor.
The current attitude angle change amount may be a current attitude angle change amount of the cursor manipulation device. In some scenarios, the current pose angle change may be determined based on a difference between a current pose angle of the cursor manipulation device and a previous pose angle. The current attitude angle may be a currently determined attitude angle. The previous attitude angle may be a previously determined attitude angle. Alternatively, the previous pose angle may be the previous pose angle (i.e., the previously determined pose angle) of the cursor manipulation device.
It can be understood that the gesture angle variation and the above displacement to be moved may both represent the gesture changing direction and magnitude of the cursor control device (i.e., the operation direction and operation magnitude of the cursor control device by the user).
In some scenarios, the cursor has a preset movement step. The moving step length is the moving length of the cursor responding to the unit attitude angle variation of the cursor control device. As can be seen, the cursor can move the above-mentioned moving step length every time the cursor control device changes the attitude of the unit attitude angle variation. In this case, the execution body may use a product of the current attitude angle variation and the movement step as the displacement to be moved of the cursor.
Step 102, determining a first position by offsetting the displacement to be moved from the current position of the cursor.
In this embodiment, the executing body may determine the first position by offsetting the displacement to be moved from the current position of the cursor.
In some scenarios, the execution body may be configured to shift the position to be moved and displaced from the current position as the first position.
Step 103, determining a second position coordinate based on the weighted coordinate sum of the first position coordinate and the current position coordinate.
In this embodiment, the execution subject may determine the second position coordinate based on a weighted coordinate sum of the first position coordinate and the current position coordinate.
The first location coordinates may be coordinates indicating a first location. The current position coordinates may be coordinates indicating the above current position.
The weighted coordinate sum may be a sum of a weighted coordinate of the first position coordinate and a weighted coordinate of the current position coordinate. As an example, the first weight of the first position coordinate is L1, and the second weight of the above current position coordinate is L2. The first position coordinates are (a, b) and the current position coordinates are (c, d). The weighted coordinates of the first position coordinates are the coordinates determined by "L1 × (a, b)", and the weighted coordinates of the second position coordinates are the coordinates determined by "L2 × (c, d)".
Referring to the previous analysis, the first position coordinates are determined on the basis of the displacement to be moved. Therefore, the second position coordinate is determined on the basis of comprehensively considering the influence ratio of the current position coordinate and the displacement to be moved.
In some scenarios, the execution subject may use a weighted coordinate sum of the first position coordinate and the current position coordinate as the second position coordinate.
And 104, moving the cursor to a second position indicated by the second position coordinate.
In this embodiment, the executing body may move the cursor from the current position to a second position indicated by a second position coordinate.
As can be seen, in this embodiment, after the gesture of the cursor control device is changed, the cursor is not directly moved from the current position by the determined displacement to be moved, but the second position coordinate is determined based on the weighted coordinate sum of the first position coordinate and the current position coordinate, and the cursor is moved to the second position.
Referring to the foregoing analysis, the first position coordinate is determined based on the above displacement to be moved, and the above displacement to be moved may embody a posture change of the cursor control device (i.e., an operation of the cursor control device by the user). Therefore, in this embodiment, the position of the cursor can be updated by comprehensively considering the current position of the cursor and the influence ratio of the posture change of the cursor control device.
In some embodiments, the execution body may determine the current attitude angle change amount of the cursor in the following manner.
Firstly, current posture detection data of cursor control equipment are obtained.
The cursor control device may be equipped with sensors such as accelerometers, gyroscopes and magnetometers. The cursor control device can acquire attitude detection data by using the sensor. The attitude detection data may include an acceleration and an angular velocity of the cursor control device, and a magnetic induction intensity of a position where the cursor control device is located.
In some scenarios, the execution body may acquire gesture detection data from the cursor manipulation device every predetermined length of time (e.g., 10 milliseconds).
The current posture detection data may be currently acquired posture detection data of the cursor control device.
And secondly, determining the current attitude angle of the cursor control equipment according to the current attitude detection data.
Specifically, the executing body may determine the current attitude angle of the cursor control device according to the currently acquired acceleration, angular velocity, and magnetic induction.
And thirdly, taking the difference between the current attitude angle of the cursor control equipment and the previous attitude angle as the current attitude angle variation.
As can be seen, in these embodiments, the amount of change in the attitude angle of the cursor manipulation device can be determined in real time based on the attitude detection data obtained from the cursor manipulation device. Therefore, when the posture of the cursor control device changes, the displacement to be moved of the cursor can be determined in real time, and further, the cursor can timely respond to the posture change of the cursor control device.
In some embodiments, the executing body may determine the displacement of the cursor to be moved in the following manner.
Firstly, determining the moving step length of the cursor according to the current attitude angle variation.
It can be understood that the larger the moving step of the cursor, the higher the response sensitivity of the cursor. Here, the moving step length of the cursor can be reasonably determined according to the current attitude angle variation of the cursor control device.
In some scenarios, if the current attitude angle change amount is less than or equal to the angle change amount threshold, the execution main body may use the first moving step as the moving step of the cursor. If the current attitude angle variation is greater than the angle variation threshold, the execution main body may use the second moving step as the moving step of the cursor. Wherein the second moving step is larger than the first moving step.
And secondly, determining the displacement to be moved of the cursor based on the product of the current attitude angle variation and the moving step length.
In some scenarios, the execution subject may use a product of the current attitude angle variation and the movement step as the displacement to be moved of the cursor.
Therefore, in the embodiments, the displacement to be moved of the cursor is reasonably determined by comprehensively considering the attitude change amplitude of the cursor control device and the response sensitivity of the cursor.
In some embodiments, the attitude angles include azimuth and pitch. It is understood that the attitude angle change amount of the cursor control device includes an azimuth angle change amount and a pitch angle change amount.
Referring to fig. 2, in the spatial coordinate system, the azimuth angle of the cursor control device may be a rotation angle of the cursor control device around the Z-axis, and the pitch angle of the cursor control device may be a rotation angle of the cursor control device around the X-axis.
The azimuth angle may be a left-right movement angle of the cursor control device, and the pitch angle may be a up-down movement angle of the cursor control device. Therefore, the azimuth angle can reflect the posture change of the cursor control device in the horizontal direction, and the pitch angle can reflect the posture change of the cursor control device in the vertical direction.
The execution body may determine the movement step of the cursor in the following manner.
The method comprises the steps of firstly, determining the comprehensive attitude angle variation of the cursor control equipment according to the current azimuth angle variation and the current pitch angle variation of the cursor control equipment.
Regarding the manner of determining the above-mentioned integrated attitude angle variation, reference may be made to the description in other embodiments, and details are not repeated here.
The change amount of the attitude angle of the cursor control equipment and the moving step length of the cursor meet positive correlation.
And secondly, determining a moving step length corresponding to the comprehensive attitude angle variation based on the positive correlation.
In some scenarios, the execution main body may input the integrated attitude angle variation into a predetermined formula, so as to determine a movement step (i.e., a movement step of the cursor) corresponding to the integrated attitude angle variation. The predetermined formula may be various formulas for representing the positive correlation, and is not limited herein.
It can be seen that, in these embodiments, the larger the change amount of the attitude angle of the cursor manipulation device, the larger the movement step size of the cursor. Therefore, the larger the posture change of the cursor control device which can ensure the cursor response is, the higher the response sensitivity of the cursor is.
In some embodiments, the to-be-moved displacement of the cursor includes a lateral to-be-moved displacement and a longitudinal to-be-moved displacement. The execution body may determine the displacement of the cursor to be moved in the following manner.
And step T1, determining the lateral displacement to be moved of the cursor based on the product of the current azimuth angle variation of the cursor control device and the moving step length.
And step T2, determining the longitudinal displacement to be moved of the cursor based on the product of the current pitch angle variation of the cursor control device and the moving step length.
In some scenarios, the execution body may use a product of the current azimuth angle variation and the moving step as a lateral to-be-moved displacement of the cursor, and use a product of the current pitch angle variation and the moving step as a longitudinal to-be-moved displacement of the cursor.
After determining the lateral to-be-moved displacement and the longitudinal to-be-moved displacement, the execution main body may laterally offset the lateral to-be-moved displacement and longitudinally offset the longitudinal to-be-moved displacement from the current position of the cursor as the first position.
In some embodiments, the executing entity may execute steps 301 to 302 shown in fig. 3 and determine the second position coordinates according to step 303 shown in fig. 3.
Step 301, determining a first weight of the first position coordinate according to the current attitude angle variation.
In some scenarios, if the current attitude angle variation is greater than or equal to a preset angle variation threshold, the executing entity may select a larger weight as the first weight. If the current attitude angle variation is smaller than a preset angle variation threshold, the execution subject may select a smaller weight as the first weight.
Step 302, determining a second weight of the current position coordinate according to the first weight.
The first weight and the second weight may be values in the interval of [0, 1 ].
Alternatively, the difference between 1 and the first weight is used as the second weight of the current position coordinate.
Step 303, determining a second position coordinate based on the weighted coordinate sum of the first position coordinate and the current position coordinate by using the first weight and the second weight.
As an example, the first weight of the first position coordinate is L1, and the second weight of the current position coordinate is "1-L1". The first position coordinates are (a, b) and the current position coordinates are (c, d). The weighted coordinates of the first position coordinates are the coordinates determined by "L1 × (a, b)", and the weighted coordinates of the second position coordinates are the coordinates determined by "(1-L1) × (c, d)".
In some scenarios, the execution subject may use a weighted coordinate sum of the first position coordinate and the current position coordinate as the second position coordinate.
Referring to the foregoing analysis, the current attitude angle variation may represent an attitude change of the cursor manipulation device. It can be seen that in these embodiments, a first weight for the first location coordinates and a second weight for the current location described above can be determined based on a change in the pose of the cursor manipulation device. Therefore, the influence proportion of the current position of the cursor and the posture change of the cursor control device can be reasonably determined.
In some embodiments, the execution subject may determine the first weight according to a process shown in fig. 4, which includes the following steps.
Step 401, determining a comprehensive attitude angle variation of the cursor control device according to a current azimuth angle variation and a current pitch angle variation of the cursor control device.
In some scenarios, the executing body may use an average of the current azimuth angle variation and the current pitch angle variation as a comprehensive attitude angle variation of the cursor control device.
It can be understood that the posture changes of the cursor control device in the horizontal direction and the vertical direction can be comprehensively embodied by synthesizing the posture angle variation.
Step 402, if the change amount of the comprehensive attitude angle is greater than or equal to a preset angle threshold, selecting a first weight from a first numerical interval.
In step 403, if the integrated attitude angle variation is smaller than the preset angle threshold, a first weight is selected from the second numerical interval.
The values in the second interval are less than or equal to the values in the first interval.
As can be seen, in these embodiments, the first weight and the second weight are determined by comprehensively considering the magnitude of the posture change of the cursor control device in the horizontal direction and the vertical direction (i.e., the magnitude of the operation of the cursor control device by the user in the horizontal direction and the vertical direction).
It is easy to find that if the integrated attitude angle variation of the cursor control device is large, the first weight of the first position coordinate is also large. If the comprehensive attitude angle change amount of the cursor control device is smaller, the first weight of the first position coordinate is also smaller. Therefore, if the posture change range of the cursor control device is large, the influence proportion occupied by the posture change of the cursor control device is large. If the gesture change amplitude of the cursor control device is smaller, the influence proportion occupied by the gesture change of the cursor control device is smaller. Thus, the cursor can respond almost negligibly to small changes in the pose of the cursor manipulation device.
As an example, in the course of a user moving a cursor from position a to position D through the cursor manipulation device, the cursor manipulation device makes two consecutive small changes in posture followed by a large change in posture. Referring to FIG. 5A, if the cursor changes in response to any gesture of the cursor manipulation device, the cursor moves in sequence from position A to position B, C, D. At this time, the cursor may be jumped on the display screen in a messy manner. This phenomenon is more prominent particularly when the response sensitivity of the cursor is high. Referring to FIG. 5B, if the cursor ignores small changes in pose in response to the cursor manipulation device, the cursor moves directly from position A to position D. At this time, smooth movement of the cursor on the display screen can be achieved.
In some embodiments, the execution body may determine the integrated attitude angle change amount of the cursor manipulation device in the following manner.
First, a square root result of a sum of a square of the current azimuth angle variation and a square of the current pitch angle variation is determined.
And secondly, determining the variation of the comprehensive attitude angle according to the square root result value.
In some scenarios, the execution subject may determine the square root result as a combined attitude angle change of the cursor control device. As an example, the current azimuth angle variation is m, and the current pitch angle variation is n. The execution body can be
Figure BDA0003234650140000101
The resulting value of (2) is used as the integrated attitude angle variation.
In some embodiments, the coordinates may include an abscissa and an ordinate. The execution body may determine the second position coordinates in the following manner.
Step S1, determining a second position abscissa based on a first weighted sum of the first position abscissa and the current position abscissa using the first weight and the second weight.
Step S2, determining a second position ordinate based on a second weighted sum of the first position ordinate and the current position ordinate using the first weight and the second weight.
As an example, the first weight of the first position coordinate is L1, and the second weight of the above current position coordinate is L2. The first position coordinates are (a, b) and the current position coordinates are (c, d). The first weighted sum is "L1 × a + L2 × c", and the second weighted sum is "L1 × b + L2 × d".
In some scenarios, the execution subject may use the first weighted sum as a second location abscissa and the second weighted sum as a second location ordinate. Referring to the above example, after the posture of the cursor manipulation device is changed, the execution body may move the cursor from the current position indicated by the coordinates (c, d) to the second position indicated by the coordinates [ (L1 × a + L2 × c), (L1 × b + L2 × d) ].
With further reference to fig. 6, as an implementation of the methods shown in the above-mentioned figures, the present disclosure provides some embodiments of a cursor position updating apparatus, which correspond to the method embodiment shown in fig. 1, and which can be applied in various electronic devices.
As shown in fig. 6, the cursor position updating device of the present embodiment includes a first determining unit 601, a second determining unit 602, a third determining unit 603, and a moving unit 604. The first determining unit 601 is configured to determine a to-be-moved displacement of the cursor according to a current attitude angle variation of the cursor control device; a second determining unit 602, configured to determine the first position by offsetting the displacement to be moved from the current position of the cursor; a third determining unit 603 configured to determine a second position coordinate based on a weighted coordinate sum of the first position coordinate and the current position coordinate; and a moving unit 604 for moving the cursor to a second position indicated by the second position coordinate.
In this embodiment, the specific processes of the first determining unit 601, the second determining unit 602, the third determining unit 603, and the moving unit 604 of the cursor position updating apparatus and the technical effects thereof can refer to the related descriptions of step 101, step 102, step 103, and step 104 in the corresponding embodiment of fig. 1, and are not repeated herein.
In some embodiments, the cursor position updating apparatus may further include a fourth determining unit (not shown in the figure). The fourth determining unit is used for determining a first weight of the first position coordinate according to the current attitude angle variation; and determining a second weight of the current position coordinate according to the first weight. The third determining unit 603 is further configured to: determining a second position coordinate based on a weighted coordinate sum of the first position coordinate and the current position coordinate using the first weight and the second weight.
In some embodiments, the attitude angles include azimuth and pitch angles; the fourth determination unit is further configured to: determining the comprehensive attitude angle variation of the cursor control equipment according to the current azimuth angle variation and the current pitch angle variation of the cursor control equipment; if the comprehensive attitude angle variation is larger than or equal to a preset angle threshold, selecting a first weight from a first numerical interval; and if the comprehensive attitude angle change is smaller than a preset angle threshold, selecting a first weight from a second numerical interval, wherein the numerical value in the second numerical interval is smaller than or equal to the numerical value in the first numerical interval.
In some embodiments, the fourth determination unit is further configured to: determining a square root result value of a sum of a square of the current azimuth angle variation and a square of the current pitch angle variation; and determining the variation of the comprehensive attitude angle according to the square root result value.
In some embodiments, the fourth determination unit is further configured to: the difference between 1 and the first weight is used as the second weight.
In some embodiments, the third determining unit 603 is further configured to: determining a second position abscissa based on a first weighted sum of the first position abscissa and the current position abscissa using the first weight and the second weight; a second location ordinate is determined based on a second weighted sum of the first location ordinate and the current location ordinate using the first weight and the second weight.
In some embodiments, the first determining unit 601 is further configured to: determining the moving step length of the cursor according to the current attitude angle variation, wherein the moving step length is the moving length of the cursor responding to the unit attitude angle variation of the cursor control equipment; and determining the displacement to be moved of the cursor based on the product of the current attitude angle variation and the moving step length.
In some embodiments, the attitude angles include azimuth and pitch angles; the first determining unit 601 is further configured to: determining the comprehensive attitude angle variation of the cursor control equipment according to the current azimuth angle variation and the current pitch angle variation of the cursor control equipment, wherein the attitude angle variation of the cursor control equipment and the movement step length of the cursor meet a positive correlation relationship; and determining the moving step length corresponding to the comprehensive attitude angle change quantity based on the positive correlation.
In some embodiments, the attitude angles include azimuth and pitch angles; the first determining unit 601 is further configured to: determining the lateral displacement to be moved of the cursor based on the product of the current azimuth angle variation and the moving step length of the cursor control equipment; and determining the longitudinal displacement to be moved of the cursor based on the product of the current pitch angle variation and the moving step length of the cursor control equipment.
In some embodiments, the cursor position updating apparatus may further include a fifth determining unit (not shown in the figure). The fifth determining unit is configured to acquire current posture detection data of the cursor control device, where the posture detection data includes the following data of the cursor control device: acceleration, angular velocity, magnetic induction at the location; determining the current attitude angle of the cursor control equipment according to the current attitude detection data; and taking the difference between the current attitude angle and the previous attitude angle of the cursor control equipment as the current attitude angle variation.
With further reference to fig. 7, fig. 7 illustrates an exemplary system architecture to which the cursor position update methods of some embodiments of the present disclosure may be applied.
As shown in fig. 7, the system architecture may include cursor manipulation devices 701, 702, 703 and a display device 704. Wherein a cursor 705 may be displayed on the display device 704.
The cursor manipulation device may be various devices that manipulate the cursor 705. Various applications (e.g., shopping-type applications, search-type applications, news-information-type applications, etc.) may be installed on the display device.
In practical applications, if the gesture of the cursor control device changes (i.e., the user operates the cursor control device), the display device 704 may move the position of the cursor 705 accordingly. In some scenarios, first, the display device 704 may determine a displacement to be moved of the cursor 705 according to a current attitude angle variation amount of the cursor manipulation device, then, the display device 704 may determine a first position by shifting the displacement to be moved from a current position of the cursor 705, further, the display device 704 may determine a second position coordinate based on a weighted sum of the first position coordinate and the current position coordinate, and finally, the display device 704 may move the cursor 705 to a second position indicated by the second position coordinate.
The display device 704 may be hardware or software. When the display device 704 is hardware, it can be a variety of electronic devices with display screens including, but not limited to, a remote control, a mouse (e.g., an air mouse), a smart phone, a tablet computer, a laptop computer, and the like. When the display device 704 is software, it may be installed in the electronic devices listed above, and may be implemented as multiple pieces of software or software modules, or may be implemented as a single piece of software or software modules, and is not limited herein.
It should be noted that the cursor position updating method provided by the embodiment of the present disclosure may be executed by the display device 704, and accordingly, the cursor position updating apparatus may be disposed in the display device 704.
It should be understood that the number of cursor manipulation devices, display devices and cursors in fig. 7 is merely illustrative. There may be any number of cursor manipulation devices, display devices and cursors, as desired for implementation.
Referring now to FIG. 8, shown is a schematic diagram of an electronic device (e.g., display device 704 of FIG. 7) suitable for use in implementing some embodiments of the present disclosure. The display device in some embodiments of the present disclosure may include, but is not limited to, a mobile terminal such as a mobile phone, a notebook computer, a digital broadcast receiver, a PDA (personal digital assistant), a PAD (tablet computer), a PMP (portable multimedia player), a vehicle-mounted terminal (e.g., a car navigation terminal), and the like, and a fixed terminal such as a digital TV, a desktop computer, and the like. The electronic device shown in fig. 8 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present disclosure. The electronic device shown in fig. 8 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present disclosure.
As shown in fig. 8, an electronic device may include a processing means (e.g., a central processing unit, a graphics processor, etc.) 801 that may perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM)802 or a program loaded from a storage means 808 into a Random Access Memory (RAM) 803. In the RAM 803, various programs and data necessary for the operation of the electronic apparatus are also stored. The processing apparatus 801, the ROM 802, and the RAM 803 are connected to each other by a bus 804. An input/output (I/O) interface 805 is also connected to bus 804.
Generally, the following devices may be connected to the I/O interface 805: input devices 806 including, for example, a touch screen, touch pad, keyboard, mouse, camera, microphone, accelerometer, gyroscope, etc.; output devices 807 including, for example, a Liquid Crystal Display (LCD), speakers, vibrators, and the like; storage 808 including, for example, magnetic tape, hard disk, etc.; and a communication device 809. The communication means 809 may allow the electronic device to communicate with other devices wirelessly or by wire to exchange data. While fig. 8 illustrates an electronic device having various means, it is to be understood that not all illustrated means are required to be implemented or provided. More or fewer devices may alternatively be implemented or provided. Each block shown in fig. 8 may represent one device or may represent multiple devices as desired.
In particular, according to some embodiments of the present disclosure, the processes described above with reference to the flow diagrams may be implemented as computer software programs. For example, some embodiments of the present disclosure include a computer program product comprising a computer program carried on a non-transitory computer readable medium, the computer program containing program code for performing the method illustrated by the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through the communication means 809, or installed from the storage means 808, or installed from the ROM 802. The computer program, when executed by the processing apparatus 801, performs the above-described functions defined in the methods of the embodiments of the present disclosure.
It should be noted that the computer readable medium described in some embodiments of the present disclosure may be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In some embodiments of the disclosure, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In some embodiments of the present disclosure, however, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: electrical wires, optical cables, RF (radio frequency), etc., or any suitable combination of the foregoing.
In some embodiments, the clients, servers may communicate using any currently known or future developed network Protocol, such as HTTP (HyperText Transfer Protocol), and may interconnect with any form or medium of digital data communication (e.g., a communications network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), the Internet (e.g., the Internet), and peer-to-peer networks (e.g., ad hoc peer-to-peer networks), as well as any currently known or future developed network.
The computer readable medium may be included in the electronic device or may exist separately without being incorporated in the electronic device. The computer readable medium carries one or more programs which, when executed by the electronic device, cause the electronic device to: determining the displacement to be moved of the cursor according to the current attitude angle variation of the cursor control equipment; determining a first position by offsetting the displacement to be moved from the current position of the cursor; determining a second position coordinate based on a weighted coordinate sum of the first position coordinate and the current position coordinate; and moving the cursor to a second position indicated by the second position coordinate.
Computer program code for carrying out operations for embodiments of the present disclosure may be written in any combination of one or more programming languages, including but not limited to an object oriented programming language such as Java, Smalltalk, C + +, and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet service provider).
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The units described in some embodiments of the present disclosure may be implemented by software, and may also be implemented by hardware. Here, the names of the units do not constitute a limitation to the unit itself in some cases, and for example, the first determination unit may also be described as a unit that "determines a displacement to be moved of the cursor according to the amount of change in the current attitude angle of the cursor manipulation device".
The functions described herein above may be performed, at least in part, by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Products (ASSPs), systems on a chip (SOCs), Complex Programmable Logic Devices (CPLDs), and the like.
In the context of this disclosure, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
The foregoing description is only exemplary of the preferred embodiments of the disclosure and is illustrative of the principles of the technology employed. It will be appreciated by those skilled in the art that the scope of the disclosure in the embodiments of the present disclosure is not limited to the particular combination of the above-described features, but also encompasses other embodiments in which any combination of the above-described features or their equivalents is possible without departing from the scope of the present disclosure. For example, the above features may be interchanged with other features disclosed in this disclosure (but not limited to) those having similar functions.
Further, while operations are depicted in a particular order, this should not be understood as requiring that such operations be performed in the particular order shown or in sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Likewise, while several specific implementation details are included in the above discussion, these should not be construed as limitations on the scope of the disclosure. Certain features that are described in the context of separate embodiments can also be implemented in combination in a single embodiment. Conversely, various features that are described in the context of a single embodiment can also be implemented in multiple embodiments separately or in any suitable subcombination.
Although the subject matter has been described in language specific to structural features and/or methodological acts, it is to be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are disclosed as example forms of implementing the claims.

Claims (13)

1. A cursor position updating method, comprising:
determining the displacement to be moved of the cursor according to the current attitude angle variation of the cursor control equipment;
determining a first position by offsetting the displacement to be moved from the current position of the cursor;
determining a second position coordinate based on a weighted coordinate sum of the first position coordinate and the current position coordinate;
and moving the cursor to a second position indicated by the second position coordinate.
2. The method of claim 1, wherein prior to said determining a second location coordinate based on a weighted coordinate sum of the first location coordinate and the current location coordinate, the method further comprises:
determining a first weight of the first position coordinate according to the current attitude angle variation;
determining a second weight of the current position coordinate according to the first weight; and
determining a second location coordinate based on a weighted coordinate sum of the first location coordinate and the current location coordinate comprises:
determining the second location coordinate based on a weighted coordinate sum of the first location coordinate and the current location coordinate using the first weight and the second weight.
3. The method of claim 2, wherein the attitude angles include azimuth and pitch angles; and
determining a first weight of the first position coordinate according to the current attitude angle variation, including:
determining the comprehensive attitude angle variation of the cursor control equipment according to the current azimuth angle variation and the current pitch angle variation of the cursor control equipment;
if the comprehensive attitude angle variation is larger than or equal to a preset angle threshold, selecting the first weight from a first numerical interval;
and if the comprehensive attitude angle change is smaller than the preset angle threshold, selecting the first weight from a second numerical value interval, wherein the numerical value in the second numerical value interval is smaller than or equal to the numerical value in the first numerical value interval.
4. The method of claim 3, wherein determining the integrated attitude angle variation of the cursor control device according to the current azimuth angle variation and the current pitch angle variation of the cursor control device comprises:
determining a square root result value of a sum of a square of the current azimuth angle variation and a square of the current pitch angle variation;
and determining the variation of the comprehensive attitude angle according to the square root result value.
5. The method of claim 2, wherein determining a second weight for the current location coordinate based on the first weight comprises:
the difference between 1 and the first weight is used as the second weight.
6. The method of claim 2, wherein determining the second location coordinate based on a weighted coordinate sum of the first location coordinate and the current location coordinate using the first weight and the second weight comprises:
determining a second location abscissa based on a first weighted sum of the first location abscissa and the current location abscissa using the first weight and the second weight;
determining a second location ordinate based on a second weighted sum of the first location ordinate and the current location ordinate using the first weight and the second weight.
7. The method according to claim 1, wherein the determining the displacement to be moved of the cursor according to the current attitude angle variation of the cursor control device comprises:
determining a moving step length of the cursor according to the current attitude angle variation, wherein the moving step length is a moving length of the cursor responding to the unit attitude angle variation of the cursor control equipment;
and determining the displacement to be moved of the cursor based on the product of the current attitude angle variation and the moving step length.
8. The method of claim 7, wherein the attitude angles include azimuth and pitch angles; and
determining a moving step length of the cursor according to the current attitude angle variation, including:
determining the comprehensive attitude angle variation of the cursor control equipment according to the current azimuth angle variation and the current pitch angle variation of the cursor control equipment, wherein the attitude angle variation of the cursor control equipment and the movement step length of the cursor meet a positive correlation relationship;
and determining the moving step length corresponding to the comprehensive attitude angle variation based on the positive correlation.
9. The method of claim 7, wherein the attitude angles include azimuth and pitch angles; and
the determining the displacement to be moved of the cursor based on the product of the current attitude angle variation and the moving step length includes:
determining the lateral displacement to be moved of the cursor based on the product of the current azimuth angle variation of the cursor control equipment and the moving step length;
and determining the longitudinal displacement to be moved of the cursor based on the product of the current pitch angle variation of the cursor control equipment and the moving step length.
10. The method according to any one of claims 1-9, wherein before determining the displacement of the cursor to be moved according to the current attitude angle variation of the cursor manipulation device, the method further comprises:
acquiring current attitude detection data of the cursor control device, wherein the attitude detection data comprises the following data of the cursor control device: acceleration, angular velocity, magnetic induction at the location;
determining a current attitude angle of the cursor control device according to the current attitude detection data;
and taking the difference between the current attitude angle and the previous attitude angle of the cursor control equipment as the current attitude angle variation.
11. A cursor position updating apparatus, comprising:
the first determining unit is used for determining the displacement to be moved of the cursor according to the current attitude angle variation of the cursor control equipment;
a second determination unit configured to determine a first position by offsetting the displacement to be moved from the current position of the cursor;
a third determination unit configured to determine a second position coordinate based on a weighted coordinate sum of the first position coordinate and the current position coordinate;
and the moving unit is used for moving the cursor to a second position indicated by the second position coordinate.
12. An electronic device, comprising:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement the method of any one of claims 1-10.
13. A computer-readable medium, on which a computer program is stored which, when being executed by a processor, carries out the method according to any one of claims 1-10.
CN202110998460.8A 2021-08-27 2021-08-27 Cursor position updating method and device and electronic equipment Active CN113741750B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110998460.8A CN113741750B (en) 2021-08-27 2021-08-27 Cursor position updating method and device and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110998460.8A CN113741750B (en) 2021-08-27 2021-08-27 Cursor position updating method and device and electronic equipment

Publications (2)

Publication Number Publication Date
CN113741750A true CN113741750A (en) 2021-12-03
CN113741750B CN113741750B (en) 2024-05-28

Family

ID=78733546

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110998460.8A Active CN113741750B (en) 2021-08-27 2021-08-27 Cursor position updating method and device and electronic equipment

Country Status (1)

Country Link
CN (1) CN113741750B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115185411A (en) * 2022-07-08 2022-10-14 北京字跳网络技术有限公司 Cursor moving method and device and electronic equipment

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100123659A1 (en) * 2008-11-19 2010-05-20 Microsoft Corporation In-air cursor control
KR20140018643A (en) * 2012-08-03 2014-02-13 한국과학기술원 Method for selecting object by utilizing tendency of recent cursor movements and control system for the same
US20140104156A1 (en) * 2004-11-02 2014-04-17 Pierre A. Touma Hand-held wireless electronic device with accelerometer for interacting with a display
CN105988664A (en) * 2015-03-19 2016-10-05 联想(新加坡)私人有限公司 Apparatus and method for setting a cursor position
US20190310755A1 (en) * 2016-03-22 2019-10-10 Mitsubishi Electric Corporation Coordinate correction apparatus

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140104156A1 (en) * 2004-11-02 2014-04-17 Pierre A. Touma Hand-held wireless electronic device with accelerometer for interacting with a display
US20100123659A1 (en) * 2008-11-19 2010-05-20 Microsoft Corporation In-air cursor control
KR20140018643A (en) * 2012-08-03 2014-02-13 한국과학기술원 Method for selecting object by utilizing tendency of recent cursor movements and control system for the same
CN105988664A (en) * 2015-03-19 2016-10-05 联想(新加坡)私人有限公司 Apparatus and method for setting a cursor position
US20190310755A1 (en) * 2016-03-22 2019-10-10 Mitsubishi Electric Corporation Coordinate correction apparatus

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115185411A (en) * 2022-07-08 2022-10-14 北京字跳网络技术有限公司 Cursor moving method and device and electronic equipment
CN115185411B (en) * 2022-07-08 2024-03-15 北京字跳网络技术有限公司 Cursor moving method and device and electronic equipment

Also Published As

Publication number Publication date
CN113741750B (en) 2024-05-28

Similar Documents

Publication Publication Date Title
CN111190520A (en) Menu item selection method and device, readable medium and electronic equipment
CN112818898B (en) Model training method and device and electronic equipment
CN114742934B (en) Image rendering method and device, readable medium and electronic equipment
CN111652675A (en) Display method and device and electronic equipment
US10606457B2 (en) Shake event detection system
CN113741750B (en) Cursor position updating method and device and electronic equipment
CN111382701A (en) Motion capture method, motion capture device, electronic equipment and computer-readable storage medium
US20230199262A1 (en) Information display method and device, and terminal and storage medium
CN112489224A (en) Image drawing method and device, readable medium and electronic equipment
CN116088537B (en) Vehicle obstacle avoidance method, device, electronic equipment and computer readable medium
CN114067030A (en) Dynamic fluid effect processing method and device, electronic equipment and readable medium
CN111273884A (en) Image display method and device and electronic equipment
CN113496533A (en) Sticker processing method and device
CN111324405A (en) Character display method and device and electronic equipment
CN113407045B (en) Cursor control method and device, electronic equipment and storage medium
CN112711457A (en) Method and device for field drawing and electronic equipment
CN111290812B (en) Display method, device, terminal and storage medium of application control
CN116266206A (en) Page display method and device and electronic equipment
CN113741749B (en) Cursor position updating method and device and electronic equipment
CN113253874A (en) Display device control method, device, terminal and storage medium
CN112416146A (en) Method, device, terminal and storage medium for processing information
CN113515201B (en) Cursor position updating method and device and electronic equipment
CN116880726B (en) Icon interaction method and device for 3D space, electronic equipment and medium
CN115908143B (en) Vehicle cross-layer parking method, device, electronic equipment and computer readable medium
CN114911564B (en) Page movement processing method, device, equipment and storage medium

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