Method and device for determining touch screen compensation point, electronic device and storage medium

By calculating the intersection point and distance mapping relationship of touch points, the touch screen compensation point is solved, and more uniform touch trajectory simulation and higher program execution accuracy are achieved.

CN116204079BActive Publication Date: 2025-08-08CHIPONE TECHNOLOGY (BEIJING) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211643543.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-12-20
Publication Date
2025-08-08
Estimated Expiration
2042-12-20

AI Technical Summary

Technical Problem

When simulating touch tracks, the touch screen is prone to defects such as burrs, insufficient curvature or reverse curvature, resulting in inaccurate program execution.

Method used

By obtaining the first touch point, the second touch point and the third touch point that are not on the same straight line, the first distance between the first intersection point and the fourth point is calculated, and the position of the target compensation point is determined using the preset distance mapping relationship. The target compensation point is located on the vertical line and is second distance from the fourth point.

Benefits of technology

It improves the efficiency of determining the compensation point of the touch screen, makes the simulated touch trajectory more uniform, reduces the probability of burrs and insufficient curvature or reverse curvature, and ensures the accuracy of program execution.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116204079B_ABST
    Figure CN116204079B_ABST
Patent Text Reader

Abstract

The present disclosure relates to a method and apparatus, electronic device, and storage medium for determining a touch screen compensation point. The method comprises: obtaining a first touch point, a second touch point, and a third touch point that are not on the same straight line and are collected at a preset frequency; obtaining a first distance between a first intersection point and a fourth point when a target compensation point to be added is located between the second touch point and the third touch point; determining a second distance that has a preset distance mapping relationship with the first distance, wherein the preset distance mapping relationship makes the second distance positively correlated with the first distance, and the magnitude of the increase in the second distance is negatively correlated with the first distance; and determining a point on the vertical line that is the second distance away from the fourth point as the target compensation point. Using this method to determine the target compensation point can improve the efficiency of determining the target compensation point, thereby making the arc of simulated motion estimation more uniform and reducing the probability of burrs, insufficient curvature, and reverse curvature.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of display, and in particular to a method and device for determining a touch screen compensation point, an electronic device, and a storage medium. Background Art

[0002] A touch screen, also known as a "touch screen" or "touch panel", is an inductive liquid crystal display device that can receive input signals.

[0003] When the touchscreen receives a touch, the on-screen tactile feedback system determines the touch location based on pre-set settings. Based on the touch location, it then determines the touch trajectory, triggering the application corresponding to that touch trajectory. The application then drives the various devices connected to the touchscreen. This shows that accurately determining the touch trajectory is crucial for accurately determining the program to be executed, and thus achieving the desired functional effect.

[0004] Typically, a touch trace is drawn by hand or with a stylus. This trace consists of multiple touch points. Most touch traces are arcs. However, touch screens can only sample touch points and then connect them to simulate an arc. However, these simulated arcs often fail to accurately reproduce the touch traces. For example, they may contain probabilistic glitches, insufficient curvature, or inverse curvature, making it difficult to accurately determine the program to be executed. Summary of the Invention

[0005] In view of this, the present disclosure proposes a solution for determining a touch screen compensation point.

[0006] According to one aspect of the present disclosure, a method for determining a touch screen compensation point is provided, comprising:

[0007] Acquire a first touch point, a second touch point, and a third touch point that are not on the same straight line and are collected at a preset frequency;

[0008] When the target compensation point to be added is located between the second touch point and the third touch point, obtaining a first distance between the first intersection point and a fourth point, where the fourth point is a point on a second line segment formed by connecting the second touch point and the third touch point, the first intersection point is an intersection of a first straight line and a perpendicular line, the first straight line is a straight line on which the first touch point and the second touch point are located, the perpendicular line is a straight line passing through the fourth point and perpendicular to the second line segment, and the target compensation point is on the perpendicular line;

[0009] Determining a second distance having a preset distance mapping relationship with the first distance, wherein the preset distance mapping relationship causes the second distance to be positively correlated with the first distance, and an increase in the second distance to be negatively correlated with the first distance;

[0010] A point on the vertical line that is the second distance away from the fourth point is determined as the target compensation point.

[0011] In a possible implementation, the second line segment is equally divided by the fourth point, and before obtaining the first distance between the first intersection point and the fourth point, the method further includes:

[0012] determining the coordinates of the fourth point according to the coordinates of the second touch point and the coordinates of the third touch point;

[0013] according to and Determine the sine value of the perpendicular line and the cosine value of the perpendicular line;

[0014] Wherein, sinθ is the sine value, cosθ is the cosine value, k2 is the slope of the vertical line, x3 is the abscissa of the third touch point, y3 is the ordinate of the third touch point; x2 is the abscissa of the second touch point, y2 is the ordinate of the second touch point; θ is the angle between the vertical line and the positive direction of the x-axis;

[0015] according to determining the first distance,

[0016] Wherein, t1 represents the first distance, k1 represents the slope of the first straight line, x1 is the horizontal coordinate of the first touch point, y1 is the vertical coordinate of the first touch point; x4 is the horizontal coordinate of the fourth point, y4 is the vertical coordinate of the fourth point.

[0017] In a possible implementation, determining the target compensation point by taking a point on the vertical line that is the second distance from the fourth point as the target compensation point includes:

