Frame rate control method and electronic equipment

By acquiring application window occlusion information and overall system load, the rendering frame rate of applications not connected to the Vsync signal was adjusted, resolving the overheating and system instability issues caused by applications not connected to the Vsync signal, and improving the user experience.

CN121996333APending Publication Date: 2026-05-08HUAWEI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
HUAWEI TECH CO LTD
Filing Date
2024-11-06
Publication Date
2026-05-08

AI Technical Summary

Technical Problem

Existing technologies cannot effectively control the rendering frame rate of applications that are not connected to the Vsync signal, leading to problems such as overheating of electronic devices, high power consumption, and system instability.

Method used

By acquiring application window occlusion information and overall system load, the rendering frame rate of applications not connected to the Vsync signal can be adjusted to meet user needs and reduce overall system load.

Benefits of technology

It effectively reduces heat generation, power consumption, and system instability in electronic devices, thus improving the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121996333A_ABST
    Figure CN121996333A_ABST
Patent Text Reader

Abstract

The invention provides a frame rate control method and electronic equipment, relates to the technical field of computers, and can effectively control the drawing frame rate of an application (such as an application without accessing a Vsync signal), reduce the problems of unstable operation of an electronic equipment system and the like, and improve the use experience of a user. According to the method, under the condition that the drawing frame rate of a first application is larger than the screen refresh rate of the electronic equipment and / or the whole machine load of the electronic equipment is larger than a preset load, the electronic equipment obtains window shielding information of the first application, the window shielding information is used for indicating the condition that the window corresponding to the first application is shielded by other display contents on the display screen of the electronic equipment. And then, the electronic equipment reduces the drawing frame rate of the first application according to the window shielding information of the first application and the whole machine load.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to a frame rate control method and electronic device. Background Technology

[0002] To ensure a smooth user experience, applications on electronic devices typically run at the highest possible frame rate. However, this can cause the application's frame rate to exceed the screen refresh rate, leading to problems such as overheating, excessive power consumption, and system instability. Currently, a common solution is to connect the application to the electronic device's vertical synchronization (Vsync) signal. The electronic device controls the transmission of the Vsync signal, and the application only begins graphics rendering after receiving the Vsync signal, thus ensuring that the application's frame rate does not exceed the screen refresh rate.

[0003] However, not all applications access the Vsync signal. For applications that do not access the Vsync signal, the electronic device cannot control its rendering frame rate using the methods described above. The rendering frame rate of these applications will still exceed the screen refresh rate of the electronic device. Some applications may even continuously refresh at a high rendering frame rate, thereby consuming a large amount of the electronic device's system resources and compromising system stability. Summary of the Invention

[0004] This application provides a frame rate control method and an electronic device that can effectively control the rendering frame rate of applications (such as applications that are not connected to the Vsync signal), reduce problems such as instability in electronic device system operation, and improve the user experience.

[0005] To achieve the above objectives, this application adopts the following technical solution:

[0006] Firstly, a frame rate control method is provided, applied to an electronic device. The electronic device includes at least one application, wherein the at least one application includes a first application. In this method, when the rendering frame rate of the first application is greater than the screen refresh rate of the electronic device and / or the overall load of the electronic device is greater than a preset load, the electronic device acquires window occlusion information of the first application, wherein the window occlusion information indicates that the window corresponding to the first application is occluded by other displayed content on the electronic device's display screen. Then, the electronic device reduces the rendering frame rate of the first application based on the window occlusion information and the overall load of the first application.

[0007] In the above method, when the application's current rendering frame rate is too high, or when the overall load on the electronic device is too heavy, the application's rendering frame rate can be reduced based on factors such as whether the application window is obscured by other display content or the overall load on the electronic device. This way, adjusting the rendering frame rate takes into account both the obstruction of the application window by other display content and the overall load on the device. The adjusted rendering frame rate satisfies the user's needs for the application window, and a lower rendering frame rate indicates a lower frequency of GPU usage, thus reducing issues such as device overheating, high power consumption, and system instability.

[0008] For example, for applications where the drawing frame rate exceeds the screen refresh rate, the drawing frame rate can be reduced to no more than the screen refresh rate; and for applications where the drawing frame rate does not exceed the screen refresh rate, the drawing frame rate can be further reduced.

[0009] In addition, the above method can adjust the application's rendering frame rate without being affected by the Vsync signal. For applications that are not connected to the Vsync signal, the application's rendering frame rate can be controlled during the application's GPU call phase.

[0010] In one possible implementation of the first aspect, the overall load of the electronic device includes the SOC occupancy rate of the first application and / or the temperature of the electronic device; the overall load of the electronic device being greater than a preset load includes at least one of the following: the SOC occupancy rate of the first application is greater than the preset occupancy rate, the SOC temperature is greater than a first preset temperature, or the overall temperature of the electronic device is greater than a second preset temperature.

[0011] In the above implementation, the electronic device can determine whether the overall load is too high, or whether the overall load exceeds a preset load, by checking whether multiple conditions are met. For example, when the SOC utilization rate of the first application is higher than the preset utilization rate, the electronic device determines that the overall load is too high; when the SOC temperature is higher than the first preset temperature, the electronic device determines that the overall load is too high; or, when the overall temperature is higher than the second preset temperature, the PC determines that the overall load is too high; or, when any two or all three of the aforementioned conditions are met, the electronic device further determines that the overall load is too high.

[0012] In one possible implementation of the first aspect, when the electronic device reduces the rendering frame rate of the first application based on the window occlusion information of the first application and the overall system load, it further reduces the rendering frame rate of the first application to a target frame rate based on the window occlusion information of the first application and the overall system load.

[0013] In the above implementation, the determination or adjustment of the target frame rate can be combined with the situation where the window is obscured by other displayed content and the overall machine load. Thus, the rendering frame rate after adjustment based on the target frame rate will be reduced, while still meeting the user's needs for the window and improving the user experience.

[0014] In one possible implementation of the first aspect, when the electronic device reduces the rendering frame rate of the first application to a target frame rate based on the window occlusion information of the first application and the overall system load, it first obtains the load level of the electronic device's overall system load, wherein different load levels correspond to different load ranges, and overall system loads within the same load range belong to the same load level. Then, the electronic device determines the target frame rate of the first application based on the load level and the window occlusion information of the first application. Finally, the electronic device reduces the rendering frame rate of the first application to the target frame rate.

[0015] In the above implementation, the electronic device can determine the target frame rate based on different levels of load and the window occlusion information of the first application, making the target frame rate more accurate. As a result, the rendering frame rate adjusted based on the target frame rate will be reduced, while meeting the user's needs for the window and improving the user experience.

[0016] In one possible implementation of the first aspect, the load level includes a first load level, which indicates at least one of the following: the SOC utilization of the first application is greater than 90%, the SOC temperature is greater than 90°C, the overall temperature of the electronic device is greater than 37°C, the first application includes at least one window, and the at least one window includes a first window. When the electronic device determines the target frame rate of the first application based on the load level and the window occlusion information of the first application, for the first load level, the electronic device determines that the first window corresponding to the first application is not occluded based on the window occlusion information, and determines that the target frame rate is equal to the screen refresh rate of the electronic device.

[0017] In one possible implementation of the first aspect, for a first load level, the electronic device determines that the first window corresponding to the first application is 1 / 3 occluded based on window occlusion information, and determines that the target frame rate is 1 / 2 of the screen refresh rate of the electronic device.

