Processing method and device of electronic equipment, storage medium and electronic equipment
By switching filtering algorithms in electronic devices, the problem of insufficient response speed of electronic devices in high-heeled performance applications is solved, and a fast response and smooth user experience is achieved.
Patent Information
- Application Number
- CN202310811647.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-07-03
- Publication Date
- 2025-01-03
AI Technical Summary
When electronic devices run applications with high heel performance requirements, they cannot meet the response speed requirements of these applications, resulting in poor user experience.
By switching different filtering algorithms in electronic devices, when switching from applications with low-heeled hand performance requirements to applications with high-heeled hand performance requirements, the first filtering algorithm is switched to the second filtering algorithm, and the second filtering algorithm has a fast response speed. In the first filtering algorithm, the fast processing and response of touch information is ensured.
It improves the response speed and user experience of electronic devices in high-heeled performance applications, and meets the requirements of high-heeled performance applications, such as achieving fast response and smooth touch operation in gaming applications.
Smart Images

Figure CN119248167A_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of electronic technology, and in particular, relates to a processing method, device, storage medium and electronic device of an electronic device. Background Art
[0002] With the development of technology, more and more applications are installed in electronic devices. When running applications, electronic devices need to respond to user touch operations in a timely manner. Different applications have different requirements for the response speed of touch operations, that is, different applications have different requirements for hand-following performance. Some applications have high requirements for hand-following performance. In related technologies, when electronic devices run these applications, they cannot meet the requirements of these applications for hand-following performance. Summary of the invention
[0003] The embodiments of the present application provide a method, an apparatus, a storage medium and an electronic device for processing an electronic device. When the electronic device runs applications with high requirements for hand-following performance, the requirements of these applications for hand-following performance can be met.
[0004] In a first aspect, an embodiment of the present application provides a processing method of an electronic device, wherein the electronic device includes a touch screen, and the touch screen includes a touch module. The method includes:
[0005] When the electronic device switches from running a first type of application to running a second type of application, the first filtering algorithm currently used to filter the touch information collected by the touch module is switched to a second filtering algorithm, wherein the response speed of the second filtering algorithm is faster than the response speed of the first filtering algorithm;
[0006] Based on the second filtering algorithm, filtering the touch information collected by the touch module;
[0007] The second type of application responds to the filtered touch information.
[0008] In a second aspect, an embodiment of the present application further provides a processing device of an electronic device, wherein the electronic device includes a touch screen, the touch screen includes a touch module, and the device includes:
[0009] a switching module, configured to switch a first filtering algorithm currently used for filtering the touch information collected by the touch module to a second filtering algorithm when the electronic device switches from running a first type of application to running a second type of application, wherein a response speed of the second filtering algorithm is faster than a response speed of the first filtering algorithm;
[0010] A processing module, configured to filter the touch information collected by the touch module based on the second filtering algorithm;
[0011] The response module, the second type application responds to the touch information after filtering.
[0012] In a third aspect, an embodiment of the present application further provides a computer-readable storage medium on which a computer program is stored. When the computer program is run on a computer, the computer executes a processing method for an electronic device as provided in any embodiment of the present application.
[0013] In a fourth aspect, an embodiment of the present application further provides an electronic device, comprising a processor and a memory, wherein the memory has a computer program, and the processor executes a processing method of an electronic device as provided in any embodiment of the present application by calling the computer program.
[0014] In the embodiment of the present application, it is taken into account that different filtering algorithms have different response speeds. Therefore, when the electronic device switches from running a first type of application to running a second type of application, the first filtering algorithm currently used to filter the touch information collected by the touch module is switched to a second filtering algorithm, and the response speed of the second filtering algorithm is faster than the response speed of the first filtering algorithm. Specifically, the first type of application has relatively low requirements for tracking performance, while the second type of application has relatively high requirements for tracking performance. When the electronic device runs the second type of application, the user performs touch operations on the touch screen, and the touch module collects touch information of the user's fingers. The electronic device filters the collected touch information based on the second filtering algorithm. The response speed of the second filtering algorithm is relatively fast, so that the touch information collected by the touch module can be quickly filtered, and the time delay caused by the filtering process is very small. Therefore, the second type of application can quickly respond to the touch information after filtering, and quickly follow the touch operation of the user's finger to display the corresponding content. Therefore, by switching the filtering algorithm with a faster response speed, the tracking performance of the electronic device can be improved. Even when the electronic device is running an application with high requirements for tracking performance, such as running a game application, the tracking performance of the electronic device can be improved to meet the requirements of these applications for tracking performance. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] The technical solution and beneficial effects of the present application will be made apparent by describing in detail the specific implementation methods of the present application in conjunction with the accompanying drawings.
[0016] Figure 1 A first flow chart of a processing method for an electronic device provided in an embodiment of the present application.
[0017] Figure 2 A comparison chart of hand tracking performance using different filtering algorithms provided in an embodiment of the present application.
[0018] Figure 3 A second flow chart of the processing method of the electronic device provided in the embodiment of the present application.
[0019] Figure 4 A schematic diagram of a first structure of a processing device of an electronic device provided in an embodiment of the present application.
[0020] Figure 5 A first structural schematic diagram of an electronic device provided in an embodiment of the present application.
[0021] Figure 6 A second structural schematic diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0022] Please refer to the drawings, where the same component symbols represent the same components. The principle of the present application is illustrated by implementing it in an appropriate computing environment. The following description is based on the illustrated specific embodiments of the present application, which should not be considered as limiting other specific embodiments of the present application that are not described in detail herein.
[0023] See also Figure 1 , Figure 1 1 is a first flow chart of a processing method for an electronic device provided in an embodiment of the present application. An embodiment of the present application provides a processing method for an electronic device. The method may include the following steps:
[0024] In 101, when the electronic device switches from running a first type of application to running a second type of application, a first filtering algorithm currently used for filtering touch information collected by a touch module is switched to a second filtering algorithm, and a response speed of the second filtering algorithm is faster than a response speed of the first filtering algorithm;
[0025] In 102, based on a second filtering algorithm, the touch information collected by the touch module is filtered;
[0026] In 103 , the second type application responds to the filtered touch information.
[0027] With the development of technology, more and more applications are installed in electronic devices. When running applications, electronic devices need to respond to user touch operations in a timely manner. Different applications have different requirements for the response speed of touch operations, that is, different applications have different requirements for hand-following performance. Some applications have high requirements for hand-following performance. In related technologies, when electronic devices run these applications, the requirements for hand-following performance of these applications cannot be met.
[0028] The electronic device may be a smart phone, tablet computer, PDA, laptop computer, desktop computer, etc. The electronic device includes a touch module, and the user can use a finger or a stylus pen to perform touch operation on the touch screen of the electronic device. The touch module can collect touch information of the user's finger or stylus pen, and the content displayed on the touch screen of the electronic device can respond in real time according to the touch information.
[0029] The currently running application is the application currently displayed on the touch screen. Taking the electronic device as a smart phone as an example, the currently running application can be understood as the application running in the foreground of the desktop, rather than the application running in the background.
[0030] Taking the example of a user performing touch operations on the touch screen of an electronic device with his fingers, tracking performance can be understood as: the speed at which the touch screen follows the touch operation of the user's fingers and displays accordingly. For example, when the user's finger slides a certain distance on the touch screen of the electronic device, the touch screen can display according to the actual touch position of the finger. The higher the tracking performance, the smaller the delay between the touch operation and the corresponding content displayed on the touch screen, the faster the response speed, and the smoother the content displayed on the touch screen.
[0031] In the embodiments of the present application, taking into account that different applications have different requirements for hand-following performance, some applications have higher requirements for hand-following performance, while some applications do not have high requirements for hand-following performance. Therefore, different applications can be classified, for example, into: first type applications and second type applications. The first type of applications have lower hand-following performance requirements than the second type of applications. It should be noted that the embodiments of the present application can classify applications at more levels based on different requirements for hand-following performance, for example, they can also be classified into third type applications, fourth type applications, etc., and the present application does not limit this.
[0032] In an embodiment of the present application, when the electronic device switches from running a first type of application to running a second type of application, the first filtering algorithm currently used to filter the touch information collected by the touch module is switched to a second filtering algorithm, and the response speed of the second filtering algorithm is faster than that of the first filtering algorithm.
[0033] Among them, the first type of application has relatively low requirements for tracking performance, such as desktop applications, video applications, photo applications, etc., which have relatively low touch operation frequencies on the touch screen, and relatively low requirements for the response speed of touch operations. For example, when running a photo application, the user's touch operations include switching focal length, selecting focus, flash on / off, confirming photo taking and other function selection operations. All functions can be satisfied without particularly high tracking performance, and power consumption can be reduced, which is not prone to misoperation. The second type of application has relatively high requirements for tracking performance, such as game applications, in which the user's touch operation frequency on the touch screen is relatively high, and the content displayed on the touch screen is required to quickly respond to the user's finger touch operation on the touch screen, without causing response delays due to the low tracking performance of the touch screen, thereby improving user experience and satisfaction.
[0034] It is understandable that for the touch information collected by the touch module, the electronic device will use a filtering algorithm to filter the touch information to reduce or remove noise, thereby improving the accuracy of the touch position coordinate positioning. Different filtering algorithms have different characteristics. For example, when the electronic device runs the first type of application, the first filtering algorithm for filtering the touch information collected by the touch module can be an infinite impulse response filtering algorithm (IIR filtering). Using IIR filtering to filter the touch information can make the linearity of the filtered touch information good, but relatively speaking, the filtering process also produces a certain delay, so the response speed is relatively slow.
[0035] Therefore, when it is recognized that the electronic device switches from running the first type of application to running the second type of application, the first filtering algorithm can be switched to the second filtering algorithm. The response speed of the second filtering algorithm is faster. For example, the second filtering algorithm can be a mean filtering algorithm. The mean filtering algorithm is used to filter the touch information. The phase deviation of the touch information after filtering is small, and the time delay generated by the filtering process is small, so that the response speed is fast, but relatively speaking, the linearity of the touch information after filtering is poor.
[0036] After comprehensively considering the characteristics of different filtering algorithms, when the electronic device runs the second type of application, the second filtering algorithm is used to filter the collected touch information. Specifically, the user performs a touch operation on the touch screen, and the touch module collects the touch information of the user's finger. The electronic device performs filtering processing on the collected touch information based on the second filtering algorithm, so that the touch information collected by the touch module can quickly complete the filtering processing, and the delay caused by the filtering processing is very small, so that the second type of application can quickly respond to the touch information after the filtering processing, and quickly follow the touch operation of the user's finger to display the corresponding content. For example, when the game application is a shooting application, the user needs to perform a quick sliding operation to quickly aim the gun at the target. Since the electronic device switches to using the second filtering algorithm to filter the collected touch information, the delay caused by the filtering processing is small. Therefore, the shooting game application can quickly respond to the touch information after the filtering processing, and promptly follow the sliding operation of the user's finger to quickly aim the gun at the target, and the displayed content is more timely and smooth. Therefore, by switching to a filtering algorithm with a faster response speed, the hand-tracking performance of the electronic device can be improved. Even when the electronic device is running an application with high requirements for hand-tracking performance, such as running a game application, the hand-tracking performance of the electronic device can be improved to meet the requirements of these applications for hand-tracking performance.
[0037] Please refer to Figure 2 , Figure 2 A comparison chart of hand tracking performance using different filtering algorithms provided in the embodiment of the present application. The touch module can collect touch information through multiple sampling points, and the touch information includes coordinate information. The electronic device uses the first filtering algorithm or the second filtering algorithm to filter the coordinate information collected by the multiple sampling points to obtain the coordinate information after filtering of the multiple sampling points. Figure 2 The horizontal axis represents the sampling point count. Time 1 to time 51 represent different times, corresponding to 51 sampling points. The vertical axis represents the distance difference between the coordinate information of multiple sampling points after filtering and the coordinate information of the actual touch position of the user on the touch screen from time 1 to time 51. Figure 2It can be seen that when the electronic device adopts the second filtering algorithm, as shown in curve L1, the distance difference between the coordinate information of the sampling point after filtering and the coordinate information of the actual touch position of the user on the touch screen is small, approximately in the range of [-5,5], and when the electronic device adopts the first filtering algorithm, as shown in curve L2, the distance difference between the coordinate information of the sampling point after filtering and the coordinate information of the actual touch position of the user on the touch screen is large, approximately in the range of [-15,-20]. It can be understood that the smaller the distance difference between the coordinate information of the sampling point after filtering and the coordinate information of the actual touch position of the user on the touch screen is, the better the hand-following performance is. Therefore, compared with the first filtering algorithm, when the electronic device adopts the second filtering algorithm, the second type of application can better follow the actual touch operation of the user's finger to display the corresponding content. When the user slides a distance to reach the same target position, the touch screen takes less time to display the corresponding content. For example, when running a game application, the game character or props can be moved faster, so that the game scene screen switches faster, thereby improving the faster response speed, that is, improving the hand-following performance of the electronic device.
[0038] In one embodiment, when the electronic device switches from running the second type of application to running the first type of application, the second filtering algorithm currently filtering the touch information collected by the touch module can be switched to the first filtering algorithm. Although the response speed of the first filtering algorithm is slower than the response speed of the second filtering algorithm, the first type of application has relatively low requirements for hand-following performance, and the linearity of the touch information processed by the first filtering algorithm is good. Therefore, in the embodiment of the present application, the electronic device can flexibly switch the filtering algorithm according to the type of application running, so as to not only take into account the hand-following performance but also the accuracy of the touch information to prevent misoperation. For example, when the second type of application is a game application, the embodiment of the present application can also be understood as determining whether the current use scenario of the electronic device is a game scenario or an ordinary use scenario. If the current use scenario is a game scenario, the first filtering algorithm currently filtering the touch information collected by the touch module is switched to the second filtering algorithm to improve the sensitivity of the touch screen and enable the user to achieve a better gaming experience. If the current use scenario is an ordinary use scenario, the second filtering algorithm currently filtering the touch information collected by the touch module is controlled to switch to the first filtering algorithm to reduce the power consumption of the touch display screen.
[0039] See also Figure 3 , Figure 3 A second flow chart of a processing method for an electronic device provided in an embodiment of the present application. The electronic device includes a touch module. The method may include the following steps:
[0040] In 201, when the electronic device switches from running a first type of application to running a second type of application, the sampling rate of the touch module is increased from the first sampling rate to the second sampling rate, and the second sampling rate is greater than the first sampling rate;
[0041] In 202 , the touch module collects touch information through a plurality of sampling points based on a second sampling rate.
[0042] The electronic device includes a touch module. The user can use fingers or a stylus to perform touch operations on the touch screen of the electronic device. The touch module can collect touch information from the user's fingers or stylus. Based on the touch information, the content displayed on the touch screen of the electronic device can respond in real time.
[0043] Taking the example of a user performing touch operations on the touch screen of an electronic device with his fingers, tracking performance can be understood as: the speed at which the touch screen follows the touch operation of the user's fingers and displays accordingly. For example, when the user's finger slides a certain distance on the touch screen of the electronic device, the touch screen can display according to the actual touch position of the finger. The higher the tracking performance, the smaller the delay between the touch operation and the corresponding content displayed on the touch screen, the faster the response speed, and the smoother the content displayed on the touch screen.
[0044] In the embodiments of the present application, taking into account that different applications have different requirements for hand-following performance, some applications have higher requirements for hand-following performance, while some applications do not have high requirements for hand-following performance. Therefore, different applications can be classified, for example, into: first type applications and second type applications. The first type of applications have lower hand-following performance requirements than the second type of applications. It should be noted that the embodiments of the present application can classify applications at more levels based on different requirements for hand-following performance, for example, they can also be classified into third type applications, fourth type applications, etc., and the present application does not limit this.
[0045] In the embodiment of the present application, when the electronic device switches from running a first type of application to running a second type of application, the sampling rate of the touch module can be increased from the first sampling rate to the second sampling rate, and the second sampling rate is greater than the first sampling rate.
[0046] Among them, the first type of application has relatively low requirements for hand-following performance, such as desktop applications, video applications, etc., which have relatively low touch operation frequency on the touch screen and relatively low requirements for the response speed of touch operation; the second type of application has relatively high requirements for hand-following performance, such as game applications, in which users have relatively high touch operation frequency on the touch screen, and require the content displayed on the touch screen to quickly respond to the touch operation of the user's finger on the touch screen. Specifically, for example, in a gun game application, the user needs to perform a relatively fast sliding operation to quickly aim the gun at the target. Therefore, when the electronic device runs a gun game application, it needs to quickly follow the sliding operation of the user's finger to display the corresponding game interface to improve the user's experience.
[0047] Exemplarily, the user can pre-set the second type of application. For example, the user can set a whitelist according to his own usage habits. The whitelist records applications that have relatively high requirements for hand tracking performance. For example, the whitelist includes application A, application C, application D, application E, etc. When the electronic device switches to running an application in the whitelist, it can be considered that the electronic device switches from running the first type of application to running the second type of application. Exemplarily, the application currently running on the electronic device can be compared with the whitelist, and the comparison can be made by the name, number, etc. of the two.
[0048] In addition to presetting a whitelist, electronic devices can also make judgments based on the number of interfaces, operating frequency, response speed, screen refresh rate, etc. required by the application currently running on the electronic device. Only when several or all of them are met are they considered to be second-type applications. It is understandable that not all game applications are second-type applications, and game applications with fewer touch operations (such as chess and card game applications) may not be second-type applications. Game applications with more touch operations (such as shooting, racing, and fighting game applications) require more interfaces, more touch operations, and high response requirements. Game applications need to be determined as second-type applications.
[0049] Exemplarily, a startup flag may be set for the second type of application, and whether the startup flag is set may be monitored in real time. If the flag is detected to be set, it may be determined that the foreground application of the electronic device is switched to run the second type of application.
[0050] When the electronic device is running a first type of application, the first application has relatively low requirements for hand-following performance, and the touch module can collect touch information based on a first sampling rate. For example, the first sampling rate can be 125 Hz, so the touch module can obtain touch information through 125 sampling points per second. When the electronic device switches to running a second type of application, the second type of application has relatively high requirements for hand-following performance, and the touch module switches to collecting touch information based on a second sampling rate. For example, the second sampling rate can be 360 Hz, so the touch module can obtain touch information through 360 sampling points per second. It can be understood that the higher the sampling rate, the more sampling points of the touch module per unit time. During the touch operation of the user, for example, the user's finger quickly slides a distance on the touch screen of the electronic device. Based on the second sampling rate, the touch module can also obtain the touch information corresponding to the actual touch position of the finger more timely, so that the touch screen can display more timely following the actual touch position of the finger. Therefore, by increasing the first sampling rate to the second sampling rate, the hand-following performance of the electronic device can be improved.
[0051] In one embodiment, when the electronic device switches from running a second type of application to running a first type of application, the second sampling rate can be switched to the first sampling rate. Since the first type of application has relatively low requirements for hand tracking performance, lowering the sampling rate can reduce the power consumption of the electronic device. Therefore, the electronic device in the embodiment of the present application can flexibly switch the sampling rate according to the type of application running, thereby taking into account not only the application's requirements for hand tracking performance, but also the overall power consumption of the electronic device.
[0052] In 203, the touch track trend is obtained according to the coordinate information of the current sampling point and the coordinate information of the historical sampling points;
[0053] In 204 , before the coordinate information of the next sampling point is collected, a virtual sampling point is predicted according to the coordinate information of the current sampling point and the touch track trend.
[0054] Furthermore, the embodiments of the present application take into account that the sampling rate of the touch module is limited by hardware. For example, the maximum sampling rate of the touch module is 360 Hz. When the second sampling rate of the touch module reaches 360 Hz, the tracking performance of the electronic device can no longer be improved by increasing the sampling rate of the touch module. Therefore, in order to meet the higher tracking performance requirements of the second type of application, the sampling points per unit time can be further increased by software.
[0055] Specifically, the touch track trend is obtained according to the coordinate information of the current sampling point and the coordinate information of the historical sampling points, and before the coordinate information of the next sampling point is collected, the virtual sampling point is predicted according to the coordinate information of the current sampling point and the touch track trend.
[0056] Exemplarily, the touch module collects touch information based on the second sampling rate. When the user's finger slides on the touch screen, multiple sampling points are collected every second. For example, the second sampling rate can be 360HZ, so the touch module can obtain touch information through 360 sampling points every second. It can be understood that the touch point includes the coordinate information of the sampling point. For example, the current sampling point is point B, and the previous sampling point of point B is point A. The touch trajectory trend can be predicted based on the current coordinate information of point B and the coordinate information of the historical sampling point A. Therefore, before the touch module obtains the next sampling point C, a virtual sampling point b is predicted based on the coordinate information of the current sampling point B and the touch trajectory trend, wherein the coordinate information of point b can be located between the coordinate information of the current sampling point B and the next sampling point C, so that a virtual sampling point is inserted between the two adjacent sampling points collected by the touch module, and the touch information corresponding to the virtual sampling point is obtained, thereby improving the unit time of the electronic device. The number of sampling points in the time interval can improve the sampling rate of the electronic device, for example, by increasing 360HZ to 720HZ, touch information can be obtained through 720 sampling points per second, so that the electronic device can break through the hardware limitations of the touch module and further improve the sampling rate. It can be understood that after the touch module collects the touch information of point B, but before the touch information of point C is collected, the touch information of point B can be collected in advance, so that the touch position of the user's finger can be collected relatively in advance, so that the second application type can respond to the touch information of point B in advance when the touch module has not collected the touch information of point C, thereby improving the hand tracking performance of the electronic device. It should be noted that the historical sampling point can be one or more, and the embodiments of the present application are not limited to this.
[0057] In 205, the first filtering algorithm currently used to filter the touch information collected by the touch module is switched to a second filtering algorithm, and the response speed of the second filtering algorithm is faster than the response speed of the first filtering algorithm;
[0058] In 206, based on a second filtering algorithm, filtering is performed on the touch information collected by the touch module through the multiple sampling points and the touch information collected by the virtual sampling points;
[0059] In 207 , the second type application responds to the filtered touch information.
[0060] Furthermore, in addition to improving the sampling points per unit time of the electronic device, the embodiment of the present application also switches the first filtering algorithm currently used to filter the touch information collected by the touch module to a second filtering algorithm when the electronic device switches from running a first type of application to running a second type of application, and the response speed of the second filtering algorithm is faster than that of the first filtering algorithm.
[0061] The electronic device may use a second filtering algorithm to filter the touch information collected by the touch module through multiple sampling points and the touch information collected by the virtual sampling points, and the second type application responds to the touch information after the filtering process.
[0062] It is understandable that for the touch information collected by the touch module and the touch information collected by the virtual collection point, the electronic device will use a filtering algorithm to filter the touch information to reduce or remove noise, thereby improving the accuracy of the sampling point coordinate positioning. It is understandable that different filtering algorithms have different characteristics. For example, when the electronic device runs the first type of application, the first filtering algorithm for filtering the touch information collected by the touch module can be an infinite impulse response filtering algorithm (IIR filtering). Using IIR filtering to filter the touch information can make the linearity of the filtered touch information good, but relatively speaking, the filtering process also produces a certain delay, so the response speed is relatively slow.
[0063] When it is recognized that the electronic device switches from running a first type of application to running a second type of application, the first filtering algorithm can be switched to a second filtering algorithm. The second filtering algorithm has a fast response speed. For example, the second filtering algorithm can be a mean filtering algorithm. The mean filtering algorithm is used to filter the touch information. The phase deviation of the touch information after filtering is small, and the time delay generated by the filtering process is small, so the response speed is fast, but relatively speaking, the linearity of the touch information after filtering is poor.
[0064] Thus, when the electronic device runs the second type of application, the user performs a touch operation on the touch screen, and the electronic device performs a filtering process on the touch information collected by the touch module through multiple sampling points and the touch information collected by the virtual sampling points based on the second filtering algorithm, so that the touch information can quickly complete the filtering process, and the delay caused by the filtering process is very small, so that the second type of application can quickly respond to the touch information after the filtering process, and quickly follow the touch operation of the user's finger to display the corresponding content. For example, when the game application is a gun battle application, the user needs to perform a fast sliding operation to quickly aim the gun at the target. Since the electronic device switches to using the second filtering algorithm to filter the collected touch information, the delay caused by the filtering process is small, so the gun battle game application can quickly respond to the touch information after the filtering process, and timely follow the sliding operation of the user's finger, and quickly aim the gun at the target, and the display content is more timely and smooth. Therefore, by switching the filtering algorithm with a faster response speed, the hand-following performance of the electronic device can be improved, so that even when the electronic device is running an application with high requirements for hand-following performance, such as running a game application, the hand-following performance of the electronic device can be improved, and the requirements of these applications for hand-following performance can be met.
[0065] Exemplarily, the IIR filtering algorithm can be: Xn=Xn-1+T*(currentCoor-Xn-1), where Xn represents the coordinate information output after filtering of the current sampling point, Xn-1 represents the coordinate information output after filtering of the previous sampling point, T represents the filtering coefficient, and currentCoor represents the initial coordinate information of the current sampling point obtained. The mean filtering algorithm can be: Xn=(Xn'*A+Xn-1*B+Xn-2*C) / 3, wherein Xn represents the coordinate information outputted by the current sampling point after filtering, Xn' represents the initial coordinate information of the current sampling point obtained, Xn-1 represents the coordinate information outputted by the previous sampling point after filtering, and Xn-2 represents the coordinate information outputted by the previous sampling point after filtering. A, B, C, etc. are weight value parameters, and the A, B, and C values can be changed according to the debugging results. Furthermore, different weight value parameters can be debugged for different second-type applications. For example, for a certain game application, the linearity requirements are not high, and the weight value parameters can be adjusted to relatively weaken the filtering effect and improve the hand tracking performance, or even directly respond to touch information without filtering. It can be seen that the IIR filtering algorithm is greatly affected by the coordinate information of the historical sampling points, while the mean filtering algorithm can be less affected by the coordinate information of the historical sampling points by adjusting the A, B, and C values. In other words, the mean filtering algorithm is more affected by the coordinate information of the current sampling point and is closer to the touch operation of the current user's finger, thus responding faster.
[0066] In one embodiment, after the filtering algorithm is switched from the first filtering algorithm to the second filtering algorithm, the trigger reporting threshold can also be switched from the first reporting threshold to the second reporting threshold, and the second reporting threshold is smaller than the first reporting threshold; when the capacitance value in the touch information collected by the touch module is greater than the second reporting threshold, the touch information is filtered based on the second filtering algorithm.
[0067] It can be understood that the touch information collected by the touch module includes a capacitance value. When the user's finger approaches the touch module, if the capacitance value in the touch information collected by the touch module is greater than the second reporting threshold, the touch information is filtered based on the second filtering algorithm, and the second type of application responds to the touch information after filtering; if the voltage change does not reach the second reporting threshold, the touch information is discarded. In the embodiment of the present application, when the electronic device switches to running the second type of application, the trigger reporting threshold is reduced from the first reporting threshold to the second reporting threshold, so that the touch module can reach the reporting domain value even in the case of a relatively small capacitance, thereby improving the sensitivity of the touch module and accelerating the acquisition of touch information corresponding to the sampling point. For example, as long as the user's finger approaches the touch screen, the corresponding touch information can be obtained without touching the touch screen, so that the touch screen quickly generates corresponding display content, thereby further improving the hand tracking performance of the electronic device.
[0068] In one embodiment, the touch module includes a self-capacitive touch layer and a mutual-capacitive touch layer. When the touch information is identified as single-finger touch information, the self-capacitive touch layer is used to receive the single-finger touch information. If the touch module integrates a self-capacitive touch layer and a mutual-capacitive touch layer, when the touch information is identified as single-finger touch information, the self-capacitive touch layer is used to obtain the single-finger touch information. The self-capacitive touch layer can obtain the coordinate information more sensitively, thereby improving the response speed of the electronic device and improving the hand-following performance of the electronic device. When the touch information is identified as multi-finger touch information, it is flexibly switched to using the mutual-capacitive touch layer to receive the multi-finger touch information to accurately obtain the multi-finger touch information.
[0069] In one embodiment, when the electronic device switches from running the first type of application or the second type of application to running the third type of application, the third type of application directly responds to the touch information received by the touch module. It can be understood that based on different requirements for hand-following performance or different application types, applications can be classified at more levels. The third type of application can be an application that can predict the user's touch operation in advance at least in some application scenarios. For example, some application scenarios that require fast clicks, such as shooting game applications, can predict that the user quickly clicks the shooting button to perform a shooting operation. In order to improve the hand-following performance of the electronic device, it can directly respond to the touch information received by the touch module without filtering the touch information, thereby saving the time required for filtering the touch information, quickly responding to the user's touch operation, and not missing the shooting opportunity.
[0070] In one embodiment, when the electronic device switches from running a first type of application to running a second type of application, the first filtering algorithm can be switched to the second filtering algorithm. Furthermore, in combination with changes in the current application scenario, in some suitable scenarios, the electronic device can predict the user's touch operation and directly respond to the touch information. For example, if the user performs multiple consecutive identical touch operations at the same touch position, such as multiple consecutive clicks or sliding operations, then the second filtering algorithm may not be used to filter the collected touch information, and the second type of application directly responds to the touch information; when it is identified that the user's touch operation method has changed, it is switched to the second filtering method to filter the collected touch information. Therefore, in the embodiment of the present application, the filtering algorithm method can be dynamically changed according to different application types and different application scenarios, which not only considers the hand tracking performance but also the accuracy of the touch information to prevent misoperation.
[0071] In the embodiment of the present application, if it is recognized that when the electronic device switches from running a first type of application to running a second type of application, the sampling rate of the touch module can be increased from the first sampling rate to the second sampling rate, such as from 125HZ to 360HZ. Furthermore, the touch trajectory trend can be obtained according to the coordinate information of the current sampling point and the coordinate information of the historical sampling points. Before collecting the coordinate information of the next sampling point, the virtual sampling point is predicted according to the coordinate information of the current sampling point and the touch trajectory trend, thereby further increasing the sampling points per unit time, such as from 360HZ to 720HZ, so that during the touch operation of the user, the touch module can collect the touch position of the user's finger more quickly. Furthermore, the first filtering algorithm for filtering the touch information can be switched to a second filtering algorithm. The response speed of the second filtering algorithm is faster than that of the first filtering algorithm. Therefore, when the electronic device runs the second type of application, the second filtering algorithm is used to filter the touch information collected by the touch module through multiple sampling points and the touch information collected by the virtual sampling points, so that the touch information can be quickly filtered and the time delay required for the filtering can be reduced, so that the second type of application can quickly respond to the touch information after the filtering process. Even when the electronic device is running an application with high requirements for hand-following performance, such as running a game application, the requirements of these applications for hand-following performance can be met.
[0072] See also Figure 4 , Figure 4 A first structural diagram of a processing device of an electronic device provided in an embodiment of the present application, wherein the processing device 400 of the electronic device includes a touch module, and the processing device 400 of the electronic device includes a switch 401, a processing module 402 and a response module 404, as follows:
[0073] The switching module 401 is used to switch the first filtering algorithm currently used to filter the touch information collected by the touch module to the second filtering algorithm when the electronic device switches from running the first type of application to running the second type of application, and the response speed of the second filtering algorithm is faster than the response speed of the first filtering algorithm;
[0074] The processing module 402 is used to filter the touch information collected by the touch module based on the second filtering algorithm;
[0075] The response module 403 is used for the second type application to respond to the touch information after filtering.
[0076] In one implementation, the switching module 401 may be used to switch the infinite impulse response filtering algorithm currently used to filter the touch information collected by the touch module to a mean filtering algorithm.
[0077] In one implementation, the switching module 401 may be used to increase the sampling rate of the touch module from a first sampling rate to a second sampling rate, where the second sampling rate is greater than the first sampling rate.
[0078] In one implementation, the switching module 401 may be used to: the touch module collects touch information through multiple sampling points based on a second sampling rate; obtains a touch trajectory trend based on coordinate information of a current sampling point and coordinate information of historical sampling points; and predicts a virtual sampling point based on the coordinate information of the current sampling point and the touch trajectory trend before collecting coordinate information of a next sampling point; the processing module 402 may be used to: perform filtering processing on the touch information collected by the touch module through multiple sampling points and the touch information collected by the virtual sampling points based on a second filtering algorithm.
[0079] In one embodiment, the switching module 401 can be used to: switch the trigger reporting threshold from a first reporting threshold to a second reporting threshold, where the second reporting threshold is smaller than the first reporting threshold; the processing module 402 can be used to: when the capacitance value in the touch information collected by the touch module is greater than the second reporting threshold, filter the touch information based on a second filtering algorithm.
[0080] In one implementation, the touch module includes a self-capacitive touch layer and a mutual-capacitive touch layer, and the switching module 401 can be used to: when the touch information is identified as single-finger touch information, use the self-capacitive touch layer to obtain the single-finger touch information.
[0081] In one implementation, the switching module 401 may be configured to: when the electronic device switches from running the first type application or the second type application to running the third type application, the third type application directly responds to the touch information received by the touch module.
[0082] The application embodiment provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed on a computer, the computer executes the process in the thread scheduling method provided in this embodiment.
[0083] An embodiment of the present application also provides an electronic device, including a memory and a processor, wherein the processor is used to execute the process in the thread scheduling method provided in the present embodiment by calling a computer program stored in the memory.
[0084] For example, the electronic device may be a mobile terminal such as a tablet computer or a smart phone. Figure 5 , Figure 5 The first structural diagram of the electronic device provided in the embodiment of the present application. The electronic device 500 includes a processor 501, a memory 502 and a touch screen 503. The processor 501 is electrically connected to the memory 502 and the touch screen 503.
[0085] The processor 501 is the control center of the electronic device 500. It uses various interfaces and lines to connect various parts of the entire electronic device. It executes various functions of the electronic device and processes data by running or calling computer programs stored in the memory 502, and calling data stored in the memory 502, thereby monitoring the electronic device as a whole.
[0086] The memory 502 may be used to store computer programs and data. The computer programs stored in the memory 502 include instructions that can be executed in the processor. The computer programs may constitute various functional modules. The processor 501 executes various functional applications and data processing by calling the computer programs stored in the memory 502.
[0087] The touch screen 503 and the touch screen 505 can be used to display information input by the user or information provided to the user and various graphical user interfaces of the electronic device, which can be composed of images, texts, icons, videos and any combination thereof. Among them, the touch screen includes a touch module, which can be used when the user performs a touch operation on the touch screen of the electronic device, and the touch module can collect corresponding touch information so that the electronic device responds according to the touch information.
[0088] In this embodiment, the processor 501 in the electronic device 500 loads instructions corresponding to the processes of one or more computer programs into the memory 502 according to the following steps, and the processor 501 runs the computer programs stored in the memory 502 to implement various functions:
[0089] When the electronic device switches from running the first type of application to running the second type of application, the first filtering algorithm currently used for filtering the touch information collected by the touch module is switched to the second filtering algorithm, and the response speed of the second filtering algorithm is faster than the response speed of the first filtering algorithm;
[0090] Based on the second filtering algorithm, filtering the touch information collected by the touch module;
[0091] The second type of application responds to the touch information after filtering.
[0092] In one implementation, the processor 501 may further execute: the first filtering algorithm is an infinite impulse response filtering algorithm, and the second filtering algorithm is a mean filtering algorithm.
[0093] In one implementation, before switching the first filtering algorithm to the second filtering algorithm, the processor 501 may further execute: increasing the sampling rate of the touch module from the first sampling rate to the second sampling rate, where the second sampling rate is greater than the first sampling rate.
[0094] In one implementation, after increasing the sampling rate of the touch module from the first sampling rate to the second sampling rate, the processor 501 may further execute: the touch module collects touch information through a plurality of sampling points based on the second sampling rate;
[0095] The touch track trend is obtained based on the coordinate information of the current sampling point and the coordinate information of the historical sampling points;
[0096] Before collecting the coordinate information of the next sampling point, a virtual sampling point is predicted based on the coordinate information of the current sampling point and the touch track trend;
[0097] Based on the second filtering algorithm, filtering the touch information collected by the touch module includes:
[0098] Based on the second filtering algorithm, the touch information collected by the touch module through the multiple sampling points and the touch information collected by the virtual sampling points are filtered.
[0099] In one embodiment, after the filtering algorithm is switched from the first filtering algorithm to the second filtering algorithm, the processor 501 may further execute: switching the trigger reporting threshold from the first reporting threshold to the second reporting threshold, the second reporting threshold being less than the first reporting threshold; in filtering the touch information collected by the touch module based on the second filtering algorithm, the processor 501 may further execute: when the capacitance value in the touch information collected by the touch module is greater than the second reporting threshold, filtering the touch information based on the second filtering algorithm.
[0100] In one implementation, the touch module includes a self-capacitive touch layer and a mutual-capacitive touch layer, and the processor 501 may further execute: when the touch information is identified as single-finger touch information, using the self-capacitive touch layer to obtain the single-finger touch information.
[0101] In one implementation, the processor 501 may further execute: when the electronic device switches from running the first type application or the second type application to running the third type application, the third type application directly responds to the touch information received by the touch module.
[0102] See also Figure 6 , Figure 6 A second structural diagram of an electronic device provided in an embodiment of the present application. The electronic device 500 further includes: a radio frequency circuit 504, a control circuit 505, an input unit 506, an audio circuit 505, a sensor 508, and a power supply 509. The processor 501 is electrically connected to the radio frequency circuit 503, the touch screen 505, the control circuit 505, the input unit 506, the audio circuit 505, the sensor 508, and the power supply 509, respectively.
[0103] The radio frequency circuit 504 is used to send and receive radio frequency signals to communicate with network devices or other electronic devices through wireless communication.
[0104] The control circuit 505 is electrically connected to the touch screen 503 and is used to control the touch screen 504 to display information.
[0105] The input unit 506 can be used to receive input numbers, character information or user feature information (such as fingerprints), and generate keyboard, mouse, joystick, optical or trackball signal input related to user settings and function control. The input unit 506 can include a fingerprint recognition module.
[0106] The audio circuit 505 can provide an audio interface between the user and the electronic device through a speaker and a microphone. The audio circuit 505 includes a microphone. The microphone is electrically connected to the processor 501. The microphone is used to receive voice information input by the user.
[0107] The sensor 508 is used to collect external environment information. The sensor 508 may include one or more sensors such as an environment brightness sensor, an acceleration sensor, and a gyroscope.
[0108] The power supply 509 is used to supply power to various components of the electronic device 500. In some implementations, the power supply 509 may be logically connected to the processor 501 through a power management system, so that the power management system can manage charging, discharging, power consumption, and other functions.
[0109] Although not shown in the figure, the electronic device 500 may also include a camera, a Bluetooth module, etc., which will not be described in detail here.
[0110] It should be noted that a person skilled in the art can understand that all or part of the steps in the various methods of the above embodiments can be completed by instructing related hardware through a computer program, and the computer program can be stored in a computer-readable storage medium, and the storage medium may include but is not limited to: a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk, etc.
[0111] In addition, the terms "first", "second", and "third" in this application are used to distinguish different objects, rather than to describe a specific order. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product, or device that includes a series of steps or modules is not limited to the listed steps or modules, but some embodiments also include steps or modules that are not listed, or some embodiments also include other steps or modules inherent to these processes, methods, products, or devices.
[0112] The processing method, device, storage medium and electronic device of the electronic device provided in the embodiments of the present application are described in detail above. Specific examples are used herein to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method and core idea of the present application. At the same time, for those skilled in the art, according to the idea of the present application, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as a limitation on the present application.
Claims
1. A method for processing an electronic device, characterized in that: The electronic device includes a touch screen, the touch screen includes a touch module, and the method includes: When the electronic device switches from running a first type of application to running a second type of application, the first filtering algorithm currently used for filtering the touch information collected by the touch module is switched to a second filtering algorithm, wherein the response speed of the second filtering algorithm is faster than the response speed of the first filtering algorithm; Based on the second filtering algorithm, filtering the touch information collected by the touch module; The second type of application responds to the filtered touch information.
2. The method for processing an electronic device according to claim 1, characterized in that: Before switching the first filtering algorithm to the second filtering algorithm, the method further includes: The sampling rate of the touch module is increased from a first sampling rate to a second sampling rate, wherein the second sampling rate is greater than the first sampling rate.
3. The method for processing an electronic device according to claim 2, characterized in that: After increasing the sampling rate of the touch module from the first sampling rate to the second sampling rate, the method further includes: The touch module collects touch information through a plurality of sampling points based on the second sampling rate; The touch track trend is obtained based on the coordinate information of the current sampling point and the coordinate information of the historical sampling points; Before collecting the coordinate information of the next sampling point, predicting a virtual sampling point according to the coordinate information of the current sampling point and the touch track trend; The filtering process of the touch information collected by the touch module based on the second filtering algorithm includes: Based on the second filtering algorithm, filtering is performed on the touch information collected by the touch module through multiple sampling points and the touch information collected by the virtual sampling points.
4. The method for processing an electronic device according to claim 1, characterized in that: After the filtering algorithm is switched from the first filtering algorithm to the second filtering algorithm, the method further includes: Switching a trigger reporting threshold from a first reporting threshold to a second reporting threshold, where the second reporting threshold is less than the first reporting threshold; The filtering process of the touch information collected by the touch module based on the second filtering algorithm includes: When the capacitance value in the touch information collected by the touch module is greater than the second reporting threshold, the touch information is filtered based on the second filtering algorithm.
5. The method for processing an electronic device according to claim 1, characterized in that: The touch module includes a self-capacitive touch layer and a mutual-capacitive touch layer, and the method further includes: When the touch information is identified as single-finger touch information, the self-capacitive touch layer is used to acquire the single-finger touch information.
6. The method for processing an electronic device according to claim 1, characterized in that: The first filtering algorithm is an infinite impulse response filtering algorithm, and the second filtering algorithm is a mean filtering algorithm.
7. The method for processing an electronic device according to claim 1, characterized in that: The method further comprises: When the electronic device switches from running the first type of application or the second type of application to running the third type of application, the third type of application directly responds to the touch information received by the touch module.
8. A processing device for an electronic device, characterized in that: The electronic device includes a touch screen, the touch screen includes a touch module, and the device includes: a switching module, configured to switch a first filtering algorithm currently used for filtering the touch information collected by the touch module to a second filtering algorithm when the electronic device switches from running a first type of application to running a second type of application, wherein a response speed of the second filtering algorithm is faster than a response speed of the first filtering algorithm; A processing module, configured to filter the touch information collected by the touch module based on the second filtering algorithm; The response module, the second type application responds to the touch information after filtering.
9. A storage medium having a computer program stored thereon, characterized in that: When the computer program is executed on a computer, the computer is caused to execute the method according to any one of claims 1 to 7.
10. An electronic device comprising a memory, a processor and a touch screen, characterized in that: The processor is configured to execute the method according to any one of claims 1 to 7 by calling the computer program stored in the memory.