[0018] According to y o =y4+t2sinθ and x o =x4+t2cosθ, determine the coordinates of the target compensation point,

[0019] Among them, x o Indicates the horizontal coordinate of the target compensation point, y o represents the ordinate of the target compensation point, x4 is the abscissa of the fourth point, y4 is the ordinate of the fourth point, and t2 represents the second distance.

[0020] In a possible implementation, the method further includes:

[0021] Obtaining the touch screen's reporting rate and display frame rate;

[0022] In a case where the reporting point rate is N+1 times the display frame rate, the number of the fourth points is determined to be N, where N is a positive integer and N≥1.

[0023] In a possible implementation, determining the coordinates of the fourth point according to the coordinates of the second touch point and the coordinates of the third touch point includes:

[0024] according to and determining the coordinates of the fourth point,

[0025] Among them, x4 is the horizontal coordinate of the fourth point, y4 is the vertical coordinate of the fourth point, N represents the number of the fourth points, and M represents the Mth fourth point N≥M≥1.

[0026] In a possible implementation, the second line segment is divided equally by the fourth points, and the fourth points are symmetrically distributed about the perpendicular midline of the second line segment. Determining the first distance includes:

[0027] A first distance between the first intersection point and any of the fourth points is determined as a first distance corresponding to each of the mutually symmetrical fourth points.

[0028] According to another aspect of the present disclosure, there is provided an apparatus for determining a touch screen compensation point, comprising:

[0029] A touch point acquisition unit, configured to acquire a first touch point, a second touch point, and a third touch point that are not on the same straight line and are collected at a preset frequency;

[0030] a first distance acquisition unit, configured to acquire, when the target compensation point to be added is located between the second touch point and the third touch point, a first distance between the first intersection point and a fourth point, the fourth point being a point on a second line segment formed by connecting the second touch point and the third touch point, the first intersection point being an intersection of a first straight line and a perpendicular line, the first straight line being a straight line on which the first touch point and the second touch point are located, the perpendicular line being a straight line passing through the fourth point and perpendicular to the second line segment, and the target compensation point being on the perpendicular line;

[0031] a second distance determining unit, configured to determine a second distance having a preset distance mapping relationship with the first distance, wherein the preset distance mapping relationship causes the second distance to be positively correlated with the first distance, and an increase in the second distance to be negatively correlated with the first distance;

[0032] The target compensation point determining unit is configured to determine a point on the vertical line that is the second distance away from the fourth point as the target compensation point.

[0033] According to another aspect of the present disclosure, a display device is provided, including a plurality of display units and at least one of the above-mentioned devices for determining touch screen compensation points.

[0034] According to another aspect of the present disclosure, an electronic device is provided, comprising: a processor; and a memory for storing processor-executable instructions; wherein the processor is configured to implement the above method when executing the instructions stored in the memory.

[0035] According to another aspect of the present disclosure, a non-volatile computer-readable storage medium is provided, on which computer program instructions are stored, wherein the computer program instructions implement the above method when executed by a processor.

[0036] According to another aspect of the present disclosure, a computer program product is provided, including a computer-readable code, or a non-volatile computer-readable storage medium carrying the computer-readable code. When the computer-readable code runs in a processor of an electronic device, the processor in the electronic device executes the above method.

[0037] In the disclosed embodiment, when the target compensation point to be added is located between the second touch point and the third touch point, the first distance between the first intersection point and the fourth point is first determined. Since the first intersection point and the fourth point lie on a vertical line, and the target compensation point and the fourth point also lie on the same vertical line, the first intersection point, the fourth point, and the target compensation point all lie on the same vertical line. Therefore, by determining the fourth point and the first intersection point, the vertical line is determined, that is, the straight line on which the target compensation point lies, narrowing the range for determining the target compensation point and improving the efficiency of determining the target compensation point.

[0038] The fourth point may be located at a preset position, so that the arcs of the touch tracks simulated by the determined target compensation point and the second touch point and the third touch point can be more uniform.

[0039] Then, a second distance having a preset distance mapping relationship with the first distance is determined. The preset distance mapping relationship can reduce the growth rate of the second distance value as the first distance value increases. Therefore, as the first distance value increases, the speed at which the target compensation point moves away from the second line segment gradually slows down, making the simulated touch trajectory smoother and reducing the probability of burrs. Moreover, the preset distance mapping relationship can increase the growth rate of the second distance value as the first distance value decreases. Therefore, as the first distance value decreases, the speed at which the target compensation point approaches the second line segment gradually slows down, reducing the probability of insufficient curvature or reverse curvature in the simulated touch trajectory.

[0040] Further features and aspects of the present disclosure will become apparent from the following detailed description of exemplary embodiments with reference to the attached drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] The accompanying drawings, which are incorporated in and constitute a part of the specification, illustrate exemplary embodiments, features, and aspects of the disclosure and, together with the description, serve to explain the principles of the disclosure.

[0042] Figure 1 A schematic flow chart of a method for determining touch screen compensation points provided by an embodiment of the present disclosure.

[0043] Figure 2 A schematic diagram of the target compensation point position provided in an embodiment of the present disclosure.

[0044] Figure 3 A schematic diagram of the positional relationship between the target compensation point and the acquired touch point provided in an embodiment of the present disclosure.

[0045] Figure 4 A schematic diagram of a device for determining touch screen compensation points provided by an embodiment of the present disclosure.