[0018] In one possible implementation of the first aspect, for a first load level, the electronic device determines that the first window corresponding to the first application is 2 / 3 occluded based on window occlusion information, and determines that the target frame rate is 1 / 4 of the screen refresh rate of the electronic device.

[0019] In one possible implementation of the first aspect, for a first load level, the electronic device determines that the first window corresponding to the first application is completely obscured based on window occlusion information, and determines the target frame rate to be 0.

[0020] In the above implementation methods, under a certain load level, the electronic device determines different target frame rates based on the degree of occlusion by the first application. For windows with a high degree of occlusion, the user's viewing needs for that window may be lower, so the target frame rate can be lower. Conversely, for windows with a low degree of occlusion, the user's viewing needs for that window may be higher, so the target frame rate can be higher. Therefore, the target frame rate determined in this way takes into account both the load of the electronic device and the possibility of the first application's window being obscured by other displayed content, making the target frame rate more accurate.

[0021] In one possible implementation of the first aspect, the load level includes a second load level, which indicates at least one of the following: the SOC utilization of the first application is greater than 70% and less than or equal to 90%, the SOC temperature is greater than 80°C and less than or equal to 90°C, the overall temperature of the electronic device is greater than 30°C and less than or equal to 37°C, the first application includes at least one window, and the at least one window includes a first window. When the electronic device determines the target frame rate of the first application based on the load level and the window occlusion information of the first application, for the second load level, the electronic device determines that the first window corresponding to the first application is not occluded based on the window occlusion information, and determines that the target frame rate is equal to the screen refresh rate of the electronic device.

[0022] In one possible implementation of the first aspect, for the second load level, the electronic device determines that the first window corresponding to the first application is 1 / 3 occluded based on window occlusion information, and determines that the target frame rate is 1 / 2 of the screen refresh rate of the electronic device.

[0023] In one possible implementation of the first aspect, for the second load level, the electronic device determines that the first window corresponding to the first application is 2 / 3 occluded based on window occlusion information, and determines that the target frame rate is 1 / 3 of the screen refresh rate of the electronic device.

[0024] In one possible implementation of the first aspect, for the second load level, the electronic device determines that the first window corresponding to the first application is completely obscured based on window occlusion information, and determines the target frame rate to be 0.

[0025] In the above implementation methods, under a certain load level, the electronic device determines different target frame rates based on the degree of occlusion by the first application. For windows with a high degree of occlusion, the user's viewing needs for that window may be lower, so the target frame rate can be lower. Conversely, for windows with a low degree of occlusion, the user's viewing needs for that window may be higher, so the target frame rate can be higher. Therefore, the target frame rate determined in this way takes into account both the load of the electronic device and the possibility of the first application's window being obscured by other displayed content, making the target frame rate more accurate.

[0026] In one possible implementation of the first aspect, the method further includes, in the event that the rendering frame rate of the first application is greater than the screen refresh rate of the electronic device and / or the overall load of the electronic device is greater than a preset load, the electronic device reduces the rendering frame rate of the first application to 0 in response to the first application not running or being detected and killed.

[0027] In the above implementation, even if the application is detected or not running, the electronic device can control its rendering frame rate to prevent the application from still occupying the SOC, which would lead to excessive SOC usage and affect the performance and stability of the electronic device.

[0028] In one possible implementation of the first aspect, the electronic device includes a loader encapsulation layer for a first application to invoke the graphics processing unit (GPU). The method further includes: the electronic device acquiring the number of times the first application invokes the loader encapsulation layer to determine the rendering frame rate of the first application.

[0029] In the above implementation, the first application can call the GPU through the loader encapsulation layer. The number of times the first application calls the loader encapsulation layer will result in the number of times the GPU will be called. Therefore, the electronic device will obtain a more accurate number of times the first application calls the loader encapsulation layer at the loader encapsulation layer, and thus obtain a more accurate rendering frame rate.

[0030] In one possible implementation of the first aspect, when the electronic device reduces the rendering frame rate of the first application to a target frame rate, the frequency at which the first application calls the GPU is adjusted in the loader encapsulation layer according to the target frame rate to reduce the rendering frame rate of the first application.

[0031] In the above implementation, for applications that do not access the Vsync signal, since such applications can directly call the GPU in the loader encapsulation layer, the electronic device in this application can also directly control the frequency of calling the GPU in the loader encapsulation layer, so as to achieve the purpose of adjustable and controllable application rendering frame rate, and also reduce the situation where the application rendering frame rate exceeds the screen refresh rate.

[0032] In one possible implementation of the first aspect, the SOC includes a central processing unit (CPU) and a GPU, and the SOC utilization includes CPU utilization and GPU utilization.

[0033] In a second aspect, a frame rate control device is provided, including a display screen, the device further comprising:

[0034] The information collection module is used to acquire window occlusion information of the first application when the rendering frame rate of the first application is greater than the screen refresh rate of the display screen and / or the overall load of the frame rate control device is greater than a preset load; the window occlusion information is used to indicate the situation where the window corresponding to the first application is occluded by other display content on the display screen.

[0035] The frame rate control module is used to reduce the rendering frame rate of the first application based on the window occlusion information of the first application and the overall system load.

[0036] Thirdly, an electronic device is provided, including a memory and one or more processors; the memory is coupled to the processors; wherein the memory stores computer program code, the computer program code including computer instructions, which, when executed by the processor, cause the electronic device to perform the frame rate control method as described in the first aspect and any of its implementable embodiments.

[0037] Fourthly, a computer-readable storage medium is provided, including computer instructions that, when executed on an electronic device, cause the electronic device to perform the frame rate control method as described in the first aspect and any of its implementable embodiments.

[0038] Fifthly, a computer program product is provided that, when run on a computer, causes the computer to perform the frame rate control method as described in the first aspect and any of its implementable embodiments.

[0039] The beneficial effects that the frame rate control device provided in the second aspect, the electronic device provided in the third aspect, the computer-readable storage medium provided in the fourth aspect, and the computer program product provided in the fifth aspect can achieve are similar to the beneficial effects that can be achieved in the first aspect and any of its implementations, and will not be repeated here. Attached Figure Description

[0040] Figure 1 A schematic diagram illustrating the control of application rendering frame rate via Vsync signal according to an embodiment of this application;

[0041] Figure 2 Schematic diagram of the structure of the electronic device provided in the embodiments of this application Figure 1 ;

[0042] Figure 3 A schematic diagram of a window displayed on an electronic device provided in an embodiment of this application;

[0043] Figure 4 Schematic diagram of the structure of the electronic device provided in the embodiments of this application Figure 2 ;

[0044] Figure 5 Schematic diagram of the structure of the electronic device provided in the embodiments of this application Figure 3 ;

[0045] Figure 6 Flowchart of the frame rate control method provided in the embodiments of this application Figure 1 ;

[0046] Figure 7 A schematic diagram illustrating the relationship between window occlusion at the first load level and the target frame rate, provided for an embodiment of this application.

[0047] Figure 8 A schematic diagram illustrating the relationship between window occlusion at the second load level and the target frame rate, provided as an embodiment of this application.

[0048] Figure 9 Flowchart of the frame rate control method provided in the embodiments of this application Figure 2 ;

[0049] Figure 10 Flowchart of the frame rate control method provided in the embodiments of this application Figure 3 ;

[0050] Figure 11 A schematic diagram of a frame rate control device provided in an embodiment of this application;

[0051] Figure 12 Schematic diagram of the structure of the electronic device provided in the embodiments of this application Figure 4 . Detailed Implementation

[0052] The technical solutions of the embodiments of this application will be described below with reference to the accompanying drawings. In the description of this application, unless otherwise stated, " / " indicates that the objects before and after are in an "or" relationship. For example, A / B can represent A or B. "And / or" in this application is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A alone, A and B simultaneously, and B alone, where A and B can be singular or plural. Furthermore, in the description of this application, unless otherwise stated, "multiple" refers to two or more. "At least one of the following" or similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one of a, b, or c can represent: a, b, c, ab, ac, bc, or abc, where a, b, and c can be single or multiple. Furthermore, to facilitate a clear description of the technical solutions in the embodiments of this application, the terms "first" and "second" are used in the embodiments of this application to distinguish identical or similar items with substantially the same function and effect. Those skilled in the art will understand that the terms "first" and "second" do not limit the quantity or execution order, and that "first" and "second" are not necessarily different. Meanwhile, in the embodiments of this application, the terms "exemplary" or "for example" are used to indicate that something is being used as an example, illustration, or description. Any embodiment or design scheme described as "exemplary" or "for example" in the embodiments of this application should not be construed as being more preferred or advantageous than other embodiments or design schemes. Specifically, the use of terms such as "exemplary" or "for example" is intended to present related concepts in a concrete manner for ease of understanding.

[0053] Furthermore, the business scenarios described in the embodiments of this application are for the purpose of more clearly illustrating the technical solutions of the embodiments of this application, and do not constitute a limitation on the technical solutions provided in the embodiments of this application. As those skilled in the art will know, with the emergence of new business scenarios, the technical solutions provided in the embodiments of this application are also applicable to similar technical problems.

[0054] Users increasingly demand a smooth user experience when using applications on electronic devices. To ensure this, applications typically render images at the highest possible frame rate. However, this can cause the application's frame rate to exceed the screen refresh rate. If the frame rate exceeds the screen refresh rate, it leads to excessive utilization of the device's central processing unit (CPU) and graphics processing unit (GPU), resulting in overheating, high power consumption, and system instability. Furthermore, when the application's frame rate is higher than the screen refresh rate, image rendering becomes ineffective, wasting overall system performance and power.

[0055] Currently, some technical solutions address this issue by having the application connect to the electronic device's Vsync signal. The electronic device controls the distribution of the Vsync signal, and the application begins image rendering after receiving the Vsync signal, thus ensuring that the application's rendering frame rate does not exceed the screen refresh rate.

[0056] For example, electronic devices use the Vsync signal to control the rendering pipeline to keep pace with the screen refresh rate. The rendering pipeline, also known as the rendering pipeline or pixel pipeline, includes parallel processing units that handle graphics signals independently, such as the CPU, GPU, and display module. See also Figure 1 As shown, when the Vsync signal arrives, the CPU begins processing the graphics signal of task B and sends the processed image to the GPU for rendering. The GPU then sends the rendered image to the display module, which displays the image when the Vsync signal arrives. After processing the graphics signal of task B, when the next Vsync signal arrives, the CPU begins processing the graphics signal of task C and sends the processed image to the GPU for rendering. The GPU then sends the rendered image to the display module, which displays the image when the Vsync signal arrives.

[0057] However, not all applications access the Vsync signal. For applications that do not access the Vsync signal, the application calls the loader wrapper layer, thereby calling the GPU to draw the image. In this case, the electronic device cannot control its drawing frame rate through the above method. The drawing frame rate of these applications will still exceed the screen refresh rate of the electronic device. Some applications will even refresh continuously with a high drawing frame rate, thereby consuming a large amount of the electronic device's system resources and causing the system's stability to be compromised.

[0058] Based on the above, this application provides a frame rate control method. When the application's current rendering frame rate is too high, or when the overall load on the electronic device is too heavy, the application's rendering frame rate can be reduced based on factors such as whether the application window displayed on the electronic device is obscured by other displayed content or the overall load on the electronic device. This reduces problems such as severe overheating, high power consumption, and system instability caused by excessively high rendering frame rates.

[0059] For example, in the above method, the electronic device may include at least one application, wherein the at least one application includes a first application. When the rendering frame rate of the first application is greater than the screen refresh rate of the electronic device and / or the overall load of the electronic device is greater than a preset load, the electronic device obtains window occlusion information of the first application, wherein the window occlusion information indicates that the window corresponding to the first application is occluded by other displayed content on the electronic device's display screen. Then, the electronic device reduces the rendering frame rate of the first application based on the window occlusion information and the overall load of the first application.

[0060] In the above method, the adjustment of the rendering frame rate takes into account both the situation where the application window is obscured by other display content and the overall system load. This ensures that the adjusted rendering frame rate can meet the user's needs for the application window. The lower the application's rendering frame rate, the lower the frequency of the application calling the GPU. This can reduce problems such as device overheating, high power consumption, and system instability.

[0061] For example, for applications where the rendering frame rate exceeds the screen refresh rate, the rendering frame rate can be reduced to no more than the screen refresh rate; and for applications where the rendering frame rate does not exceed the screen refresh rate, the rendering frame rate can be further reduced.

[0062] In addition, the above method can adjust the application's rendering frame rate without being affected by the Vsync signal. For applications that are not connected to the Vsync signal, the application's rendering frame rate can be controlled during the application's GPU call phase.

[0063] The frame rate control method described above can be applied to electronic devices.

[0064] In some embodiments, see Figure 2As shown, the electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, antenna 1, antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a sensor module 180, buttons 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc. The sensor module 180 may include a temperature sensor 180J, etc.

[0065] It is understood that the structures illustrated in the embodiments of this application do not constitute a specific limitation on the electronic device 100. In other embodiments of this application, the electronic device 100 may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements.

[0066] Processor 110 may include one or more processing units, such as a CPU, application processor (AP), modem processor, GPU, image signal processor (ISP), controller, memory, video codec, digital signal processor (DSP), baseband processor, and / or neural network processing unit (NPU). Different processing units may be independent devices or integrated into one or more processors.

[0067] In some possible application scenarios, the electronic device 100 can implement the frame rate control method provided in the embodiments of this application through the processor 110 described above.

[0068] In some possible application scenarios, if a user wants to open an application on electronic device 100, they can click the application icon, and electronic device 100 will then display the application page; alternatively, if the user performs an operation within the application, triggering a page redirection, electronic device 100 will also display the redirected application page. Before displaying the application page, electronic device 100 needs to perform image rendering on the application page.

[0069] The image rendering process involves both CPU and GPU rendering stages; that is, the CPU and GPU work together to generate the final displayed image or application page. The CPU is responsible for scene management, logic processing, and generating rendering instructions, while the GPU is responsible for the actual image rendering and parallel computation based on the rendering instructions.

[0070] Specifically, the GPU receives an image instruction stream from the CPU for an image frame to be rendered, and performs image rendering operations on the image frame according to the image instruction stream to obtain display data for the image frame to be rendered. The GPU then sends the display data to the display screen 194, which displays an image or application page based on the display data. The image instruction stream typically includes multiple drawing instructions. These drawing instructions are used to generate a rendering target to obtain the display data for the image frame to be rendered.

[0071] The application's rendering frame rate typically refers to the number of image frames per second that the CPU or GPU can process and render for the application's page. Alternatively, the application can determine the rendering frame rate by detecting the number of times it calls the loader wrapper layer, thereby obtaining the number of times the application calls the GPU.

[0072] In some possible application scenarios, the CPU and GPU in electronic device 100 can be integrated on a SOC.