[0046] Figure 5 A schematic diagram of an electronic device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION

[0047] Various exemplary embodiments, features, and aspects of the present disclosure will be described in detail below with reference to the accompanying drawings. The same reference numerals in the accompanying drawings represent elements with the same or similar functions. Although various aspects of the embodiments are shown in the accompanying drawings, the drawings are not necessarily drawn to scale unless otherwise indicated.

[0048] In the description of the present disclosure, it should be understood that the terms "length", "width", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside", etc., indicating the orientation or position relationship, are based on the orientation or position relationship shown in the accompanying drawings, and are only for the convenience of describing the present disclosure and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation on the present disclosure.

[0049] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of the technical features being referred to. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features. Throughout the present disclosure, "plurality" means two or more, unless otherwise specifically defined.

[0050] In this disclosure, unless otherwise expressly specified or limited, terms such as "mounted," "connected," "connect," and "fixed" should be understood broadly. For example, they may refer to fixed connections, detachable connections, or integration; mechanical connections or electrical connections; direct connections or indirect connections through an intermediate medium; and internal connections between two components or interactions between two components. Those skilled in the art will understand the specific meanings of these terms in this disclosure based on specific circumstances.

[0051] The term "and / or" herein simply describes an association relationship between associated objects, indicating that three relationships can exist. For example, "A and / or B" can represent the existence of three situations: A alone, A and B simultaneously, and B alone. Furthermore, the term "at least one" herein refers to any combination of at least two of any one or more of a plurality of items. For example, "at least one of A, B, and C" can represent any one or more elements selected from the set consisting of A, B, and C.

[0052] Figure 1 Schematic diagram of a flow chart of a method for determining a touch screen compensation point provided by an embodiment of the present disclosure. Figure 1 As shown, the method includes:

[0053] S11, acquiring a first touch point, a second touch point, and a third touch point that are not on the same straight line and are collected at a preset frequency.

[0054] The touch screen can collect touch points at a preset frequency. The preset frequency can limit the number of touch points collected per unit time. For example, 60 times / second. The touch point can be the pixel that receives the touch, or the center point of multiple pixels that receive a single touch. The present embodiment does not limit the method for determining the touch point.

[0055] The first touch point, the second touch point, and the third touch point are not on the same straight line. For example, the first touch point, the second touch point, and the third touch point are touch points sampled by the screen during the process of a finger drawing an arc on the touch screen. The acquired touch points may include acquiring coordinates of the touch points, i.e., the coordinates of the first touch point, the second touch point, and the third touch point may be acquired.

[0056] S12. When the target compensation point to be added is located between the second touch point and the third touch point, obtain a first distance between the first intersection point and the fourth point, where the fourth point is a point on the second line segment formed by connecting the second touch point and the third touch point, the first intersection point is the intersection of the first straight line and the perpendicular line, the first straight line is the straight line where the first touch point and the second touch point are located, the perpendicular line is a straight line passing through the fourth point and perpendicular to the second line segment, and the target compensation point is on the perpendicular line.

[0057] In the disclosed embodiment, it is desirable to add a target compensation point so that the line connecting the second touch point, the target compensation point, and the third touch point can be used to simulate the actual touch trajectory between the second and third touch points. Therefore, the target compensation point will not be located on the second line segment where the second and third touch points are located. However, it can be located somewhere between the second and third touch points.

[0058] Figure 2 Schematic diagram of the target compensation point position provided by the embodiment of the present disclosure. Figure 2 As shown in the figure, point A is the second touch point, point B is the third touch point, and arc h is the actual touch trajectory between point A and point B. Point C is the target compensation point, and line segments AC and CB are used to simulate arc h. Figure 2 As can be seen, point C is between point A and point B, but because the arc needs to be simulated, point C is not on line segment AB.

[0059] Then, if it is desired to add a target compensation point between the second touch point and the third touch point, the first distance between the first intersection point and the fourth point can be obtained. The fourth point here can be located on the second line segment and on the perpendicular line perpendicular to the second line segment, that is, the fourth point can be the intersection of the perpendicular line and the second point segment. The first intersection here can be located on the perpendicular line and on the first straight line where the first touch point and the second touch point are located, that is, the first intersection can be the intersection of the perpendicular line and the first straight line. The first distance can be an external input, or obtained by measurement. The embodiment of the present disclosure does not limit the method of obtaining the first distance.

[0060] In an embodiment of the present disclosure, a fourth point can be determined on a second line segment with the second touch point and the third touch point as endpoints. The position of the fourth point can be pre-set. For example, the fourth point can be set on the second line segment, for example, the midpoint of the second line segment can be determined as the fourth point. For example, a position range for the fourth point can be set on the second line segment, and any point within this position range can be determined as the fourth point. The endpoints of this position range can be on the second line segment, symmetrically about the midpoint of the second line segment. For example, starting from an endpoint of the second line segment, two-fifths and three-fifths of the second line segment can be determined, and two-fifths and three-fifths of the second line segment can be determined as the endpoints of the position range. That is, the position range is from two-fifths to three-fifths of the second line segment. The coordinates of any point within this position range can be determined as the coordinates of the fourth point. In an embodiment of the present disclosure, at least one fourth point is determined. The number of first distances is equal to the number of fourth points, that is, a single fourth point corresponds to one first distance.