[0073] In some possible application scenarios, the processor 110 can adjust the application's rendering frame rate when the application's rendering frame rate is greater than the screen refresh rate of the electronic device 100, or when the electronic device 100 is under excessive load, so that the actual rendering frame rate of the application is reduced, or the actual rendering frame rate of the application is less than or equal to the screen refresh rate, thereby reducing problems such as severe overheating, high power consumption, and unstable system operation of the electronic device 100 caused by the application's excessively high rendering frame rate.

[0074] It is understood that the load of the aforementioned electronic device 100 may include the SOC utilization rate applied in the electronic device 100 and / or the temperature of the electronic device 100. Furthermore, the SOC utilization rate includes CPU utilization rate and GPU utilization rate, and the temperature of the electronic device 100 includes the overall temperature of the electronic device 100 and / or the SOC temperature.

[0075] USB port 130 is a USB standard compliant interface, specifically a Mini USB port, Micro USB port, USB Type-C port, etc. USB port 130 can be used to connect a charger to charge electronic device 100, and can also be used for data transfer between electronic device 100 and peripheral devices. It can also be used to connect headphones for audio playback. This interface can also be used to connect other electronic devices, such as AR devices.

[0076] The charging management module 140 receives charging input from a charger. The charger can be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 receives charging input from the wired charger via the USB interface 130. In some wireless charging embodiments, the charging management module 140 receives wireless charging input via the wireless charging coil of the electronic device 100. While charging the battery 142, the charging management module 140 can also supply power to the electronic device via the power management module 141.

[0077] The power management module 141 connects the battery 142, the charging management module 140, and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140, providing power to the processor 110, internal memory 121, external memory, display screen 194, camera 193, and wireless communication module 160, etc. The power management module 141 can also monitor parameters such as battery capacity, battery cycle count, and battery health status (leakage current, impedance). In some other embodiments, the power management module 141 may also be located within the processor 110. In other embodiments, the power management module 141 and the charging management module 140 may be located in the same device.

[0078] The wireless communication function of electronic device 100 can be realized through antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modem processor and baseband processor, etc.

[0079] Electronic device 100 implements display functions through a GPU, a display screen 194, and an application processor. The GPU is a microprocessor for image processing, connected to the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations and for graphics rendering. Processor 110 may include one or more GPUs, which execute program instructions to generate or modify display information.

[0080] The display screen 194 is used to display images, videos, etc. In some embodiments, the electronic device 100 may include one or N display screens 194, where N is a positive integer greater than 1.

[0081] In some potential application scenarios, the application pages on display screen 194 can be displayed in the form of windows, where one application can correspond to one window, and the window can display the application page, application images, etc. For example, see... Figure 3As shown, one or more application windows can be displayed on the screen 194. Multiple application windows may obscure each other, resulting in varying degrees of obstruction by other displayed content, or different visual visibility of the windows. Visual visibility refers to the degree to which a window is visible to the user. Figure 3 As shown, window 1 is not obscured, window 2 is partially obscured by window 1, and window 3 is obscured by more of window 2 than window 2 is obscured by window 1. Therefore, the degree of obscuration of window 1 is higher than that of window 2, and the degree of obscuration of window 2 is higher than that of window 3.

[0082] In other possible application scenarios, the degree or situation of window occlusion can also be represented by the window's Z-order, window priority, or window hierarchy. For example, a higher window Z-order indicates a lower degree of occlusion, and a lower window Z-order indicates a higher degree of occlusion; a higher window priority indicates a lower degree of occlusion, and a lower window priority indicates a higher degree of occlusion; a higher window hierarchy indicates a lower degree of occlusion, and a lower window hierarchy indicates a higher degree of occlusion.

[0083] It is understandable that the window's occlusion by other displayed content, visual visibility, window Z-order, window priority, and window hierarchy can all serve as window occlusion information for the application.

[0084] In some potential application scenarios, when adjusting the application's rendering frame rate, the processor 110 can determine the target frame rate by combining the application's window occlusion information and the overall load of the electronic device 100. Specifically, the target frame rate varies depending on the extent to which the application window is occluded by other displayed content within a certain load range. For example, for an overall load within the first load range, if the application window is completely obscured, it indicates that the user's viewing need for that window is low, or that they no longer need to view it. In this case, the application's rendering frame rate might be 0, meaning the corresponding page or image will not be rendered. If the application window is partially obscured, it indicates that the user still has some viewing need for that window. In this case, the application's rendering frame rate might be equal to or lower than the screen refresh rate. Regardless of the approach, the rendering frame rate of the application can be reduced as much as possible, minimizing issues such as heat generation, high power consumption, and system instability in the electronic device 100.

[0085] Electronic device 100 can perform shooting functions through ISP, camera 193, video codec, GPU, display 194 and application processor.

[0086] The ISP is used to process the data fed back by the camera 193. In some embodiments, the ISP may be located in the camera 193.

[0087] Camera 193 is used to capture still images or videos. In some embodiments, electronic device 100 may include one or N cameras 193, where N is a positive integer greater than 1.

[0088] Digital signal processors (DSPs) are used to process digital signals. Besides digital image signals, they can also process other digital signals. For example, when electronic device 100 selects a frequency, the DSP can perform Fourier transforms on the frequency energy.

[0089] The external storage interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100. The external memory card communicates with the processor 110 through the external storage interface 120 to perform data storage functions. For example, music, video, and other files can be saved on the external memory card.

[0090] Internal memory 121 can be used to store computer executable program code, which includes instructions. Processor 110 executes various functional applications and data processing of electronic device 100 by running the instructions stored in internal memory 121. Internal memory 121 may include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function (such as sound playback, image playback, etc.), etc. The data storage area may store data created during the use of electronic device 100 (such as audio data), etc. Furthermore, internal memory 121 may include high-speed random access memory, and may also include non-volatile memory, such as at least one disk storage device, flash memory device, universal flash storage (UFS), etc.

[0091] Electronic device 100 can implement audio functions, such as music playback and recording, through audio module 170 and application processor.

[0092] The audio module 170 is used to convert digital audio information into analog audio signals for output, and also to convert analog audio input into digital audio signals. The audio module 170 can also be used for encoding and decoding audio signals. In some embodiments, the audio module 170 may be located in the processor 110, or some functional modules of the audio module 170 may be located in the processor 110.

[0093] Temperature sensor 180J is used to detect temperature. In some embodiments, electronic device 100 uses the temperature detected by temperature sensor 180J to execute a temperature handling strategy. For example, when the temperature reported by temperature sensor 180J exceeds a threshold, electronic device 100 performs thermal protection by reducing the performance of a processor located near temperature sensor 180J to reduce power consumption. In other embodiments, when the temperature is below another threshold, electronic device 100 heats battery 142 to prevent abnormal shutdown of electronic device 100 due to low temperature. In still other embodiments, when the temperature is below yet another threshold, electronic device 100 boosts the output voltage of battery 142 to prevent abnormal shutdown due to low temperature.

[0094] In some possible applications, the temperature sensor 180J can also detect the temperature of the SOC in the electronic device 100, as well as the overall temperature of the electronic device 100.

[0095] Buttons 190 include a power button, volume buttons, etc. Motor 191 can generate vibration alerts. Motor 191 can be used for incoming call vibration alerts or for touch vibration feedback. Indicator 192 can be an indicator light, used to indicate charging status, battery level changes, or to indicate messages, missed calls, notifications, etc. SIM card interface 195 is used to connect a SIM card.

[0096] In some embodiments, the software system of electronic device 100 may adopt a layered architecture, event-driven architecture, microkernel architecture, microservice architecture, or cloud architecture. This application embodiment uses a layered mobile operating system as an example to exemplify the software structure of electronic device 100.