[0061] S13: Determine a second distance having a preset distance mapping relationship with the first distance, wherein the preset distance mapping relationship makes the second distance positively correlated with the first distance, and an increase in the second distance is negatively correlated with the first distance.

[0062] In the embodiment of the present disclosure, a distance mapping relationship can be preset. The distance mapping relationship reflects the relationship between the first distance and the second distance. The second distance can be the distance between the target compensation point and the fourth point. The value of the second distance can increase as the value of the first distance increases, and decrease as the value of the first distance decreases; however, the increase in the second distance can decrease as the value of the first distance increases, and increase as the value of the first distance decreases. The distance mapping relationship can be expressed as: t2 = t1 × f(t1), where f(t1) can be t1 is the first distance, t2 is the second distance, and a is a constant. The above is only an example, and the embodiment of the present disclosure does not limit the specific form of the distance mapping relationship.

[0063] The number of the second distances may be the same as the number of the first distances, that is, a single fourth point corresponds to a first distance, and the first distance corresponds to a second distance.

[0064] S14: Determine a point on the vertical line that is the second distance away from the fourth point as the target compensation point.

[0065] In the disclosed embodiment, a target compensation point is determined on the vertical line on which the fourth point lies, and is located at a second distance from the fourth point. If there are multiple fourth points, each of the fourth points lies on multiple vertical lines, and there is a one-to-one correspondence between the fourth points and the vertical lines, with only one fourth point on each vertical line. Alternatively, a target compensation point can be determined on the vertical line on which a single fourth point lies, and is located at the second distance from the single fourth point. The number of target compensation points can be the same as the number of fourth points.

[0066] In the disclosed embodiment, when the target compensation point to be added is located between the second touch point and the third touch point, the first distance between the first intersection point and the fourth point is first determined. Since the first intersection point and the fourth point lie on a vertical line, and the target compensation point and the fourth point also lie on the same vertical line, the first intersection point, the fourth point, and the target compensation point all lie on the same vertical line. Therefore, by determining the fourth point and the first intersection point, the vertical line is determined, that is, the straight line on which the target compensation point lies, narrowing the range for determining the target compensation point and improving the efficiency of determining the target compensation point.

[0067] The fourth point may be located at a preset position, so that the arcs of the touch tracks simulated by the determined target compensation point and the second touch point and the third touch point can be more uniform.

[0068] Then, a second distance having a preset distance mapping relationship with the first distance is determined. The preset distance mapping relationship can reduce the growth rate of the second distance value as the first distance value increases. Therefore, as the first distance value increases, the speed at which the target compensation point moves away from the second line segment gradually slows down, making the simulated touch trajectory smoother and reducing the probability of burrs. Moreover, the preset distance mapping relationship can increase the growth rate of the second distance value as the first distance value decreases. Therefore, as the first distance value decreases, the speed at which the target compensation point approaches the second line segment gradually slows down, reducing the probability of insufficient curvature or reverse curvature in the simulated touch trajectory.

[0069] In a possible implementation, the second line segment is bisected by the fourth point, and before obtaining the first distance between the first intersection point and the fourth point, the method further includes: determining the coordinates of the fourth point according to the coordinates of the second touch point and the coordinates of the third touch point; and determining the coordinates of the fourth point according to the coordinates of the second touch point and the coordinates of the third touch point. and Determine the sine value and cosine value of the vertical line; wherein sinθ is the sine value, cosθ is the cosine value, and k2 is the slope of the vertical line. x3 is the horizontal coordinate of the third touch point, y3 is the vertical coordinate of the third touch point; x2 is the horizontal coordinate of the second touch point, y2 is the vertical coordinate of the second touch point; θ is the angle between the vertical line and the positive direction of the x-axis; according to Determine the first distance, wherein t1 represents the first distance, k1 represents the slope of the first straight line, x1 is the horizontal coordinate of the first touch point, y1 is the vertical coordinate of the first touch point; x4 is the horizontal coordinate of the fourth point, y4 is the vertical coordinate of the fourth point.

[0070] As previously mentioned, the fourth point, the second touch point, and the third touch point are all on the second line segment. Therefore, when the second line segment is divided equally by the fourth point, the number of fourth points can be determined first. For example, one fourth point divides the second line segment into two equal parts; two fourth points divide the second line segment into three equal parts; and so on; N fourth points divide the second line segment into N+1 equal parts, where N ≥ 1 and N is a positive integer. The number of fourth points can be pre-set or automatically adjusted by the program based on the application scenario.

[0071] Since the fourth point divides the second line segment into equal parts, the coordinates of the fourth point can be determined according to the number of the fourth points, the coordinates of the second touch point, and the coordinates of the third touch point.

[0072] For example, if there is one fourth point, this indicates that the fourth point divides the second line segment into two equal parts. That is, the fourth point is located at the midpoint of the second line segment. Therefore, the coordinates of the midpoint of the second line segment can be determined based on the coordinates of the second touch point and the third touch point. Another example is if there are two fourth points, this indicates that the fourth points divide the second line segment into three equal parts. That is, the fourth points are located at one-third and two-thirds of the second line segment, respectively. Therefore, the coordinates of one-third and two-thirds of the second line segment can be determined based on the coordinates of the second touch point and the third touch point.