[0097] For example, see Figure 4 As shown, the layered architecture divides the software into several layers, each with a clear role and function. Layers communicate with each other through software interfaces. In some embodiments, the mobile operating system is divided into four layers, from top to bottom: the application layer, the framework layer, and the kernel layer.

[0098] The application layer can include a series of application packages.

[0099] like Figure 4 As shown, an application package may include applications (hereinafter referred to as applications). Applications may include, for example, camera, gallery, calendar, WLAN, Bluetooth, music, video, etc. Applications may be third-party applications or non-third-party applications (such as system applications). The rendering frame rate of these applications may exceed the screen refresh rate in some cases.

[0100] The electronic device 100 can render the application page or image of the aforementioned application and display the rendered application page or image on the display screen in the form of a window.

[0101] The framework layer provides application programming interfaces (APIs) and programming frameworks for applications in the application layer. The framework layer includes some predefined functions.

[0102] like Figure 4 As shown, the framework layer may include window modules, media modules, user interface (UI) engine, frame rate decision module, Loader encapsulation layer, etc.

[0103] The window module is used to manage window applications. It can obtain information such as screen size, status bar presence, screen locking, and screen capture. It can also obtain window occlusion information such as whether the application window is obscured by other displayed content, visual visibility, Z-order, priority, and hierarchy.

[0104] The media module provides the application with various resources, such as localized strings, icons, images, layout files, video files, and so on.

[0105] The UI engine is used to display window programs.

[0106] The electronic device 100 collects information from the aforementioned modules, obtains information such as application window occlusion and application running status, and sends the application window occlusion information and application running status to the frame rate decision module.

[0107] The frame rate decision module primarily determines the target frame rate for the application based on the information mentioned above. For example, for applications without a vertical synchronization signal, this module will allocate a reasonable rendering frame rate.

[0108] The Loader wrapper layer includes the GLES Wrapper module, the Vulkan Loader module, and the frame rate control module.

[0109] The GLES Wrapper module is a library or framework that encapsulates the underlying application programming interface (API) of OpenGL ES. It provides a higher-level interface, making it easier for developers to use OpenGL ES for image rendering.

[0110] The Vulkan Loader module is the Vulkan loader. Vulkan is an API that allows applications to directly access graphics hardware, resulting in higher performance, efficiency, and lower latency.

[0111] The frame rate control module is used to adjust the frequency of application layer submissions to the display in the Loader encapsulation layer, or adjust the frequency of application calling the GPU, based on the target frame rate allocated by the frame rate decision module. This limits the number of frames submitted by the application layer to the GPU for rendering and synthesis within a certain period of time, i.e., the rendering frame rate of the display application.

[0112] The kernel layer is the layer between hardware and software. The kernel layer includes the device driver development kit (DDK) for the GPU. The GPU can use the DDK to perform image rendering. Additionally, the kernel layer may also include display drivers, camera drivers, audio drivers, etc. The application page or image rendered by the GPU is then sent to the display screen of the electronic device 100 for display.

[0113] See also: [In some possible application scenarios] Figure 5 As shown, the frame rate decision module includes an information collection module, an inference decision module, and a communication module.

[0114] The information collection module can acquire information such as the screen refresh rate of the electronic device 100, application window occlusion information, application SOC utilization rate, SOC temperature, and the overall temperature of the electronic device 100.

[0115] The reasoning and decision-making module can determine, based on the information obtained by the information collection module, applications whose rendering frame rate is higher than the screen refresh rate, or applications whose rendering frame rate needs to be adjusted, and determine the target frame rate of the application.

[0116] The communication module can send the application's target frame rate to the frame rate control module. Specifically, the communication module primarily relies on the capabilities of the graphics queue, passing the inferred target frame rate to the frame rate control module integrated into the Loader wrapper layer via the graphics buffer queue.

[0117] It is understood that, based on the aforementioned electronic device, the frame rate control method in this application embodiment can reduce the application's frame rate for applications with excessively high rendering frame rates, or make the application's frame rate less than or equal to the screen refresh rate of the electronic device. This can reduce problems such as severe overheating, high power consumption, and system instability caused by excessively high rendering frame rates.

[0118] Whether the rendering frame rate is too high can be detected directly in the Loader encapsulation layer by comparing the application's rendering frame rate with the screen refresh rate, or it can be reflected by the application's SOC utilization rate, or it can be reflected by the temperature of the electronic device.

[0119] In addition, the above method can adjust the application's rendering frame rate without being affected by the Vsync signal. For applications that are not connected to the Vsync signal, the application's rendering frame rate can be controlled during the application's GPU call phase.

[0120] It is understood that the electronic devices in the embodiments of this application may be mobile phones, tablets, smartwatches, vehicle terminals, handheld computers, laptops, personal computers (PCs), ultra-mobile personal computers (UMPCs), netbooks, as well as cellular phones, personal digital assistants (PDAs), augmented reality (AR) / virtual reality (VR) devices, smart home devices (such as smart TVs, smart screen devices, and smart central control devices), etc. The embodiments of this application do not impose special restrictions on the specific form of the electronic device.

[0121] The following explanation uses a PC as an example to illustrate the frame rate control method.

[0122] In some embodiments, see Figure 6 As shown, the frame rate control method may include the following steps S601-S602.

[0123] S601, when the rendering frame rate of the first application is greater than the screen refresh rate of the PC and / or the overall load of the PC is greater than a preset load, the PC obtains the window occlusion information of the first application.

[0124] The PC may include at least one application, which may include applications that are connected to the Vsync signal or applications that are not connected to the Vsync signal. The first application can be any one of these applications. When the first application is running, it may correspond to a window on the PC screen. At the same time, the PC screen may also display windows corresponding to other applications. When there are too many windows displayed, it is inevitable that windows will obscure each other. Therefore, the first application may also include window obstruction information to indicate whether a window is obscured by other displayed content on the PC screen.

[0125] For example, situations where a window is obscured by other displayed content on a PC screen can include being completely obscured, partially obscured, or not obscured at all.

[0126] Understandably, a PC can determine that the first application's rendering frame rate is too high by directly determining that the first application's rendering frame rate is greater than the screen refresh rate; a PC can also determine that the first application's rendering frame rate is too high by determining that the overall system load is greater than a preset load; or, a PC can determine that the first application's rendering frame rate is too high if both the first application's rendering frame rate are greater than the screen refresh rate and the overall system load is greater than a preset load.

[0127] In some examples, the overall load of the PC mentioned above includes the SOC utilization of the first application and / or the temperature of the PC. Wherein, the overall load of the PC exceeding the preset load includes at least one of the following: the SOC utilization of the first application is greater than the preset utilization, the SOC temperature is greater than a first preset temperature, or the overall temperature of the PC is greater than a second preset temperature.

[0128] In other words, a PC can determine whether the overall system load is too high, or whether the overall system load exceeds a preset load, by checking whether multiple conditions are met. For example, when the SOC utilization rate of the first application is higher than the preset utilization rate, the PC determines that the overall system load is too high; when the SOC temperature is higher than the first preset temperature, the PC determines that the overall system load is too high; or when the overall system temperature is higher than the second preset temperature, the PC determines that the overall system load is too high; or, when any two or all three of the aforementioned conditions are met, the PC then determines that the overall system load is too high.

[0129] When the rendering frame rate of the first application is greater than the PC's screen refresh rate and / or the PC's overall load is greater than the preset load, it means that the rendering frame rate of the first application is too high. In this case, the PC needs to obtain the window occlusion information of the first application and then adjust the rendering frame rate of the first application accordingly.

[0130] A PC can determine whether the rendering frame rate of the primary application is too high from multiple angles and aspects, resulting in a more accurate assessment.

[0131] In some possible application scenarios, the above SOC utilization rate can include CPU utilization rate and GPU utilization rate, thereby reflecting the rendering frame rate of the first application.

[0132] In some potential application scenarios, the primary application can access the GPU through a loader layer. The number of times the primary application calls the loader layer corresponds to the number of GPU calls. Since the primary application uses the GPU for rendering, the PC can obtain the number of times the primary application calls the loader layer, thereby determining the number of GPU calls and the rendering frame rate of the primary application. Data obtained from the loader layer is more accurate.

[0133] S602, PC reduces the rendering frame rate of the first application based on the window occlusion information of the first application and the overall load of the machine, so that the reduced rendering frame rate does not exceed the screen refresh rate of the PC.

[0134] In some potential application scenarios, the PC can determine the target frame rate of the first application based on window occlusion information and overall system load, and then reduce the rendering frame rate of the first application to the target frame rate. In this way, the determination of the target frame rate can take into account whether the window is obscured by other displayed content and the overall system load, thus ensuring that the adjusted rendering frame rate, while not exceeding the screen refresh rate, meets the user's window requirements and improves the user experience.

[0135] In some examples, the PC can obtain the load level of the PC's overall load based on the overall load. Different load levels correspond to different load ranges, and the overall loads within the same load range belong to the same load level.

[0136] For example, when the overall system load includes the SOC utilization of the first application, the first load range is (90%, +∞); when the overall system load includes the SOC temperature, the first load range is (90°, +∞); when the overall system load includes the overall system temperature, the first load range is (37°, +∞); when the overall system load includes both the SOC utilization and SOC temperature of the first application, the first load range is (90%, +∞) and (90°, +∞); when the overall system load includes the SOC utilization, SOC temperature, and overall system temperature of the first application, the first load range is (90%, +∞), (90°, +∞), and (37°, +∞). The first load range corresponds to the first load level.

[0137] Understandably, the first load level indicates at least one of the following: the SOC utilization of the first application is greater than 90%, the SOC temperature is greater than 90°, and the overall PC temperature is greater than 37°.

[0138] For example, when the overall system load includes the SOC utilization of the first application, the second load range is (70%, 90%); when the overall system load includes the SOC temperature, the second load range is (80°, 90°); when the overall system load includes the overall system temperature, the second load range is (30°, 37°); when the overall system load includes both the SOC utilization and SOC temperature of the first application, the second load range is (70%, 90%) and (80°, 90°); when the overall system load includes the SOC utilization, SOC temperature, and overall system temperature of the first application, the second load range is (70%, 90%), (80°, 90°), and (30°, 37°). The second load range corresponds to the second load level.

[0139] Understandably, the second load level indicates at least one of the following: the SOC utilization of the first application is greater than 70% and less than or equal to 90%, the SOC temperature is greater than 80° and less than or equal to 90°, and the overall PC temperature is greater than 30° and less than or equal to 37°.

[0140] After determining the load level, the PC obtains the target frame rate of the first application based on the load level and the window occlusion information of the first application.

[0141] In this way, the PC can determine the target frame rate based on different levels of load and the window occlusion information of the first application, making the target frame rate more accurate. As a result, the rendering frame rate adjusted based on the target frame rate will be lower or will not exceed the screen refresh rate, while meeting the user's needs for windows and improving the user experience.

[0142] In some potential application scenarios, the PC can determine the target frame rate by combining the application's window occlusion information, taking into account different overall system load, load level, load range, etc. Furthermore, the target frame rate can be determined based on the screen refresh rate; for example, the target frame rate is equal to the screen refresh rate, or it is 1 / 2, 1 / 3, 1 / 4, or 1 / 5 of the screen refresh rate.

[0143] In some potential application scenarios, a PC can display multiple windows corresponding to a primary application. The occlusion information of these windows can then indicate how much each window is obscured by other displayed content. For each window, the application can utilize the GPU for rendering; understandably, the application has a corresponding rendering frame rate for each window. Since the degree of occlusion by other displayed content may differ for each window, the PC can also adjust the rendering frame rate for different windows.

[0144] The following example illustrates how to adjust the frame rate of the first window within at least one window corresponding to the first application on a PC.

[0145] For example, see Figure 7 As shown, for the first load level, if the PC determines that the first window corresponding to the first application is not obscured based on the window occlusion information, the PC can determine that the target frame rate is equal to the screen refresh rate. If the PC determines that the first window corresponding to the first application is obscured by 1 / 3 based on the window occlusion information, the PC can determine that the target frame rate is 1 / 2 of the screen refresh rate. If the PC determines that the first window corresponding to the first application is obscured by 2 / 3 based on the window occlusion information, the PC can determine that the target frame rate is 1 / 4 of the screen refresh rate. If the PC determines that the first window corresponding to the first application is completely obscured based on the window occlusion information, the PC can determine that the target frame rate is 0.

[0146] In this way, under a certain load level, the PC determines different target frame rates based on the degree of obstruction by the primary application. For windows with significant obstruction, the user's viewing needs for those windows may be lower, so the target frame rate can be lower. Conversely, for windows with minimal obstruction, the user's viewing needs for those windows may be higher, so the target frame rate can be higher. Therefore, this method of determining the target frame rate takes into account both the PC's load and the possibility of the primary application's window being obstructed by other displayed content, resulting in a more accurate target frame rate.

[0147] For another example, see Figure 8 As shown, for the second load level, if the PC determines that the first window corresponding to the first application is not obscured based on the window occlusion information, the PC can determine that the target frame rate is equal to the screen refresh rate. If the PC determines that the first window corresponding to the first application is obscured by 1 / 3 based on the window occlusion information, the PC can determine that the target frame rate is 1 / 2 of the screen refresh rate. If the PC determines that the first window corresponding to the first application is obscured by 2 / 3 based on the window occlusion information, the PC can determine that the target frame rate is 1 / 3 of the screen refresh rate. If the PC determines that the first window corresponding to the first application is completely obscured based on the window occlusion information, the PC can determine that the target frame rate is 0.

[0148] In this way, under a certain load level, the PC determines different target frame rates based on the degree of occlusion of the first application. For windows with a high degree of occlusion, the user's viewing needs for that window may be lower, so the target frame rate can be lower. Conversely, for windows with a low degree of occlusion, the user's viewing needs for that window may be higher, so the target frame rate can be higher. Therefore, this method of determining the target frame rate takes into account both the PC's load and the occlusion of the first application's window, making the target frame rate more accurate.

[0149] In other examples, if the first window is occluded but not occluded (or the occluded portion is 0), then the target frame rate determined by the PC is equal to the screen refresh rate; if the occluded portion of the first window is greater than 0 and less than 1 / 3, then the target frame rate determined by the PC is 1 / 2 of the screen refresh rate; if the occluded portion of the first window is greater than 1 / 3 and less than 2 / 3, then the target frame rate determined by the PC is 1 / 4 or 1 / 3 of the screen refresh rate; if the occluded portion of the first window is greater than 2 / 3, then the target frame rate determined by the PC is 0.

[0150] It is understood that the above determination of the target frame rate is only an example. In other embodiments, the load level can be divided more finely, or the window occlusion situation can be divided more finely, or the screen refresh rate can be divided more finely, so as to obtain a more accurate or more refined target frame rate.