[0073] In the embodiment of the present disclosure, the slope of the second line segment can be determined based on the coordinates of the second touch point, the coordinates of the third touch point, and formula (1). Since the vertical line and the second line segment are perpendicular to each other, the slope k2 of the vertical line can be determined according to formula (2).

[0074]

[0075]

[0076] Wherein, k3 represents the slope of the second line segment, k2 represents the slope of the vertical line; the coordinates of the second touch point are (x2, y2), and the coordinates of the second touch point are (x3, y3).

[0077] Then, the sine value of the perpendicular line is determined according to formula (3), and the cosine value of the perpendicular line is determined according to formula (4).

[0078]

[0079]

[0080] Wherein, θ is the angle between the vertical line and the positive direction of the x-axis.

[0081] When the sine and cosine values of the vertical line are determined, the first distance is determined according to formula (5):

[0082]

[0083] Wherein, t1 represents the first distance, k1 represents the slope of the first straight line, x1 is the horizontal coordinate of the first touch point, y1 is the vertical coordinate of the first touch point; x4 is the horizontal coordinate of the fourth point, y4 is the vertical coordinate of the fourth point.

[0084] In the embodiment of the present disclosure, since the fourth point divides the second line segment into equal parts, it means that the fourth point is evenly distributed on the second line segment. Since the fourth point and the target compensation point are on the same vertical line, the target compensation point will also be evenly distributed on the simulated touch trajectory, making the simulated touch trajectory smoother and more in line with the actual touch trajectory. Moreover, the coordinates of the fourth point can be determined based on the coordinates of the second touch point and the coordinates of the third touch point, and then the slope of the vertical line can be determined based on the coordinates of the second touch point and the coordinates of the third touch point, and then the sine and cosine values of the vertical line can be determined. Then, the coordinates, sine and cosine values of the fourth point are used to determine the first distance. Therefore, the embodiment of the present disclosure only needs to obtain the coordinates of the three touch points to determine the first distance and then determine the position of the target compensation point, saving storage resources.

[0085] In one possible implementation, the method further includes: obtaining the reporting rate and display frame rate of the touch screen; when the reporting rate is N+1 times the display frame rate, determining the number of the fourth points to be N, where N is a positive integer and N≥1.

[0086] The display frame rate is the number of image frames displayed per unit time on the phone screen, for example, 60 frames per millisecond. The reporting rate is the number of times the touch chip on the phone screen reports the touch position (coordinates) per unit time, for example, 60 times per millisecond.

[0087] When the point reporting rate is greater than the display frame rate, and the point reporting rate is N+1 times the display frame rate, the number of the fourth point can be determined to be N.

[0088] For example, if the dot reporting rate is 120 times / millisecond and the display frame rate is 60 times / millisecond, it can be determined that the dot reporting rate is twice the display frame rate, and thus one fourth point exists. For another example, if the dot reporting rate is 180 times / millisecond and the display frame rate is 60 times / millisecond, it can be determined that the dot reporting rate is three times the display frame rate, and thus two fourth points exist.

[0089] The reporting rate varies in different application scenarios. Increasing the reporting rate requires increasing the number of points used to simulate the touch trajectory; otherwise, the simulated arc won't be able to accurately match the actual touch trajectory. Conversely, decreasing the reporting rate reduces the number of points used to simulate the touch trajectory, minimizing computing resources while still meeting the quality requirements for the simulated touch trajectory.

[0090] In the disclosed embodiment, the number of fourth points can be adjusted according to the multiple of the reporting rate and the display frame rate, thereby adjusting the number of target compensation points to be added, thereby finding a balance between improving the quality of the simulated touch trajectory and saving computing resources.

[0091] In a possible implementation, determining the coordinates of the fourth point according to the coordinates of the second touch point and the coordinates of the third touch point includes: and Determine the coordinates of the fourth point, where x4 is the horizontal coordinate of the fourth point, y4 is the vertical coordinate of the fourth point, N represents the number of the fourth points, and M represents the Mth fourth point, N≥M≥1.

[0092] Since the fourth point divides the second line segment equally, and the coordinates of the second touch point and the third touch point are known, the coordinates of the single fourth point can be determined.

[0093] For example, if there is a fourth point, the fourth point divides the second line segment into two equal parts. That is, the fourth point is the midpoint of the second line segment. Therefore, the coordinates of the fourth point can be That is, when there is one fourth point, the coordinates of the fourth point can be

[0094] Another example, when there are two fourth points, the fourth point divides the second line segment into three equal parts. That is, the fourth point is the point at one-third and two-thirds of the second line segment. Therefore, the coordinates of the first fourth point can be The coordinates of the second fourth point can be

[0095] Similarly, the coordinates of the fourth point can be determined using formulas (6) and (7).

[0096]

[0097]

[0098] Among them, x4 is the horizontal coordinate of the fourth point, y4 is the vertical coordinate of the fourth point, N represents the number of the fourth points, and M represents the Mth fourth point N≥M≥1.

[0099] In the case where the fourth point is a point that divides the second line segment equally, the method of the embodiment of the present disclosure can accurately determine the fourth point without being limited by the number of fourth points, thereby ultimately improving the accuracy of determining the target compensation point.