[0151] In some potential application scenarios, since the first application calls the GPU at the loader wrapper layer, after determining the target frame rate, the PC can adjust the frequency of the first application calling the GPU at the loader wrapper layer based on the target frame rate to reduce the rendering frame rate of the first application. In some examples, the first application implements rendering based on a flush buffer or swap buffer at the loader wrapper layer, that is, it calls the GPU for rendering. Therefore, the PC can also reduce the frequency of the flush buffer or swap buffer in the loader wrapper layer, thereby reducing the frequency of the first application calling the GPU.

[0152] In this way, for applications that do not access the Vsync signal, since these applications can directly call the GPU in the loader encapsulation layer, the PC in this embodiment can also directly control the frequency of calling the GPU in the loader encapsulation layer, so as to achieve the purpose of adjustable and controllable application rendering frame rate and reduce the situation where the application rendering frame rate exceeds the screen refresh rate.

[0153] In some possible application scenarios, the PC can also ensure that the application's rendering frame rate is not lower than 30 frames / s, even if the application's corresponding window is not completely obscured, so as to ensure the smoothness of the application's operation.

[0154] In general, the frame rate control method in the above embodiments can reduce the rendering frame rate of applications with excessively high rendering frame rates, or make the rendering frame rate of the application less than or equal to the screen refresh rate of the electronic device. This can reduce problems such as severe overheating, high power consumption, and system instability caused by excessively high rendering frame rates.

[0155] In some embodiments, when the first application is detected and killed for some reason, or is not running for some reason, the window corresponding to the first application may still exist, and the PC will also detect the rendering frame rate corresponding to the first application. Since the first application is not running or has been detected and killed, the window of the first application is an invalid window, and the rendering of the window content by the first application will consume CPU and GPU resources. In this case, the PC will directly reduce the rendering frame rate corresponding to the application to 0.

[0156] For example, the specific processing procedure for the first application can also be found in [reference needed]. Figure 9 As shown in the diagram. For the first application on the PC, if the application's SOC utilization is high, the PC can determine the application's status, such as whether it's running or has been detected / killed. If the application is not running or has been detected / killed, and it has a corresponding rendering frame rate, the PC will reduce the application's rendering frame rate to 0. If the application is running or has not been detected / killed, the PC will obtain the application's window occlusion information and its SOC utilization. Then, based on the window occlusion information and the application's SOC utilization, the PC will determine a target frame rate and reduce the application's rendering frame rate accordingly, or ensure that the application's rendering frame rate does not exceed the screen refresh rate.

[0157] This can be due to several factors, including: the first application not running but having a corresponding rendering frame rate; or the first application being frozen and temporarily stopped, but its corresponding window not being closed. Even when an application is not running or has been detected and killed, the PC can control its rendering frame rate to prevent the application from still occupying the SOC, which could lead to excessive SOC usage and negatively impact PC performance and system stability.

[0158] As another example, the specific processing procedure for the first application can also be found in [reference needed]. Figure 10 As shown in the diagram. Specifically, for the first application on the PC, the PC can determine the application's status, such as whether it's running or has been detected and removed, even when the PC is overheating. If the first application is not running or has been removed, and it has a corresponding rendering frame rate, the PC will reduce its rendering frame rate to 0. If the first application is running or has not been removed, the PC will obtain the application's window occlusion information and the PC's temperature. Then, based on the window occlusion information and the PC's temperature, the PC will determine a target frame rate and reduce the first application's rendering frame rate accordingly, or ensure that the first application's rendering frame rate does not exceed the screen refresh rate.

[0159] Severe PC overheating can include severe overheating of the SOC within the PC and / or severe overheating of the entire system. The severity of overheating can be determined based on the temperature of the SOC and / or the temperature of the entire system.

[0160] In other embodiments, for a first application with a high rendering frame rate, the PC can also determine the status of the first application, such as whether the first application is running or has been detected and killed. If the first application is not running or has been detected and killed, and the first application has a corresponding rendering frame rate, then the PC reduces the rendering frame rate of the first application to 0. If the first application is running or has not been detected and killed, then the PC obtains the window occlusion information of the first application and the overall load of the PC. Then, based on the window occlusion information and the overall load of the PC, the PC reduces the rendering frame rate of the first application, or ensures that the rendering frame rate of the first application does not exceed the screen refresh rate.

[0161] Whether the drawing frame rate is high or low can be determined by comparing the drawing frame rate with the screen refresh rate. When the drawing frame rate is higher than the screen refresh rate, it can be determined that the drawing frame rate is high; when the drawing frame rate is lower than or equal to the screen refresh rate, it can be determined that the drawing frame rate is low.

[0162] The above embodiments all use a PC to execute the frame rate control method as an example for illustration. In other embodiments, the above method can also be executed by a mobile phone, tablet computer, smartwatch, smart TV, vehicle terminal, handheld computer, laptop computer, UMPC, netbook, as well as cellular phone, PDA, AR / VR device, smart home device (such as smart TV, smart screen device, smart central control device), etc. The embodiments of this application do not impose special limitations on the specific form of the electronic device.

[0163] In some solutions, multiple embodiments of this application can be combined, and the combined solution can be implemented. Optionally, some operations in the processes of each method embodiment may be combined, and / or the order of some operations may be changed. Furthermore, the execution order between the steps of each process is merely exemplary and does not constitute a limitation on the execution order between steps; other execution orders are also possible. It is not intended to indicate that the execution order is the only possible order in which these operations can be performed. Those skilled in the art will conceive of various ways to reorder the operations described in the embodiments of this application. In addition, it should be noted that the process details involved in one embodiment of this application are also applicable to other embodiments in a similar manner, or different embodiments may be combined.

[0164] Furthermore, some steps in the method embodiments can be equivalently replaced with other possible steps. Alternatively, some steps in the method embodiments may be optional and can be deleted in certain use cases. Or, other possible steps may be added to the method embodiments.

[0165] Furthermore, the various method embodiments can be implemented individually or in combination.

[0166] It is understood that, in order to achieve the above functions, the aforementioned electronic device includes hardware and / or software modules corresponding to perform each function. Based on the algorithmic steps of the various examples described in conjunction with the embodiments disclosed herein, this application can be implemented in hardware or a combination of hardware and computer software. Whether a function is executed in hardware or by computer software driving hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application in conjunction with the embodiments, but such implementation should not be considered beyond the scope of this application.

[0167] This embodiment can divide the electronic device into functional modules according to the above method example. For example, each function can be divided into its own functional modules, or two or more functions can be integrated into one processing module. The integrated modules can be implemented in hardware. It should be noted that the module division in this embodiment is illustrative and only represents one logical functional division. In actual implementation, there may be other division methods.

[0168] For example, this application provides a frame rate control device, which includes a display screen. See also... Figure 11 As shown, the device also includes an information collection module 1101 and a frame rate control module 1102.

[0169] The information collection module 1101 is used to acquire window occlusion information of the first application when the rendering frame rate of the first application is greater than the screen refresh rate of the display screen and / or the overall load of the frame rate control device is greater than a preset load. The window occlusion information is used to indicate that the window corresponding to the first application is occluded by other displayed content on the display screen. For example, the information collection module 1101 can perform the relevant content as described in S601 above.

[0170] The frame rate control module 1102 is used to reduce the rendering frame rate of the first application based on the window occlusion information of the first application and the overall system load. For example, the frame rate control module 1102 can perform the relevant content as described in S602 above.

[0171] This application also provides an electronic device, such as... Figure 12 As shown, the electronic device may include one or more processors 1201, memory 1202 and communication interface 1203.