[0100] In a possible implementation, determining the target compensation point by taking the point on the vertical line that is the second distance from the fourth point as the target compensation point includes: o =y4+t2sinθ and x o =x4+t2cosθ, determine the coordinates of the target compensation point, where x o Indicates the horizontal coordinate of the target compensation point, y o represents the ordinate of the target compensation point, x4 is the abscissa of the fourth point, y4 is the ordinate of the fourth point, and t2 represents the second distance.

[0101] As previously mentioned, the target compensation point is located on the vertical line at a second distance from the fourth point. That is, the target compensation point and the fourth point are both on the same vertical line. Therefore, once the angle θ between the vertical line and the positive x-axis is known, the direction of the vertical line extending in the rectangular coordinate system at the target compensation point can be determined. Once the coordinates of the fourth point on the vertical line and the second distance are known, the coordinates of the target compensation point can be determined. Here, variations of the angle θ can be used to determine the first distance, such as the sine or cosine of the angle θ.

[0102] In a possible implementation, the second line segment is divided equally by the fourth points, and the fourth points are symmetrically distributed about the perpendicular midline of the second line segment. Determining the first distance includes: determining a first distance between the first intersection point and any of the fourth points as the first distance corresponding to the mutually symmetrical fourth points.

[0103] In the disclosed embodiment, since the fourth points are equally divided points of the second line segment, the fourth points are symmetrically distributed about the perpendicular bisector of the second line segment. Therefore, only the first distances corresponding to the fourth points on one side of the perpendicular bisector can be determined as the first distances to the mutually symmetrical fourth points on the other side of the perpendicular bisector.

[0104] In this way, the number of times the program is called to calculate the first distance can be reduced, computing resources can be saved, and the efficiency of determining the first distance can be improved.

[0105] Figure 3 Schematic diagram of the positional relationship between the target compensation point and the acquired touch point provided in the embodiment of the present disclosure. Figure 3 The method for determining the target compensation point provided by the embodiment of the present disclosure is described.

[0106] In the embodiment of the present disclosure, the reporting rate of the touch screen is 120 times / millisecond, and the display frame rate is 60 frames / millisecond. The reporting rate is twice the display frame rate. Therefore, there is a fourth point in the embodiment of the present disclosure. For the sake of convenience of description, the fourth point is named point f1, and the coordinates of point f1 are (x4, y4).

[0107] exist Figure 3 In the example, point P1 represents the first touch point, with coordinates (x1, y1); point P2 represents the second touch point, with coordinates (x2, y2); and point P3 represents the third touch point, with coordinates (x3, y3). Points P1 and P2 lie on the first straight line L1. A second line segment L3 is formed with points P2 and P3 as endpoints. A perpendicular line L2, perpendicular to the second line segment L3, is determined through point f1. The angle θ between perpendicular line L2 and the positive x-axis is θ, and the supplement of θ is γ. For ease of description, the first intersection of perpendicular line L2 and first straight line L1 is named point f2.

[0108] As mentioned above, the slope of the vertical line L2 can be determined according to formulas (1) and (2): The slope of the first straight line

[0109] from Figure 3 It can be seen from the figure that k2 can also be expressed in another way, that is, According to trigonometric functions, it can be clearly seen that so, Since angle θ and angle γ are complementary angles, sinθ = sinγ and cosθ = -cosγ. Therefore, formulas (3) and (4) can be derived.

[0110] Since the fourth point f1 divides the second line segment into two equal parts, the coordinates of the fourth point f1 can be determined according to formulas (6) and (7):

[0111] After determining the sine and cosine values of the perpendicular line L2 and the coordinates of point f1, the position of a point on L2 (point f1) and the angle (sine and cosine values) of L2 are determined. Therefore, L2 can be expressed using the distance t from any point on L2 to the fourth point as the independent variable and the abscissa x and ordinate y of that point as the dependent variables. That is, L2 can be expressed using formula (8).

[0112]

[0113] Given the slope of the first straight line L1, the coordinates of the first touch point, and the coordinates of the second touch point, L1 can be expressed by formula (9).

[0114] y-y1=k1(x-x1) (9)

[0115] Formula (5) can be derived by combining formulas (8) and (9).

[0116] The distance t1 between point f2 and point f1 is determined according to formula (5). If the preset distance mapping relationship is formula (10), the value of t2 can be determined according to formula (10). t2 represents the distance between the target compensation point to be added and the fourth point.

[0117] t2=t1×f(t1) (10)

[0118] Among them, f(t1) can be a is a constant. After testing, a can be 0.3.

[0119] As mentioned above, point P0 is located above the vertical line. Therefore, according to formula (8), the coordinates of point P0 (x o ,y o ). That is, use formula (11) to identify the coordinates of point P0

[0120]

[0121] After deformation,

[0122] In this way, the exact position of the compensation point P0 can be determined.

[0123] In the disclosed embodiment, if the target compensation point to be added is located between the second touch point and the third touch point, and the fourth point bisects the second line segment, the first distance between the first intersection point and the fourth point is first determined. Since the first intersection point and the fourth point lie on a vertical line, and the target compensation point and the fourth point also lie on a vertical line, the first intersection point, the fourth point, and the target compensation point all lie on the same vertical line. Therefore, the straight line on which the target compensation point lies is determined, narrowing the range for determining the target compensation point.

[0124] Furthermore, since the fourth point divides the second line segment into equal parts, it is evenly distributed on the second line segment. Since the fourth point and the target compensation point are on the same vertical line, the target compensation point can also be evenly distributed on the simulated touch trajectory, making the simulated touch estimation smoother.