[0172] The memory 1202, communication interface 1203, and processor 1201 are coupled together. For example, the memory 1202, communication interface 1203, and processor 1201 can be coupled together via bus 1204.

[0173] The communication interface 1203 is used for data transmission with other devices. The memory 1202 stores computer program code. The computer program code includes computer instructions, which, when executed by the processor 1201, cause the electronic device to perform the frame rate control method described in this embodiment.

[0174] The processor 1201 may be a processor or controller, such as a CPU, a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, transistor logic devices, hardware components, or any combination thereof. It can implement or execute the various exemplary logic blocks, modules, and circuits described in conjunction with this disclosure. The processor may also be a combination that implements computational functions, such as a combination of one or more microprocessors, a combination of a DSP and a microprocessor, etc.

[0175] Bus 1204 can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. Bus 1204 can be divided into address bus, data bus, control bus, etc. For ease of representation, Figure 12 The bus is represented by a single thick line, but this does not mean that there is only one bus or one type of bus.

[0176] This application also provides a computer-readable storage medium that includes computer instructions. When the computer instructions are executed on an electronic device, the electronic device performs the relevant method steps described in the above method embodiments.

[0177] This application also provides a computer program product that, when run on a computer, causes the computer to execute the relevant method steps described in the above method embodiments.

[0178] The frame rate control device, electronic device, computer-readable storage medium or computer program product provided in this application are all used to execute the corresponding methods provided above. Therefore, the beneficial effects they can achieve can be referred to the beneficial effects in the corresponding methods provided above, and will not be repeated here.

[0179] Through the above description of the embodiments, those skilled in the art can clearly understand that, for the sake of convenience and brevity, only the division of the above functional modules is used as an example. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.

[0180] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another device, or some features may be ignored or not executed. Furthermore, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.

[0181] The units described as separate components may or may not be physically separate. A component shown as a unit can be one or more physical units; that is, it can be located in one place or distributed in multiple different locations. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0182] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0183] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solution of the embodiments of this application, in essence, or the part that contributes, or all or part of the technical solution, can be embodied in the form of a software product. This software product is stored in a storage medium and includes several instructions to cause a device (which may be a microcontroller, chip, etc.) or processor to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0184] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. A frame rate control method, characterized in that, The method is applied to an electronic device, the electronic device including at least one application, the at least one application including a first application; the method includes: If the rendering frame rate of the first application is greater than the screen refresh rate of the electronic device and / or the overall load of the electronic device is greater than a preset load, the window occlusion information of the first application is obtained; the window occlusion information is used to indicate the situation where the window corresponding to the first application is occluded by other displayed content on the display screen of the electronic device. Based on the window occlusion information of the first application and the overall system load, the rendering frame rate of the first application is reduced.

2. The method according to claim 1, characterized in that, The overall load of the electronic device includes the SOC occupancy rate of the first application and / or the temperature of the electronic device; the overall load of the electronic device being greater than a preset load includes at least one of the following: the SOC occupancy rate of the first application is greater than the preset occupancy rate, the SOC temperature is greater than a first preset temperature, or the overall temperature of the electronic device is greater than a second preset temperature.

3. The method according to claim 1 or 2, characterized in that, Based on the window occlusion information of the first application and the overall system load, the rendering frame rate of the first application is reduced, including: Based on the window occlusion information of the first application and the overall system load, the rendering frame rate of the first application is reduced to the target frame rate.

4. The method according to claim 3, characterized in that, The step of reducing the rendering frame rate of the first application to the target frame rate based on the window occlusion information of the first application and the overall system load includes: Based on the overall load, the load level of the electronic device is obtained; different load levels correspond to different load ranges, and overall loads within the same load range belong to the same load level; The target frame rate of the first application is determined based on the load level and the window occlusion information of the first application. Reduce the rendering frame rate of the first application to the target frame rate.

5. The method according to claim 4, characterized in that, The load level includes a first load level, which indicates at least one of the following: the SOC utilization of the first application is greater than 90%, the SOC temperature is greater than 90°C, and the overall temperature of the electronic device is greater than 37°C; the first application includes at least one window, and the at least one window includes a first window; determining the target frame rate of the first application based on the load level and the window occlusion information of the first application includes: For the first load level, Based on the window occlusion information, it is determined that the first window corresponding to the first application is not occluded, and the target frame rate is determined to be equal to the screen refresh rate of the electronic device.

6. The method according to claim 5, characterized in that, Determining the target frame rate of the first application based on the load level and the window occlusion information of the first application includes: For the first load level, Based on the window occlusion information, it is determined that the first window corresponding to the first application is occluded by 1 / 3, and the target frame rate is determined to be 1 / 2 of the screen refresh rate of the electronic device.

7. The method according to claim 5 or 6, characterized in that, Determining the target frame rate of the first application based on the load level and the window occlusion information of the first application includes: For the first load level, Based on the window occlusion information, it is determined that the first window corresponding to the first application is occluded by 2 / 3, and the target frame rate is determined to be 1 / 4 of the screen refresh rate of the electronic device.

8. The method according to any one of claims 5-7, characterized in that, Determining the target frame rate of the first application based on the load level and the window occlusion information of the first application includes: For the first load level, Based on the window occlusion information, it is determined that the first window corresponding to the first application is completely occluded, and the target frame rate is determined to be 0.

9. The method according to claim 4, characterized in that, The load level includes a second load level, which indicates at least one of the following: the SOC utilization of the first application is greater than 70% and less than or equal to 90%; the SOC temperature is greater than 80°C and less than or equal to 90°C; the overall temperature of the electronic device is greater than 30°C and less than or equal to 37°C; the first application includes at least one window, and the at least one window includes a first window; determining the target frame rate of the first application based on the load level and the window occlusion information of the first application includes: For the second load level, If the window corresponding to the first application is determined to be 2 / 3 obscured based on the window occlusion information, then the target frame rate is 1 / 3 of the screen refresh rate of the electronic device.

10. The method according to any one of claims 1-9, characterized in that, The method further includes: If the rendering frame rate of the first application is greater than the screen refresh rate of the electronic device and / or the overall load of the electronic device is greater than a preset load, the rendering frame rate of the first application is reduced to 0 in response to the first application not running or being detected and killed.

11. The method according to any one of claims 1-7, characterized in that, The electronic device includes a loader encapsulation layer, the loader encapsulation layer being used by the first application to invoke the graphics processing unit (GPU); the method further includes: The number of times the first application calls the loader encapsulation layer is obtained to determine the rendering frame rate of the first application.

12. The method according to claim 4, characterized in that, The step of reducing the rendering frame rate of the first application to the target frame rate includes: In the loader encapsulation layer, the frequency at which the first application calls the GPU is adjusted according to the target frame rate, so as to reduce the rendering frame rate of the first application.

13. The method according to any one of claims 1-12, characterized in that, The SOC includes a central processing unit (CPU) and a GPU, and the SOC utilization rate includes the CPU utilization rate and the GPU utilization rate.

14. An electronic device, characterized in that, The device includes a memory and one or more processors; the memory is coupled to the processors; wherein the memory stores computer program code, the computer program code including computer instructions, which, when executed by the processor, cause the electronic device to perform the frame rate control method as described in any one of claims 1-13.

15. A computer-readable storage medium, characterized in that, Includes computer instructions that, when executed on an electronic device, cause the electronic device to perform the frame rate control method as described in any one of claims 1-13.

16. A computer program product, characterized in that, When the computer program product is run on a computer, it causes the computer to perform the frame rate control method as described in any one of claims 1-13.