[0125] After determining the first distance, a second distance having a preset distance mapping relationship with the first distance is determined. The preset distance mapping relationship can reduce the growth rate of the second distance value as the first distance value increases. Therefore, as the first distance value increases, the speed at which the target compensation point moves away from the second line segment gradually slows down, making the simulated touch trajectory smoother and reducing the probability of burrs. In addition, the preset distance mapping relationship can increase the growth rate of the second distance value as the first distance value decreases. Therefore, as the first distance value decreases, the speed at which the target compensation point approaches the second line segment gradually slows down, reducing the probability of insufficient curvature or reverse curvature in the simulated touch trajectory.

[0126] Figure 4 Schematic diagram of a device for determining a touch screen compensation point provided by an embodiment of the present disclosure. Figure 4 As shown, the device 20 includes:

[0127] A touch point acquisition unit 21 is used to acquire a first touch point, a second touch point, and a third touch point that are not on the same straight line and are collected at a preset frequency;

[0128] a first distance acquisition unit 22 configured to acquire, when the target compensation point to be added is located between the second touch point and the third touch point, a first distance between the first intersection point and a fourth point, the fourth point being a point on a second line segment formed by connecting the second touch point and the third touch point, the first intersection being an intersection of a first straight line and a perpendicular line, the first straight line being a straight line on which the first touch point and the second touch point are located, the perpendicular line being a straight line passing through the fourth point and perpendicular to the second line segment, and the target compensation point being on the perpendicular line;

[0129] A second distance determining unit 23 is configured to determine a second distance having a preset distance mapping relationship with the first distance, wherein the preset distance mapping relationship makes the second distance positively correlated with the first distance, and an increase in the second distance is negatively correlated with the first distance;

[0130] The target compensation point determination unit 24 is configured to determine a point on the vertical line that is the second distance away from the fourth point as the target compensation point.

[0131] For example, the apparatus in this embodiment includes but is not limited to desktop computers, televisions, mobile devices with large screens such as mobile phones, tablet computers, and other common electronic devices that require multiple chips to be cascaded to achieve driving.

[0132] Exemplarily, the apparatus may also be user equipment (UE), mobile device, user terminal, terminal, handheld device, computing device, or vehicle-mounted device, etc. Exemplarily, some examples of terminals include: display, smart phone or portable device, mobile phone, tablet computer, laptop computer, PDA, mobile Internet device (MID), wearable device, virtual reality (VR) device, augmented reality (AR) device, wireless terminal in industrial control (Industrial Control), wireless terminal in self-driving, wireless terminal in remote medical surgery, wireless terminal in smart grid (Smart Grid), wireless terminal in transportation safety (Transportation Safety), wireless terminal in smart city (Smart City), wireless terminal in smart home (Smart Home), wireless terminal in Internet of Vehicles, etc. For example, the server may be a local server or a cloud server.

[0133] Figure 5 Schematic diagram of an electronic device provided in an embodiment of the present disclosure. For example, the electronic device 1900 can be provided as a server or a terminal device. Figure 5 The electronic device 1900 includes a processing component 1922, which further includes one or more processors, and a memory resource represented by a memory 1932 for storing instructions executable by the processing component 1922, such as an application. The application stored in the memory 1932 may include one or more modules, each corresponding to a set of instructions. In addition, the processing component 1922 is configured to execute the instructions to perform the above-described method.

[0134] The electronic device 1900 may further include a power supply component 1926 configured to perform power management of the electronic device 1900, a wired or wireless network interface 1950 configured to connect the electronic device 1900 to a network, and an input / output (I / O) interface 1958. The electronic device 1900 may operate based on an operating system stored in the memory 1932, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™, or the like.

[0135] In an exemplary embodiment, a non-volatile computer-readable storage medium is also provided, such as a memory 1932 including computer program instructions that can be executed by the processing component 1922 of the electronic device 1900 to perform the above method.

[0136] The above description is merely an exemplary embodiment of the present invention and is not intended to limit the scope of protection of the present invention. The scope of protection of the present invention is determined by the appended claims.

[0137] The word “exemplary” is used exclusively herein to mean “serving as an example, example, or illustration.” Any embodiment described herein as “exemplary” is not necessarily to be construed as preferred or advantageous over other embodiments.

[0138] It should be noted that, in this document, the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, article, or apparatus comprising a series of elements includes not only those elements but also other elements not explicitly listed, or elements inherent to such process, method, article, or apparatus. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of other identical elements in the process, method, article, or apparatus comprising the element.

[0139] The flow charts and block diagrams in the accompanying drawings show the possible architecture, functions and operations of the systems, methods and computer program products according to multiple embodiments of the present disclosure. In this regard, each box in the flow chart or block diagram can represent a part of a module, program segment or instruction, and the part of the module, program segment or instruction contains one or more executable instructions for realizing the prescribed logical function. In some alternative implementations, the functions marked in the box can also occur in a sequence different from that marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flow chart, and the combination of the boxes in the block diagram and / or flow chart can be implemented by a dedicated hardware-based system that performs the prescribed function or action, or can be implemented by a combination of dedicated hardware and computer instructions.

[0140] While various embodiments of the present disclosure have been described above, the above descriptions are illustrative, non-exhaustive, and not intended to be limiting of the disclosed embodiments. Many modifications and variations will be apparent to those skilled in the art without departing from the scope and spirit of the described embodiments. The terminology used herein is selected to best explain the principles of the embodiments, their practical applications, or improvements to existing technologies, or to enable others skilled in the art to understand the embodiments disclosed herein.

Claims

1. A method for determining a touch screen compensation point, characterized in that: include: Acquire a first touch point, a second touch point, and a third touch point that are not on the same straight line and are collected at a preset frequency; When the target compensation point to be added is located between the second touch point and the third touch point, obtaining a first distance between the first intersection point and a fourth point, where the fourth point is a point on a second line segment formed by connecting the second touch point and the third touch point, the first intersection point is an intersection of a first straight line and a perpendicular line, the first straight line is a straight line on which the first touch point and the second touch point are located, the perpendicular line is a straight line passing through the fourth point and perpendicular to the second line segment, and the target compensation point is on the perpendicular line; Determining a second distance having a preset distance mapping relationship with the first distance, wherein the preset distance mapping relationship causes the second distance to be positively correlated with the first distance, and an increase in the second distance to be negatively correlated with the first distance; A point on the vertical line that is the second distance away from the fourth point is determined as the target compensation point.

2. The method according to claim 1, characterized in that The second line segment is equally divided by the fourth point, and before obtaining the first distance between the first intersection point and the fourth point, the method further includes: determining the coordinates of the fourth point according to the coordinates of the second touch point and the coordinates of the third touch point; according to and Determine the sine value of the perpendicular line and the cosine value of the perpendicular line; Wherein, sinθ is the sine value, cosθ is the cosine value, k2 is the slope of the vertical line, x3 is the abscissa of the third touch point, y3 is the ordinate of the third touch point; x2 is the abscissa of the second touch point, y2 is the ordinate of the second touch point; θ is the angle between the vertical line and the positive direction of the x-axis; according to determining the first distance, Wherein, t1 represents the first distance, k1 represents the slope of the first straight line, x1 is the horizontal coordinate of the first touch point, y1 is the vertical coordinate of the first touch point; x4 is the horizontal coordinate of the fourth point, y4 is the vertical coordinate of the fourth point.

3. The method according to claim 2, characterized in that Determining the target compensation point by taking a point on the vertical line that is the second distance from the fourth point as the target compensation point includes: According to y o =y4+t2sinθ and x o =x4+t2cosθ, determine the coordinates of the target compensation point, Among them, x o Indicates the horizontal coordinate of the target compensation point, y o represents the ordinate of the target compensation point, x4 is the abscissa of the fourth point, y4 is the ordinate of the fourth point, and t2 represents the second distance.

4. The method according to claim 1, wherein The method further comprises: Obtaining the touch screen's reporting rate and display frame rate; In a case where the reporting point rate is N+1 times the display frame rate, the number of the fourth points is determined to be N, where N is a positive integer and N≥1.

5. The method according to claim 2, characterized in that The determining the coordinates of the fourth point according to the coordinates of the second touch point and the coordinates of the third touch point includes: according to and determining the coordinates of the fourth point, Among them, x4 is the horizontal coordinate of the fourth point, y4 is the vertical coordinate of the fourth point, N represents the number of the fourth points, and M represents the Mth fourth point N≥M≥1.

6. The method according to claim 2, characterized in that The second line segment is divided equally by the fourth points, and the fourth points are symmetrically distributed about the perpendicular midline of the second line segment. Determining the first distance includes: A first distance between the first intersection point and any of the fourth points is determined as a first distance corresponding to each of the mutually symmetrical fourth points.

7. A device for determining a touch screen compensation point, characterized in that: include: A touch point acquisition unit, configured to acquire a first touch point, a second touch point, and a third touch point that are not on the same straight line and are collected at a preset frequency; a first distance acquisition unit, configured to acquire, when the target compensation point to be added is located between the second touch point and the third touch point, a first distance between the first intersection point and a fourth point, the fourth point being a point on a second line segment formed by connecting the second touch point and the third touch point, the first intersection point being an intersection of a first straight line and a perpendicular line, the first straight line being a straight line on which the first touch point and the second touch point are located, the perpendicular line being a straight line passing through the fourth point and perpendicular to the second line segment, and the target compensation point being on the perpendicular line; a second distance determining unit, configured to determine a second distance having a preset distance mapping relationship with the first distance, wherein the preset distance mapping relationship causes the second distance to be positively correlated with the first distance, and an increase in the second distance to be negatively correlated with the first distance; The target compensation point determining unit is configured to determine a point on the vertical line that is the second distance away from the fourth point as the target compensation point.

8. A display device, characterized in that: The device comprises a plurality of display units and at least one device for determining a touch screen compensation point according to claim 7.

9. An electronic device, characterized in that: include: processor; a memory for storing processor-executable instructions; The processor is configured to implement the method according to any one of claims 1 to 6 when executing the instructions stored in the memory.

10. A non-volatile computer-readable storage medium having computer program instructions stored thereon, characterized in that: When the computer program instructions are executed by a processor, the method according to any one of claims 1 to 6 is implemented.

Citation Information

Patent Citations

  • Curve fitting based touch trajectory smoothing method and system

    CN103902086A

  • Handwriting correcting method and system of touch screen

    CN105183341A