Interface display method and related equipment

By using a universal synthesis channel in the terminal device to synthesize a rounded corner layer containing a privacy indicator, the problem that the rounded corner synthesis channel cannot synthesize a rounded corner layer with a privacy indicator is solved, achieving more efficient layer resource management and lower power consumption.

CN119739357APending Publication Date: 2025-04-01HONOR DEVICE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311238876.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-09-22
Publication Date
2025-04-01

AI Technical Summary

Technical Problem

In terminal devices, physically cut rounded corners may have jagged when displayed on the screen, and in the scene where the privacy indicator is displayed, the rounded corner synthesis channel cannot synthesize the rounded corner layer with the privacy indicator, resulting in abnormal layer synthesis.

Method used

Using an interface display method, by receiving user actions and responding to launching the camera or recording application, draw a rounded corner layer containing a privacy indicator, and use a universal synthesis channel to synthesize the rounded corner layer and the application layer, avoiding the rounded corner synthesis channel.

Benefits of technology

It solves the problem of abnormal synthesis of rounded-corner layer, reduces the consumption of layer resources, reduces the power consumption of electronic devices, improves display performance, and reserves more layer resources for the application layer.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119739357A_ABST
    Figure CN119739357A_ABST
Patent Text Reader

Abstract

The present application provides an interface display method and related equipment, which relate to the field of terminal technology. The interface display method includes: in response to a first operation of a user, starting a first application, the first application has a privacy indicator display requirement; drawing a first rounded corner layer containing a privacy indicator; drawing an application layer containing image information of the first application; using a general synthesis channel to synthesize the first rounded corner layer and the application layer to obtain an image frame; and displaying the image frame on a display screen. Using the above method, in the scenario of displaying a privacy indicator, a general synthesis channel is used instead of a rounded corner synthesis channel to synthesize a rounded corner layer, which can avoid layer synthesis anomalies caused by the inability of the rounded corner synthesis channel to synthesize a rounded corner layer with a privacy indicator drawn thereon, and drawing the privacy indicator on the rounded corner layer can reserve more layer resources for the application layer, reduce the number of layers to be synthesized and the power consumption of the device, and improve the display performance of the device.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the field of terminal technology, and in particular, to an interface display method and related equipment. Background Art

[0002] In terminal products (such as tablets, mobile phones, etc.) released by terminal manufacturers, in order to achieve visual beauty and high screen-to-body ratio, the four corners of the screen are generally rounded. After the screen corners are physically cut, jagged edges may appear when the screen is displayed, giving users a bad visual experience.

[0003] To solve this problem, terminal manufacturers generally use software to draw a rounded corner layer with the same curvature to block the jagged phenomenon caused by physical cutting. The general software implementation method is as follows: create a rounded corner layer on the top layer and the bottom layer of the image to be displayed, fill the rounded corner layer with grayscale rendering, and keep the rounded corner filling edge consistent with the rounded corner curvature of the physical cutting to block the jaggedness and improve the user's visual experience.

[0004] When the camera or recording app is opened, for privacy and security reasons, a privacy indicator (usually a small green dot) is usually displayed in the upper right corner of the screen to remind the user that the app is using the camera or recording function. If a separate layer is created for the privacy indicator, the rounded corner layer will occupy two layer resources, resulting in a shortage of layer resources for the application interface display, which will have a negative impact on the display performance and power consumption of electronic devices.

[0005] Some chip manufacturers have opened up a dedicated rounded corner synthesis channel inside the hardware synthesizer to address the characteristics of rounded corner layers that are not updated frequently and have single layer content and rendering colors. This rounded corner synthesis channel is specifically used for synthesizing rounded corner layers. Since the rounded corner synthesis channel only supports single-channel color mode and does not support multi-channel color mode, when the privacy indicator is drawn on the rounded corner layer, since the privacy indicator is in color, the rounded corner layer drawn with the privacy indicator using the rounded corner synthesis channel will cause layer synthesis anomalies. Therefore, it is necessary to create a separate layer for the privacy indicator, that is, not drawing the privacy indicator on the rounded corner layer can avoid the problem of rounded corner layer synthesis anomalies. Summary of the invention

[0006] In view of the above content, it is necessary to provide an interface display method and related equipment. In the scenario of displaying the privacy indicator, the rounded corner layer is not synthesized using the rounded corner synthesis channel dedicated to the rounded corner layer, so as to solve the layer synthesis anomaly problem caused by the rounded corner synthesis channel being unable to synthesize the rounded corner layer on which the privacy indicator is drawn. In addition, the privacy indicator is drawn on the rounded corner layer, which can reserve more layer resources for the application layer.

[0007] In a first aspect, the present application provides an interface display method, which is applied to an electronic device, wherein the electronic device includes a processing chip and a display screen, the processing chip includes a general synthesis channel for layer synthesis and a rounded corner synthesis channel dedicated to the rounded corner layer, and the interface display method includes: receiving a first operation of a user; in response to the first operation, starting a first application, the first application is an application with a privacy indicator display requirement; drawing a first rounded corner layer, the first rounded corner layer including a privacy indicator; drawing an application layer containing image information of the first application; using the general synthesis channel to synthesize the first rounded corner layer and the application layer to obtain an image frame; and displaying the image frame on the display screen.

[0008] By adopting the above technical solution, the processing chip may refer to a processor chip or a system-level chip. In a scenario where a privacy indicator needs to be displayed, the rounded corner synthesis channel dedicated to the rounded corner layer is not used to synthesize the rounded corner layer. This can solve the problem of layer synthesis abnormality caused by the inability of the rounded corner synthesis channel to synthesize the rounded corner layer with the privacy indicator drawn on it. Drawing the privacy indicator on the rounded corner layer can reserve more layer resources for the application layer, reducing the number of layers to be synthesized, thereby reducing the resource occupation of layer synthesis, and increasing the possibility of electronic devices using hardware synthesis methods to synthesize layers, thereby reducing the power consumption of electronic devices and improving the display performance of electronic devices.

[0009] In one possible implementation, the electronic device also starts a second application, the thread of the second application is used to draw the first rounded corner layer and send the first rounded corner layer to SurfaceFlinger, the thread of the first application is used to draw the application layer containing the image information of the first application and send the application layer of the first application to SurfaceFlinger.

[0010] Using the above technical solution, the second application may refer to a system-level application (SystemUI), which may be automatically started during the startup of the electronic device. The first rounded corner layer containing the privacy indicator may be drawn by the thread of SystemUI. When the privacy indicator needs to be displayed, SurfaceFlinger will not call the rounded corner synthesis channel dedicated to the rounded corner layer to synthesize the rounded corner layer, thereby solving the problem of layer synthesis abnormality caused by the inability of the rounded corner synthesis channel to synthesize the rounded corner layer with the privacy indicator drawn.

[0011] In one possible implementation, the interface display method also includes: receiving a second operation from the user; exiting the first application in response to the second operation; drawing a second rounded corner layer, the second rounded corner layer does not include a privacy indicator; and synthesizing the second rounded corner layer using a rounded corner synthesis channel.

[0012] By adopting the above technical solution, after exiting the first application, since there is no need to display the privacy indicator, the rounded corner layer can be synthesized using the rounded corner synthesis channel dedicated to the rounded corner layer. This can make full use of the rounded corner synthesis channel of the processing chip, reserve more layer synthesis resources for non-rounded corner layers (without occupying the general synthesis channel), and increase the possibility of electronic devices using hardware synthesis methods to synthesize layers, thereby reducing the power consumption of electronic devices and improving the display performance of electronic devices.

[0013] In one possible implementation, after exiting the first application, the interface display method also includes: creating a cancel display notification of the privacy indicator; using the rounded corner synthesis channel to synthesize the second rounded corner layer, including: based on the cancel display notification of the privacy indicator, using the rounded corner synthesis channel to synthesize the second rounded corner layer.

[0014] By adopting the above technical solution, in a scenario where the privacy indicator does not need to be displayed, a notification to cancel the display of the privacy indicator is created, so that SurfaceFlinger can respond to the notification to cancel the display of the privacy indicator, and use the rounded corner synthesis channel to synthesize the second rounded corner layer, so as to make full use of the rounded corner synthesis channel of the processing chip, reserve more layer synthesis resources for non-rounded corner layers, and enhance the possibility of electronic devices using hardware synthesis methods to synthesize layers. For example, the thread of SystemUI can create a notification to cancel the display of the privacy indicator, so that in a scenario where the privacy indicator does not need to be displayed, the notification to cancel the display of the privacy indicator can be sent to SurfaceFlinger accurately and timely.

[0015] In one possible implementation, the processing chip includes a hardware compositor (HWC), the HWC includes a rounded corner synthesis channel, the HWC includes a rounded corner synthesis channel and a general synthesis channel, the HWC is used to use the rounded corner synthesis channel to synthesize the layer to be synthesized when the layer to be synthesized includes a rounded corner label, and based on the cancel display notification of the privacy indicator, use the rounded corner synthesis channel to synthesize the second rounded corner layer, including: the synthesis service (SurfaceFlinger) adds a rounded corner label to the second rounded corner layer in response to the cancel display notification of the privacy indicator; SurfaceFlinger sends the second rounded corner layer containing the rounded corner label to the HWC; HWC uses the rounded corner synthesis channel to synthesize the second rounded corner layer.

[0016] By adopting the above technical solution, HWC determines whether to use the rounded corner synthesis channel for synthesis by identifying whether the layer to be synthesized includes a rounded corner label. When the layer to be synthesized includes a rounded corner label, the rounded corner synthesis channel is used to synthesize the layer to be synthesized. In the scenario where the privacy indicator does not need to be displayed, SurfaceFlinger can add a rounded corner label to the rounded corner layer based on the cancellation notification of the privacy indicator, so that HWC will use the rounded corner synthesis channel dedicated to the rounded corner layer to synthesize the rounded corner layer, thereby making full use of the rounded corner synthesis channel of the processing chip, reserving more layer synthesis resources for non-rounded corner layers, and improving the possibility of electronic devices using hardware synthesis to synthesize layers.

[0017] In one possible implementation, the processing chip includes an HWC, the HWC includes a rounded corner synthesis channel and a general synthesis channel, and based on the cancel display notification of the privacy indicator, the rounded corner synthesis channel is used to synthesize the second rounded corner layer, including: SurfaceFlinger creates first identification information in response to the cancel display notification of the privacy indicator, the first identification information includes the identification of the second rounded corner layer; SurfaceFlinger sends the second rounded corner layer and the first identification information to the HWC; the HWC enables the rounded corner synthesis channel based on the first identification information, and uses the rounded corner synthesis channel to synthesize the second rounded corner layer.

[0018] By adopting the above technical solution, after exiting the first application, since there is no need to display the privacy indicator, SurfaceFlinger can create first identification information based on the notification of canceling the display of the privacy indicator, and the first identification information includes the identification of the rounded corner layer. HWC can enable the rounded corner synthesis channel and locate the rounded corner layer based on the first identification information, and then use the rounded corner synthesis channel dedicated to the rounded corner layer to synthesize the rounded corner layer, so as to make full use of the rounded corner synthesis channel of the processing chip, reserve more layer synthesis resources for non-rounded corner layers, and improve the possibility of electronic devices using hardware synthesis to synthesize layers, thereby reducing the power consumption of electronic devices and improving the display performance of electronic devices.

[0019] In one possible implementation, after starting the first application, the interface display method also includes: creating a display notification of the privacy indicator; and synthesizing the first rounded corner layer and the application layer using a universal synthesis channel, including: based on the display notification of the privacy indicator, synthesizing the first rounded corner layer and the application layer using a universal synthesis channel.

[0020] By adopting the above technical solution, in the scenario where the privacy indicator needs to be displayed, by creating a display notification of the privacy indicator, SurfaceFlinger can respond to the display notification of the privacy indicator, and use the general synthesis channel to synthesize the first rounded corner layer and the application layer, which can solve the layer synthesis abnormality problem caused by the inability of the rounded corner synthesis channel to synthesize the rounded corner layer with the privacy indicator drawn on it. By drawing the privacy indicator on the rounded corner layer, more layer resources can be reserved for the application layer, reducing the number of layers to be synthesized, thereby reducing the resource occupation of layer synthesis, and increasing the possibility of electronic devices using hardware synthesis methods to synthesize layers, thereby reducing the power consumption of electronic devices and improving the display performance of electronic devices. For example, the display notification of the privacy indicator can be created by the thread of SystemUI, so that in the scenario where the privacy indicator needs to be displayed, the display notification of the privacy indicator can be sent to SurfaceFlinger accurately and timely.

[0021] In one possible implementation, the processing chip includes an HWC, the HWC includes a rounded corner synthesis channel and a general synthesis channel, the HWC is used to use the rounded corner synthesis channel to synthesize the layer to be synthesized when the layer to be synthesized includes a rounded corner label, and based on the display notification of the privacy indicator, use the general synthesis channel to synthesize the first rounded corner layer and the application layer, including: SurfaceFlinger removes the rounded corner label set for the first rounded corner layer in response to the display notification of the privacy indicator; SurfaceFlinger sends the first rounded corner layer and the application layer that do not include the rounded corner label to the HWC; HWC uses the general synthesis channel to synthesize the first rounded corner layer and the application layer.

[0022] By adopting the above technical solution, HWC determines whether to use the rounded corner synthesis channel for synthesis by identifying whether the layer to be synthesized includes a rounded corner label. When the layer to be synthesized includes a rounded corner label, the rounded corner synthesis channel is used to synthesize the layer to be synthesized. In the scenario where the privacy indicator needs to be displayed, SurfaceFlinger can remove the rounded corner label set for the rounded corner layer based on the display notification of the privacy indicator, so that HWC will not use the rounded corner synthesis channel dedicated to the rounded corner layer to synthesize the rounded corner layer, and use the general synthesis channel to synthesize the rounded corner layer and the application layer, thereby solving the problem of layer synthesis abnormality caused by the inability of the rounded corner synthesis channel to synthesize the rounded corner layer with a privacy indicator drawn.

[0023] In one possible implementation, the processing chip includes an HWC, the HWC includes a rounded corner synthesis channel and a universal synthesis channel, and based on the display notification of the privacy indicator, the universal synthesis channel is used to synthesize the first rounded corner layer and the application layer, including: SurfaceFlinger creates second identification information in response to the display notification of the privacy indicator; SurfaceFlinger sends the first rounded corner layer, the application layer and the second identification information to the HWC; the HWC disables the rounded corner synthesis channel based on the second identification information, and uses the universal synthesis channel to synthesize the first rounded corner layer and the application layer.

[0024] By adopting the above technical solution, in a scenario where a privacy indicator needs to be displayed, SurfaceFlinger can create second identification information based on the display notification of the privacy indicator, and HWC disables the rounded corner synthesis channel dedicated to the rounded corner layer based on the second identification information, so that HWC does not use the rounded corner synthesis channel to synthesize the rounded corner layer, and uses the general synthesis channel to synthesize the rounded corner layer and the application layer, thereby solving the layer synthesis abnormality problem caused by the inability of the rounded corner synthesis channel to synthesize the rounded corner layer with the privacy indicator drawn.

[0025] In a possible implementation manner, the interface display method further includes: constructing a transmission interface for transmitting the first identification information or the second identification information between SurfaceFlinger and HWC.

[0026] By adopting the above technical solution, a transmission interface specifically used for transmitting the first identification information or the second identification information is constructed between SurfaceFlinger and HWC, so that SurfaceFlinger can transmit the first identification information or the second identification information to HWC, so as to facilitate the subsequent disabling or enabling of the rounded corner synthesis channel by HWC. The transmission interface can be an Android interface definition language (AIDL) interface.

[0027] In one possible implementation, a universal synthesis channel is used to synthesize the first rounded corner layer and the application layer, including: when the synthesis capability of the universal synthesis channel meets the synthesis requirements of the first rounded corner layer and the application layer, the universal synthesis channel is used to synthesize the first rounded corner layer and the application layer; when the synthesis capability of the universal synthesis channel does not meet the synthesis requirements of the first rounded corner layer and the application layer, a graphics processing unit (GPU) and the universal synthesis channel are used to synthesize the first rounded corner layer and the application layer.

[0028] By adopting the above technical scheme, when the synthesis capability of the general synthesis channel meets the synthesis requirements of the rounded corner layer and the application layer, the general synthesis channel is used to synthesize the rounded corner layer and the application layer, that is, the rounded corner layer and the application layer are synthesized using the hardware synthesis method, thereby reducing the power consumption of the electronic device and improving the display performance of the electronic device. When the synthesis capability of the general synthesis channel does not meet the synthesis requirements of the rounded corner layer and the application layer, the GPU (software synthesis method) and the general synthesis channel (hardware synthesis method) are used to synthesize the rounded corner layer and the application layer, that is, a hybrid synthesis method including the hardware synthesis method and the software synthesis method is used for layer synthesis. Compared with simply using the software synthesis method for layer synthesis, the layer synthesis efficiency is higher and the device power consumption is lower.

[0029] In a possible implementation, the first application is a camera application or a recording application.

[0030] By adopting the above technical solution, when an electronic device starts a camera application or a recording application, it is necessary to display a privacy indicator. By synthesizing the rounded corner layer without using the rounded corner synthesis channel dedicated to the rounded corner layer, the problem of layer synthesis abnormality caused by the inability of the rounded corner synthesis channel to synthesize the rounded corner layer with the privacy indicator drawn can be solved. In addition, by drawing the privacy indicator on the rounded corner layer, more layer resources can be reserved for the layers of the camera application or the recording application, reducing the number of layers to be synthesized, and increasing the possibility of electronic devices using hardware synthesis methods to synthesize layers, thereby reducing the power consumption of electronic devices and improving the display performance of electronic devices.

[0031] In the second aspect, the present application also provides an interface display method, which is applied to an electronic device, the electronic device including a processing chip and a display screen, the processing chip including a general synthesis channel for layer synthesis and a rounded corner synthesis channel dedicated to the rounded corner layer, the interface display method including: receiving a first operation of the user; in response to the first operation, starting a camera application; drawing a first rounded corner layer, the first rounded corner layer including the privacy indicator; drawing a camera preview layer of the camera application; using the general synthesis channel to synthesize the first rounded corner layer and the camera preview layer to obtain a camera preview interface; displaying the camera preview interface on the display screen.

[0032] Using the above technical solution, the processing chip may refer to a processor chip or a system-level chip. After the camera application is opened, a privacy indicator will be displayed on the camera preview interface. The privacy indicator is drawn on the rounded corner layer. By synthesizing the rounded corner layer without using the rounded corner synthesis channel dedicated to the rounded corner layer, the problem of layer synthesis abnormality caused by the inability of the rounded corner synthesis channel to synthesize the rounded corner layer with the privacy indicator drawn can be solved. Drawing the privacy indicator on the rounded corner layer can reserve more layer resources for the application layer, reducing the number of layers to be synthesized, thereby reducing the resource occupation of layer synthesis, and increasing the possibility of electronic devices using hardware synthesis methods to synthesize layers, thereby reducing the power consumption of electronic devices and improving the display performance of electronic devices.

[0033] In one possible implementation, the interface display method also includes: receiving a second operation from the user; in response to the second operation, switching to the interface of other applications, where the other applications do not have a requirement to display a privacy indicator; drawing a second rounded corner layer, where the second rounded corner layer does not include a privacy indicator; and synthesizing the second rounded corner layer using a rounded corner synthesis channel.

[0034] By adopting the above technical solution, when switching from the camera application interface to other application interfaces that do not have the display requirements of the privacy indicator, since there is no need to display the privacy indicator, the rounded corner layer can be synthesized using the rounded corner synthesis channel dedicated to the rounded corner layer. This can make full use of the rounded corner synthesis channel of the processing chip, reserve more layer synthesis resources for non-rounded corner layers (without occupying general synthesis channels), and increase the possibility of electronic devices using hardware synthesis methods to synthesize layers, thereby reducing the power consumption of electronic devices and improving the display performance of electronic devices.

[0035] In one possible implementation, after switching to the interface of other applications, the interface display method also includes: creating a cancel display notification of the privacy indicator; and synthesizing the second rounded corner layer using a rounded corner synthesis channel, including: based on the cancel display notification of the privacy indicator, synthesizing the second rounded corner layer using a rounded corner synthesis channel.

[0036] By adopting the above technical solution, when switching from the camera application interface to other application interfaces that do not have the display requirement of the privacy indicator, since the privacy indicator does not need to be displayed, by creating a cancel display notification of the privacy indicator, SurfaceFlinger can respond to the cancel display notification of the privacy indicator and use the rounded corner synthesis channel to synthesize the rounded corner layer, so as to make full use of the rounded corner synthesis channel of the processing chip, reserve more layer synthesis resources for non-rounded corner layers, and enhance the possibility of electronic devices using hardware synthesis methods to synthesize layers. For example, the cancel display notification of the privacy indicator can be created by the SystemUI thread, so that in the scenario where the privacy indicator does not need to be displayed, the cancel display notification of the privacy indicator can be accurately and timely sent to SurfaceFlinger.

[0037] In one possible implementation, the processing chip includes an HWC, the HWC includes a rounded corner synthesis channel and a general synthesis channel, the HWC is used to use the rounded corner synthesis channel to synthesize the layer to be synthesized when the layer to be synthesized includes a rounded corner label, and based on the cancel display notification of the privacy indicator, use the rounded corner synthesis channel to synthesize the second rounded corner layer, including: SurfaceFlinger adds a rounded corner label to the second rounded corner layer in response to the cancel display notification of the privacy indicator; SurfaceFlinger sends the second rounded corner layer containing the rounded corner label to the HWC; HWC uses the rounded corner synthesis channel to synthesize the second rounded corner layer.

[0038] By adopting the above technical solution, HWC determines whether to use the rounded corner synthesis channel for synthesis by identifying whether the layer to be synthesized includes a rounded corner label. When the layer to be synthesized includes a rounded corner label, the rounded corner synthesis channel is used to synthesize the layer to be synthesized. When switching from the camera application interface to other application interfaces that do not have the display requirements of the privacy indicator, since there is no need to display the privacy indicator, SurfaceFlinger can add a rounded corner label to the rounded corner layer based on the cancellation display notification of the privacy indicator, so that HWC will use the rounded corner synthesis channel dedicated to the rounded corner layer to synthesize the rounded corner layer, thereby making full use of the rounded corner synthesis channel of the processing chip, reserving more layer synthesis resources for non-rounded corner layers, and improving the possibility of electronic devices using hardware synthesis to synthesize layers.

[0039] In one possible implementation, after starting the camera application, the interface display method also includes: creating a display notification of the privacy indicator; and synthesizing the first rounded corner layer and the camera preview layer using a universal synthesis channel, including: based on the display notification of the privacy indicator, synthesizing the first rounded corner layer and the camera preview layer using a universal synthesis channel.

[0040] By adopting the above technical solution, when the camera application is started to enter the camera preview interface, since the privacy indicator needs to be displayed, a display notification of the privacy indicator is created so that SurfaceFlinger can respond to the display notification of the privacy indicator, and a general synthesis channel is used to synthesize the first rounded corner layer and the camera preview layer, which can solve the layer synthesis abnormality problem caused by the inability of the rounded corner synthesis channel to synthesize the rounded corner layer with the privacy indicator drawn on it. By drawing the privacy indicator on the rounded corner layer, more layer resources can be reserved for the application layer, reducing the number of layers to be synthesized, thereby reducing the resource occupation of layer synthesis, and increasing the possibility of electronic devices using hardware synthesis methods to synthesize layers, thereby reducing the power consumption of electronic devices and improving the display performance of electronic devices. For example, the display notification of the privacy indicator can be created by the thread of SystemUI, so that in the scenario where the privacy indicator needs to be displayed, the display notification of the privacy indicator can be sent to SurfaceFlinger accurately and timely.

[0041] In one possible implementation, the processing chip includes an HWC, the HWC includes a rounded corner synthesis channel and a general synthesis channel, the HWC is used to use the rounded corner synthesis channel to synthesize the layer to be synthesized when the layer to be synthesized includes a rounded corner label, and based on the display notification of the privacy indicator, use the general synthesis channel to synthesize the first rounded corner layer and the camera preview layer, including: SurfaceFlinger removes the rounded corner label set for the first rounded corner layer in response to the display notification of the privacy indicator; SurfaceFlinger sends the first rounded corner layer and the camera preview layer that do not include the rounded corner label to the HWC; HWC uses the general synthesis channel to synthesize the first rounded corner layer and the camera preview layer.

[0042] By adopting the above technical solution, HWC determines whether to use the rounded corner synthesis channel for synthesis by identifying whether the layer to be synthesized includes a rounded corner label. When the layer to be synthesized includes a rounded corner label, the rounded corner synthesis channel is used to synthesize the layer to be synthesized. When the camera application is started to enter the camera preview interface, due to the need to display the privacy indicator, SurfaceFlinger can remove the rounded corner label set for the rounded corner layer based on the display notification of the privacy indicator, so that HWC will not use the rounded corner synthesis channel dedicated to the rounded corner layer to synthesize the rounded corner layer, and use the general synthesis channel to synthesize the rounded corner layer and the camera preview layer, thereby solving the layer synthesis abnormality problem caused by the inability of the rounded corner synthesis channel to synthesize the rounded corner layer with a privacy indicator drawn.

[0043] In the third aspect, the present application also provides an interface display method, which is applied to an electronic device, the electronic device including a processing chip and a display screen, the processing chip including a general synthesis channel for layer synthesis and a rounded corner synthesis channel dedicated to the rounded corner layer, the interface display method including: receiving a first operation of the user; in response to the first operation, starting the recording of the recording application; drawing a first rounded corner layer, the first rounded corner layer including the privacy indicator; drawing the recording layer of the recording application; using the general synthesis channel to synthesize the first rounded corner layer and the recording layer to obtain a recording interface; displaying the recording interface on the display screen.

[0044] By adopting the above technical solution, the processing chip may refer to a processor chip or a system-level chip. After the recording application is opened and the recording is started, a privacy indicator will be displayed on the recording interface. The privacy indicator is drawn on the rounded corner layer. By synthesizing the rounded corner layer without using the rounded corner synthesis channel dedicated to the rounded corner layer, the problem of layer synthesis abnormality caused by the inability of the rounded corner synthesis channel to synthesize the rounded corner layer with the privacy indicator drawn can be solved. Drawing the privacy indicator on the rounded corner layer can reserve more layer resources for the application layer, reducing the number of layers to be synthesized, thereby reducing the resource occupation of layer synthesis, and increasing the possibility of electronic devices using hardware synthesis methods to synthesize layers, thereby reducing the power consumption of electronic devices and improving the display performance of electronic devices.

[0045] In one possible implementation, the interface display method also includes: receiving a second operation from the user; in response to the second operation, stopping recording by the recording application; drawing a second rounded corner layer, the second rounded corner layer does not include a privacy indicator; and synthesizing the second rounded corner layer using a rounded corner synthesis channel.

[0046] By adopting the above technical solution, when the recording of the recording application is stopped, there is no need to display the privacy indicator. By using the rounded corner synthesis channel dedicated to the rounded corner layer to synthesize the rounded corner layer, the rounded corner synthesis channel of the processing chip can be fully utilized, and more layer synthesis resources can be reserved for non-rounded corner layers (without occupying the general synthesis channel), thereby increasing the possibility of electronic devices using hardware synthesis methods to synthesize layers, thereby reducing the power consumption of electronic devices and improving the display performance of electronic devices.

[0047] In one possible implementation, after stopping the recording of the recording application, the interface display method also includes: creating a cancel display notification of the privacy indicator; using a rounded corner synthesis channel to synthesize the second rounded corner layer, including: based on the cancel display notification of the privacy indicator, using a rounded corner synthesis channel to synthesize the second rounded corner layer.

[0048] By adopting the above technical solution, when the recording of the recording application is stopped, since there is no need to display the privacy indicator, a cancel display notification of the privacy indicator is created, so that SurfaceFlinger can respond to the cancel display notification of the privacy indicator, and use the rounded corner synthesis channel to synthesize the rounded corner layer, so as to make full use of the rounded corner synthesis channel of the processing chip, reserve more layer synthesis resources for non-rounded corner layers, and enhance the possibility of electronic devices using hardware synthesis methods to synthesize layers. For example, the cancel display notification of the privacy indicator can be created by the thread of SystemUI, so that in the scenario where the privacy indicator does not need to be displayed, the cancel display notification of the privacy indicator can be accurately and timely sent to SurfaceFlinger.

[0049] In one possible implementation, the processing chip includes an HWC, the HWC includes a rounded corner synthesis channel and a general synthesis channel, the HWC is used to use the rounded corner synthesis channel to synthesize the layer to be synthesized when the layer to be synthesized includes a rounded corner label, and based on the cancel display notification of the privacy indicator, use the rounded corner synthesis channel to synthesize the second rounded corner layer, including: SurfaceFlinger adds a rounded corner label to the second rounded corner layer in response to the cancel display notification of the privacy indicator; SurfaceFlinger sends the second rounded corner layer containing the rounded corner label to the HWC; HWC uses the rounded corner synthesis channel to synthesize the second rounded corner layer.

[0050] By adopting the above technical solution, HWC determines whether to use the rounded corner synthesis channel for synthesis by identifying whether the layer to be synthesized includes a rounded corner label. When the layer to be synthesized includes a rounded corner label, the rounded corner synthesis channel is used to synthesize the layer to be synthesized. When the recording of the recording application is stopped, since there is no need to display the privacy indicator, SurfaceFlinger can add a rounded corner label to the rounded corner layer based on the cancellation notification of the privacy indicator, so that HWC will use the rounded corner synthesis channel dedicated to the rounded corner layer to synthesize the rounded corner layer, thereby making full use of the rounded corner synthesis channel of the processing chip, reserving more layer synthesis resources for non-rounded corner layers, and improving the possibility of electronic devices using hardware synthesis to synthesize layers.

[0051] In one possible implementation, after starting the recording of the recording application, the interface display method also includes: creating a display notification of the privacy indicator; using a general synthesis channel to synthesize the first rounded corner layer and the recording layer, including: based on the display notification of the privacy indicator, using a general synthesis channel to synthesize the first rounded corner layer and the recording layer.

[0052] By adopting the above technical solution, when starting the recording of the recording application, since the privacy indicator needs to be displayed, a display notification of the privacy indicator is created so that SurfaceFlinger can respond to the display notification of the privacy indicator, and a general synthesis channel is used to synthesize the first rounded corner layer and the recording layer, which can solve the layer synthesis abnormality problem caused by the inability of the rounded corner synthesis channel to synthesize the rounded corner layer with the privacy indicator drawn on it. Moreover, by drawing the privacy indicator on the rounded corner layer, more layer resources can be reserved for the application layer, reducing the number of layers to be synthesized, thereby reducing the resource occupation of layer synthesis, and increasing the possibility of electronic devices using hardware synthesis methods to synthesize layers, thereby reducing the power consumption of electronic devices and improving the display performance of electronic devices. For example, the display notification of the privacy indicator can be created by the thread of SystemUI, so that in the scenario where the privacy indicator needs to be displayed, the display notification of the privacy indicator can be accurately and timely sent to SurfaceFlinger.

[0053] In one possible implementation, the processing chip includes an HWC, and the HWC includes a rounded corner synthesis channel and a general synthesis channel. The HWC is used to use the rounded corner synthesis channel to synthesize the layer to be synthesized when the layer to be synthesized includes a rounded corner label, and based on the display notification of the privacy indicator, use the general synthesis channel to synthesize the first rounded corner layer and the recording layer, including: SurfaceFlinger removes the rounded corner label set for the first rounded corner layer in response to the display notification of the privacy indicator; SurfaceFlinger sends the first rounded corner layer and the recording layer that do not include the rounded corner label to the HWC; HWC uses the general synthesis channel to synthesize the first rounded corner layer and the recording layer.

[0054] By adopting the above technical solution, HWC determines whether to use the rounded corner synthesis channel for synthesis by identifying whether the layer to be synthesized includes a rounded corner label. When the layer to be synthesized includes a rounded corner label, the rounded corner synthesis channel is used to synthesize the layer to be synthesized. When the recording of the recording application is started, since the privacy indicator needs to be displayed, SurfaceFlinger can remove the rounded corner label set for the rounded corner layer based on the display notification of the privacy indicator, so that HWC will not use the rounded corner synthesis channel dedicated to the rounded corner layer to synthesize the rounded corner layer, and use the general synthesis channel to synthesize the rounded corner layer and the recording layer, thereby solving the layer synthesis abnormality problem caused by the inability of the rounded corner synthesis channel to synthesize the rounded corner layer with a privacy indicator drawn.

[0055] In a fourth aspect, the present application provides an electronic device, comprising a touch screen, a memory and a processor; the touch screen, the memory and the processor are coupled; the memory is used to store program instructions; the processor is used to read the program instructions stored in the memory to implement the interface display method of the first aspect, the second aspect or the third aspect above.

[0056] In a fifth aspect, the present application provides a computer-readable storage medium, in which computer-readable instructions are stored. When the computer-readable instructions are executed by a processor, the interface display method of the first aspect, the second aspect or the third aspect is implemented.

[0057] In a sixth aspect, the present application provides a chip coupled to a memory in an electronic device, and the chip is used to control the electronic device to implement the interface display method of the first aspect, the second aspect or the third aspect.

[0058] In addition, the technical effects brought about by the fourth to sixth aspects can be found in the descriptions related to the methods of each design in the above method part, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS

[0059] Figure 1A A schematic diagram of a scene with rounded corners display provided in an embodiment of the present application;

[0060] Figure 1B A schematic diagram of pixel distribution of a rounded edge provided in an embodiment of the present application;

[0061] Figure 2 A schematic diagram showing how to improve rounded edge jaggedness by using a rounded corner layer according to an embodiment of the present application;

[0062] Figure 3A A schematic diagram of a display interface of an electronic device according to an embodiment of the present application;

[0063] Figure 3B A schematic diagram showing an electronic device interface according to another embodiment of the present application;

[0064] Figure 3C A schematic diagram of displaying an electronic device interface according to another embodiment of the present application;

[0065] Figure 4 An interactive flow chart of an interface display provided in an embodiment of the present application;

[0066] Figure 5 An interactive flow chart of an interface display provided in another embodiment of the present application;

[0067] Figure 6 An interactive flow chart of an interface display provided in yet another embodiment of the present application;

[0068] Figure 7 A schematic diagram of the software architecture for interaction between SurfaceFlinger and HWC provided in one embodiment of the present application;

[0069] Figure 8 A schematic diagram of the software architecture for interaction between SurfaceFlinger and HWC provided in another embodiment of the present application;

[0070] Fig. 9A A flowchart of an interface display method provided in one embodiment of the present application;

[0071] Fig. 9B A flowchart of an interface display method provided by another embodiment of the present application;

[0072] Fig. 9C A flowchart of an interface display method provided in yet another embodiment of the present application;

[0073] Fig.10 is a software architecture diagram of an electronic device provided by an embodiment of the present application;

[0074] Fig.11 This is a schematic diagram of an application scenario of the interface display method provided by an embodiment of the present application;

[0075] Fig.12 This is a schematic diagram of an application scenario of an interface display method provided by another embodiment of the present application;

[0076] Fig.13 This is a schematic diagram of an application scenario of an interface display method provided by another embodiment of the present application;

[0077] Fig.14 This is a hardware architecture diagram of an electronic device provided in one embodiment of the present application. DETAILED DESCRIPTION

[0078] The following will describe the technical solutions in the embodiments of the present application in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0079] In the following, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of indicated technical features. Thus, the features defined as "first" and "second" may explicitly or implicitly include one or more of the features. In the description of the embodiments of the present application, words such as "exemplary", "or", "for example" are used to indicate examples, illustrations or explanations. Any embodiment or design described as "exemplary" or "for example" in the embodiments of the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary", "or", "for example" is intended to present related concepts in a concrete way.

[0080] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those generally understood by technicians in the technical field of the present application. The terms used in the specification of the present application are only for the purpose of describing specific embodiments and are not intended to limit the present application. It should be understood that, unless otherwise specified in the present application, " / " means or. For example, A / B can represent A or B. "And / or" in the present application is only a kind of association relationship describing associated objects, indicating that three relationships can exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. "At least one" means one or more. "Multiple" means two or more than two. For example, at least one of a, b or c can represent: a, b, c, a and b, a and c, b and c, a, b and c seven situations. It should be understood that the order of the steps shown in the flowchart of this article can be changed, and some can also be omitted.

[0081] In order to facilitate understanding of the embodiments of the present application, first Figure 1A and Figure 1B The four rounded corners of the display screen of the electronic device of the present application are formed by physical cutting, and there is a sawtooth phenomenon during the display process. The electronic device can be a terminal device such as a mobile phone, a tablet computer, a smart watch, etc.

[0082] The term "user interface (UI)" in the following embodiments of the present application refers to a medium interface for interaction and information exchange between an application or operating system and a user, which realizes the conversion between the internal form of information and the form acceptable to the user. The user interface is a source code written in a specific computer language such as Java and extensible markup language (XML). The interface source code is parsed and rendered on an electronic device, and finally presented as content that can be recognized by the user. The commonly used form of user interface is a graphical user interface (GUI), which refers to a user interface related to computer operation displayed in a graphical manner. It can be a visual interface element such as text, icons, buttons, menus, tabs, text boxes, dialog boxes, status bars, navigation bars, widgets, etc. displayed on the display screen of an electronic device.

[0083] like Figure 1A As shown, the electronic device may include a display screen. In order to increase the screen-to-body ratio of the electronic device, the four corners of the display screen are curved to form four rounded corners 10, so that the four corners of the display area in the display screen form a softer display effect. Since the rounded corners 10 are made by physically cutting the display screen, when the picture is displayed, the boundaries of the rounded corners 10 will have jagged edges, which will bring a bad visual experience to the user.

[0084] like Figure 1B As shown, since each pixel unit arrayed in the display screen is rectangular, when the pixel points at the corners of the display screen are processed into an arc shape, the edge of the rounded corner 10 shows obvious jagged phenomenon, which not only affects the user experience, but also reduces the display quality.

[0085] In order to solve this problem, electronic device manufacturers usually use software to draw a rounded corner layer with the same curvature as the rounded corner 10 to block the aliasing phenomenon caused by the rounded corner 10. The general software implementation method is as follows: create a rounded corner layer at the top and bottom of the user interface to be displayed, for example, the rounded corner layer at the top can be named ScreenDecorOverlay layer, and the rounded corner layer at the bottom can be named ScreenDecorOverlayBottom layer; use grayscale rendering to render the rounded corner layers (ScreenDecorOverlay layer and ScreenDecorOverlayBottom layer), and the edges of the rounded corner layers are consistent with the curvature of the rounded corner 10, so as to block the aliasing and improve the user's visual experience.

[0086] like Figure 2As shown, in order to improve the jagged display effect of the rounded edge, the unsmooth first arc 11 can be adjusted to a second arc 12 with a relatively smooth display effect by grayscale rendering the rounded layer. The electronic device can use the existing grayscale rendering algorithm to perform grayscale rendering on the rounded layer to adjust the brightness change of the pixel points near the first arc 11, obtain the second arc 12 with a relatively smooth display effect, and achieve a visual effect of gradual brightness change. When rendering in grayscale, the jagged first arc 11 can be gradually processed from dark to bright, so that the originally harsh jagged first arc 11 becomes softer, thereby achieving a smoother rounded display effect.

[0087] The rounded corner layer in the embodiment of the present application can be considered as an additional layer superimposed to solve the jagged phenomenon of the rounded corners 10 of the display screen when displaying images. The rounded corner layer is mainly used for the rounded corner position of the display screen. Therefore, the rounded corner layer can be a complete layer that matches the size of the display screen, or it can be an incomplete layer that matches the size of the display screen. The "rounded corner" in the embodiment of the present application is described relative to the display screen. Any part with a curved edge on the display screen can be considered as a rounded corner on the display screen (or a screen rounded corner). For example, the position of the "rounded corner" includes not only the four corners of the display screen, but also the hollowed-out area on the screen. That is to say, as long as the display screen has a curved position in the structure, it can be considered as a rounded corner of the display screen. In addition, "rounded corners" include not only arcs, but also other streamlined designs, such as circles, Euler spirals, and other complex curves, etc. The embodiment of the present application does not limit this.

[0088] Introducing rounded corner layers to block jagged edges may reduce the number of available layers in the application display scene. For electronic devices, before the layers are sent to the display screen, they need to be synthesized by the synthesis service (SurfaceFlinger) in the operating system to merge multiple layers into one image frame, and finally send the synthesized image frame to the display screen.

[0089] SurfaceFlinger is used to synthesize layers, and the hardware composer (HWC) is used to provide hardware support for SurfaceFlinger. In the process of layer synthesis, SurfaceFlinger may use hardware synthesis and / or software synthesis. In the embodiment of the present application, the use of both hardware synthesis and software synthesis is called a hybrid synthesis method.

[0090] The software synthesis method may refer to using a graphics processing unit (GPU) to redraw the contents of all layers to be synthesized onto a frame buffer, and then send it to the display screen for display. The software synthesis has good compatibility and is applicable to all image display scenarios. However, since the software synthesis method involves copying the layers to the GPU and synthesizing the layers through the GPU, this will consume additional GPU bandwidth, resulting in high power consumption and relatively slow synthesis speed. The hardware synthesis method may refer to layer synthesis through the HWC integrated in the processor. The hardware synthesis method can directly synthesize the layers to be synthesized and send them to the display screen for display, without occupying additional GPU bandwidth, so the power consumption is small and the synthesis speed is relatively fast. However, the HWC is limited by the specifications of the processor chip. For low-end processor chips, the integrated HWC generally supports the synthesis of up to 4 layers (for example, the HWC includes 4 layer synthesis channels). For high-end processor chips, the integrated HWC generally supports the synthesis of up to 8 layers (for example, the HWC includes 8 layer synthesis channels), and the HWC generally does not support the synthesis of layers with specific display effects, such as being unable to synthesize image frames with display effects such as rotatable and scalable. Since the speed of synthesis using software synthesis alone is relatively slow and the power consumption is high, in order to improve the speed of layer synthesis and reduce the power consumption of electronic devices, in most cases, SurfaceFlinger uses hardware synthesis or hybrid synthesis. If HWC can meet the layer synthesis requirements, SurfaceFlinger uses hardware synthesis. If HWC cannot meet the layer synthesis requirements, SurfaceFlinger uses hybrid synthesis. The synthesis logic of the hybrid synthesis method is generally as follows: for multiple layers to be synthesized, some layers that cannot be synthesized by HWC are handed over to the GPU for synthesis, and the HWC synthesizes the other layers and the synthesis results of the GPU, and then sends them to the display screen. That is, for most device usage scenarios, the probability of using hardware synthesis or hybrid synthesis is higher, and the probability of using software synthesis is lower. The scenario where software synthesis is used alone is generally a layer synthesis with a specific display effect.

[0091] For privacy and security reasons, when an electronic device opens a camera application or a recording application in response to a user operation, a privacy indicator (Privacy Indicator) will be displayed at the top of the display screen to prompt the user that the electronic device is using the camera shooting function or the recording function. For example, the privacy indicator can be a small green dot. The embodiment of the present application does not limit the color or shape of the privacy indicator. In the application display scenario where the privacy indicator needs to be displayed, compared to creating a separate layer for the privacy indicator, drawing the privacy indicator on the rounded corner layer can save a layer, thereby reserving more layer resources for the application display. For example, in a multi-layer display scenario, if a camera application or a recording application is turned on, a privacy indicator needs to be displayed. At this time, if the electronic device also opens a small window to play videos / WeChat video calls / floating windows, resulting in a large number of layers, creating a separate layer for the privacy indicator will have a negative impact on the display performance and power consumption of the electronic device.

[0092] In order to solve the problem of two rounded corner layers being resident, which leads to a reduction in the number of available layers in the application display scene, some chip manufacturers have opened up a dedicated rounded corner synthesis channel inside the HWC, which is specifically used for the synthesis of rounded corner layers, and then releases the original layer synthesis resources of the HWC for the use of non-rounded corner layers, so that the rounded corner layers do not occupy the original layer synthesis channel of the HWC (hereinafter referred to as the general synthesis channel). The general synthesis channel can be used for the synthesis of rounded corner layers or non-rounded corner layers. The rounded corner synthesis channel provided by the chip with rounded corner synthesis function generally only supports single-channel color mode, and does not support multi-channel color mode, that is, it does not support the synthesis of layers with color content, and does not support dynamic enabling / disabling of rounded corner synthesis function. Therefore, when it is required to draw the privacy indicator on the rounded corner layer, because the privacy indicator is colored, the rounded corner layer cannot be synthesized using the rounded corner synthesis channel, and then the privacy indicator needs to be created separately from the rounded corner layer, that is, a separate layer needs to be created for the privacy indicator.

[0093] In view of this, the interface display method provided in the embodiment of the present application can determine the synthesis method of the rounded corner layer according to whether the chip has the rounded corner synthesis function and whether the privacy indicator needs to be displayed. If the chip has the rounded corner synthesis function and does not need to display the privacy indicator, choose to use a dedicated rounded corner synthesis channel to synthesize the rounded corner layer. If the chip has the rounded corner synthesis function and needs to display the privacy indicator, choose to use a general synthesis channel to synthesize the rounded corner layer, so that the privacy indicator can be drawn on the rounded corner layer. If the chip does not have the rounded corner synthesis function (that is, does not include a rounded corner synthesis channel), use the general synthesis channel to synthesize the rounded corner layer, which can also allow the privacy indicator to be drawn on the rounded corner layer.

[0094] When using a general synthesis channel to synthesize rounded corner layers, the synthesis method of the rounded corner layers is decided by the HWC, that is, the HWC determines which synthesis method (hardware synthesis method, software synthesis method, or mixed synthesis method) to use for synthesis based on its own synthesis capabilities.

[0095] like Figure 3A As shown, it is assumed that the screen of the electronic device displays the interface of the first application and the second application. The interface of the first application can be called a status bar. Figure 3A In the example, the first application may be a system-level application (SystemUI), and the second application may be a music application. The following description is made by taking the Android operating system installed in the electronic device as an example, but the present application is not limited thereto, and the electronic device may also be installed with other types of operating systems.

[0096] Figure 3A Four layers are shown: Layer A1, Layer A2, Layer A3, and Layer A4. Layer A1 is the ScreenDecorOverlay layer (the rounded corner layer at the top), Layer A2 is the status bar layer, Layer A3 is the music application layer, and Layer A4 is the ScreenDecorOverlayBottom layer (the rounded corner layer at the bottom).

[0097] The interface of the status bar is maintained by SystemUI, that is, the application that generates layer A2 (the layer of the status bar) is SystemUI, and layer A2 carries the image information of the status bar. In the Android system, the ScreenDecorOverlay layer and the ScreenDecorOverlayBottom layer are also generated by SystemUI, that is, the application that generates layer A1 and layer A4 is SystemUI. SystemUI can pass the generated layers (layer A1, layer A2, layer A4) to SurfaceFlinger. Layer A3 is generated by the music application, and layer A3 carries the image information of the music application. The music application can pass the generated layer A3 to SurfaceFlinger.

[0098] After receiving layer A1, layer A2, layer A3 and layer A4, SurfaceFlinger can perform layer synthesis on layer A1, layer A2, layer A3 and layer A4, and send the synthesized image frame to the display screen for display, so as to realize display such as Figure 3A The interface shown.

[0099] If the processor chip or system-level chip of the electronic device has the rounded corner synthesis function, that is, the HWC includes two types of synthesis channels: a rounded corner synthesis channel dedicated to the rounded corner layer and a general layer synthesis channel (hereinafter referred to as the general synthesis channel), the general synthesis channel can be used to synthesize the rounded corner layer or the non-rounded corner layer. Assuming that the number of rounded corner synthesis channels in the HWC is 2 and the number of general synthesis channels is 4, SurfaceFlinger can call the 2 rounded corner synthesis channels and 2 general synthesis channels in the HWC to synthesize layer A1, layer A2, layer A3 and layer A4. Layer A1 and layer A4 use 2 rounded corner synthesis channels respectively, and layer A2 and layer A3 use 2 general synthesis channels respectively.

[0100] If the processor chip or system-level chip of the electronic device does not have the rounded corner synthesis function, that is, the HWC only includes one type of synthesis channel: the general synthesis channel. Assuming that the number of general synthesis channels in the HWC is 4, it can support the synthesis of four layers. SurfaceFlinger can call the 4 general synthesis channels in the HWC to synthesize layer A1, layer A2, layer A3 and layer A4.

[0101] like Figure 3B As shown, assuming that the screen of the electronic device displays interfaces of a first application and a third application, the interface of the first application can be called a status bar, and the interface of the third application can be an interface of a recording application. Figure 3B Five layers are shown: layer A11, layer A12, layer A13, layer A14, and layer A15. Layer A11 is the ScreenDecorOverlay layer, layer A12 is the status bar layer, layer A13 is the recording application layer, layer A14 is the privacy indicator layer, and layer A15 is the ScreenDecorOverlayBottom layer.

[0102] exist Figure 3B In the example, layer A11, layer A12, layer A14, and layer A15 are generated by SystemUI, layer A12 carries the image information of the status bar, and layer A14 carries the image information of the privacy indicator. SystemUI can pass the generated layers (layers A11, A12, A14, and A15) to SurfaceFlinger. Layer A13 is generated by the recording application, and layer A13 carries the image information of the recording application. The recording application can pass layer A13 to SurfaceFlinger.

[0103] After receiving layer A11, layer A12, layer A13, layer A14, and layer A15, SurfaceFlinger can perform layer synthesis on layer A11, layer A12, layer A13, layer A14, and layer A15, and can send the synthesized image frame to the display screen for display, so as to realize display such as Figure 3B The interface shown.

[0104] If the processor chip or system-level chip of the electronic device has the rounded corner synthesis function, assuming that the number of rounded corner synthesis channels in HWC is 2 and the number of general synthesis channels is 4, SurfaceFlinger can call 2 rounded corner synthesis channels and 3 general synthesis channels in HWC to synthesize layer A11, layer A12, layer A13, layer A14 and layer A15. Layer A11 and layer A15 use 2 rounded corner synthesis channels accordingly, and layer A12, layer A13 and layer A14 use 3 general synthesis channels accordingly.

[0105] If the processor chip or system-level chip of the electronic device does not have the rounded corner synthesis function. Assuming that the number of general synthesis channels in HWC is 4, Figure 3B Five layers are shown, which exceed the layer synthesis capability of HWC, that is, it is impossible to synthesize layer A11, layer A12, layer A13, layer A14 and layer A15 by hardware synthesis alone. HWC can notify SurfaceFlinger of the information of the layers that cannot be synthesized. SurfaceFlinger can transfer these layers that cannot be synthesized to the GPU for synthesis based on the information notification of HWC. The synthesis result of GPU can be passed to HWC, and HWC synthesizes the synthesis result of GPU with the rest of the layers, and sends the synthesized image frame to the display screen for display. The rules for HWC to select layers that cannot be synthesized can be existing rules or rules defined by electronic equipment manufacturers. The embodiments of the present application do not limit this. For example, the rules include: selecting layers that exceed the synthesis capability of HWC (HWC does not support the synthesis of layers with specific display effects); for layers that do not exceed the synthesis capability of HWC, they can be randomly selected or selected according to the layer category (for example, the rounded corner layer is selected as the layer that cannot be synthesized, and the other non-rounded corner layers that do not exceed the synthesis capability of HWC are synthesized by HWC).

[0106] For example, SurfaceFlinger can call the GPU to synthesize layer A12 and layer A13 to obtain a first synthesis result, and the HWC then synthesizes the first synthesis result with layer A11, layer A14 and layer A15 to obtain the final image frame sent to the display screen.

[0107] As an example, if the layer synthesis capability of HWC is exceeded, SurfaceFlinger can also transfer all layers to GPU for synthesis, and the synthesis result of GPU is then passed to HWC, and HWC sends the synthesis result to the display screen for display. For example, SurfaceFlinger can call GPU to redraw the contents of all layers to be synthesized (layer A11, layer A12, layer A13, layer A14 and layer A15) to a Frame buffer, and then send it to the display screen for display by HWC.

[0108] like Figure 3C As shown, it is assumed that the screen of the electronic device displays the interfaces of the first application and the third application. The third application may be a recording application. After the electronic device starts the recording application, a privacy indicator (a small dot) is displayed in the upper right corner of the display screen to remind the user that the electronic device is using the recording function.

[0109] and Figure 3B compared to, Figure 3C Draw the privacy indicator on the ScreenDecorOverlay layer. Figure 3C Four layers are shown: layer A21, layer A22, layer A23 and layer A24. Layer A21 is a layer shared by ScreenDecorOverlay and the privacy indicator, layer A22 is a layer of the status bar, layer A23 is a layer of the recording application, and layer A24 is a ScreenDecorOverlayBottom layer.

[0110] When the electronic device starts the recording application, SystemUI can obtain the information that the recording application is started, and draw and render the privacy indicator on the ScreenDecorOverlay layer while generating the ScreenDecorOverlay layer.

[0111] exist Figure 3C In the example, layers A21, A22, and A24 are generated by SystemUI. Figure 3A Layer A1 in the image, layer A21 also carries the image information of the privacy indicator, and layer A22 carries the image information of the status bar. SystemUI can pass the generated layers (layer A21, layer A22, layer A24) to SurfaceFlinger. Layer A23 is generated by the recording application, and layer A23 carries the image information of the recording application. The recording application can pass layer A23 to SurfaceFlinger.

[0112] After receiving layer A21, layer A22, layer A23, and layer A24, SurfaceFlinger may perform layer synthesis on layer A21, layer A22, layer A23, and layer A24, and may send the synthesized image frame to the display screen for display, so as to realize display such as Figure 3C The interface shown.

[0113] If the processor chip or system-level chip of the electronic device has the function of rounded corner synthesis, assuming that the number of rounded corner synthesis channels in HWC is 2 and the number of general synthesis channels is 4, because the ScreenDecorOverlay layer is drawn with a privacy indicator, the ScreenDecorOverlay layer changes from a single-channel color mode to a multi-channel color mode, and the rounded corner synthesis channel does not support layer synthesis in multi-channel color mode, that is, the rounded corner synthesis channel cannot be used to synthesize the rounded corner layer. In this case, SurfaceFlinger can not use the rounded corner synthesis function of the chip, and treat the ScreenDecorOverlay layer (with a privacy indicator drawn) and the ScreenDecorOverlayBottom layer as ordinary layers, and use the general synthesis channel for layer synthesis, that is, SurfaceFlinger can call the 4 general synthesis channels in HWC to synthesize layer A21, layer A22, layer A23 and layer A24.

[0114] If the processor chip or system-level chip of the electronic device does not have the rounded corner synthesis function, assuming that the number of general synthesis channels in HWC is 4, it can support the synthesis of four layers. SurfaceFlinger can directly call the 4 general synthesis channels in HWC to synthesize layer A21, layer A22, layer A23 and layer A24.

[0115] In order to further understand the synthesis method of the rounded corner layer of this application, the following is combined with Figure 4 The software process flow for creating and synthesizing rounded corner layers displayed on electronic devices is described in detail. Figure 4 Taking the example that the rounded corner layers of an electronic device include the ScreenDecorOverlay layer and the ScreenDecorOverlayBottom layer, the rounded corner layers are generated by a system-level application (SystemUI), and the processor chip or system-level chip of the electronic device has a rounded corner synthesis function, for the sake of convenience of description, the ScreenDecorOverlay layer is called rounded corner layer 1, and the ScreenDecorOverlayBottom layer is called rounded corner layer 2.

[0116] S401: When SystemUI is started, SystemUI sends window creation requests of rounded corner layer 1 and rounded corner layer 2 to the window manager service (WMS).

[0117] In some embodiments, the electronic device can automatically start SystemUI during the boot process, and SystemUI is used to display system interfaces such as the status bar, notification bar, drop-down menu, and navigation bar. After starting, SystemUI can initiate the creation of rounded corner layer 1 and rounded corner layer 2, so that when the electronic device turns on the screen, rounded corner layer 1, rounded corner layer 2 and another target layer can be synthesized to obtain an image frame to be displayed. The target layer can be a layer other than the rounded corner layer, which is used to display the content on the target layer on the display screen, such as an image, text, or table.

[0118] In some embodiments, the target layer may be created by other applications (non-system-level applications) installed on the electronic device, and the target layer carries the image information of the application. The target layer may also be created by SystemUI, and the target layer carries the image information of the status bar, the notification bar, the navigation bar, etc.

[0119] The process of creating the target layer is substantially the same as the process of creating the rounded corner layer. To avoid repetition, the present application embodiment only describes in detail the process of creating the rounded corner layer.

[0120] WMS can be used for window management, window animation management, surface management, and as a transfer station for the input system. After SystemUI starts the creation of rounded corner layer 1 and rounded corner layer 2, SystemUI can send window creation requests for rounded corner layer 1 and rounded corner layer 2 to WMS, so that WMS can create corresponding windows for rounded corner layer 1 and rounded corner layer 2, so that SystemUI can draw the layer content of rounded corner layer 1 and rounded corner layer 2 in the corresponding windows.

[0121] S402: The WMS creates corresponding windows for the rounded corner layer 1 and the rounded corner layer 2 based on the received window creation request.

[0122] In some embodiments, after receiving the window creation request for rounded corner layer 1 and rounded corner layer 2 sent by SystemUI, WMS can respond to the window creation request and create corresponding windows for rounded corner layer 1 and rounded corner layer 2. For example, WMS can create a first window for rounded corner layer 1 and a second window for rounded corner layer 2.

[0123] S403, WMS sends a window creation notification of rounded corner layer 1 and a window creation notification of rounded corner layer 2 to SurfaceFlinger.

[0124] In some embodiments, after creating corresponding windows for rounded corner layer 1 and rounded corner layer 2, WMS can send a window creation notification to SurfaceFlinger to facilitate SurfaceFlinger to create layers (Layer) corresponding to rounded corner layer 1 and rounded corner layer 2.

[0125] S404, SurfaceFlinger creates a first layer corresponding to rounded corner layer 1 based on the window creation notification of rounded corner layer 1, and creates a second layer corresponding to rounded corner layer 2 based on the window creation notification of rounded corner layer 2.

[0126] In some embodiments, after receiving a window creation notification of a layer sent by WMS, SurfaceFlinger can create a corresponding Layer for the layer. Layer is the basic operation unit for SurfaceFlinger to perform layer synthesis. There is a one-to-one correspondence between layers, that is, each layer of an application corresponds to a Layer in SurfaceFlinger, and each Layer corresponds to a buffer queue (BufferQueue). BufferQueue is used to connect the application and SurfaceFlinger. The application can be regarded as a producer of BufferQueue, and SurfaceFlinger can be regarded as a consumer of BufferQueue.

[0127] S405: WMS sends the handles of the first window and the second window to SystemUI.

[0128] In some embodiments, after creating corresponding windows for rounded corner layer 1 and rounded corner layer 2, WMS can send the window handles to SystemUI, so that SystemUI can subsequently determine the corresponding window based on the handles and draw the layer content in the corresponding window. For example, after WMS creates the first window for rounded corner layer 1, it sends the handle of the first window to SystemUI, and after WMS creates the second window for rounded corner layer 2, it sends the handle of the second window to SystemUI.

[0129] In some embodiments, S405 and S403 may be executed simultaneously or in a sequential order, which is not limited in the embodiments of the present application.

[0130] S406, SystemUI draws the layer content of rounded corner layer 1 based on the handle of the first window, and draws the layer content of rounded corner layer 2 based on the handle of the second window.

[0131] In some embodiments, SystemUI can operate the first window created by WMS based on the handle of the first window, and operate the second window created by WMS based on the handle of the second window, to achieve the drawing of rounded corner layer 1 and rounded corner layer 2. SystemUI operating a window may refer to drawing layer content in the window. For example, SystemUI can position the first window based on the handle of the first window, and then draw the layer content of rounded corner layer 1 in the first window, position the second window based on the handle of the second window, and then draw the layer content of rounded corner layer 2 in the second window.

[0132] S407, SystemUI updates the layer content of rounded corner layer 1 to SurfaceFlinger, and updates the layer content of rounded corner layer 2 to SurfaceFlinger.

[0133] SystemUI uses BufferQueue to pass the layer content of the drawn rounded corner layer to SurfaceFlinger. For example, SystemUI can use a BufferQueue to update the layer content of rounded corner layer 1 to the first layer created by SurfaceFlinger, and use another BufferQueue to update the layer content of rounded corner layer 2 to the second layer created by SurfaceFlinger, thereby generating rounded corner layer 1 and rounded corner layer 2 on the SurfaceFlinger side.

[0134] Generating rounded corner layer 1 on the SurfaceFlinger side can be understood as the first Layer carrying the layer content of rounded corner layer 1 drawn by SystemUI, and generating rounded corner layer 2 on the SurfaceFlinger side can be understood as the second Layer carrying the layer content of rounded corner layer 2 drawn by SystemUI.

[0135] S408, SurfaceFlinger sends rounded corner layer 1 and rounded corner layer 2 to HWC.

[0136] S409, SurfaceFlinger calls the software interface provided by HWC to set rounded corner labels for rounded corner layer 1 and rounded corner layer 2.

[0137] After SurfaceFlinger sends rounded corner layer 1 and rounded corner layer 2 to HWC, it can call the software interface provided by HWC (for example, an AIDL interface specifically used for rounded corner label setting) to set rounded corner labels for rounded corner layer 1 and rounded corner layer 2, so that HWC can subsequently determine which layer is the rounded corner layer based on the rounded corner label, and use the rounded corner synthesis channel to synthesize the rounded corner layers.

[0138] In some embodiments, if the processor chip or system-level chip of the electronic device has a rounded corner synthesis function, SurfaceFlinger can also call the software interface provided by HWC (for example, the setLayerAsMask interface) to set a rounded corner label for the rounded corner layer, and use the rounded corner label to identify rounded corner layer 1 and rounded corner layer 2 as rounded corner layers, so that HWC can use the rounded corner synthesis channel to synthesize rounded corner layer 1 and rounded corner layer 2.

[0139] If the processor chip or system-level chip of the electronic device does not have the rounded corner synthesis function, that is, HWC does not provide a software interface for setting rounded corner labels for the rounded corner layer, SurfaceFlinger only performs the operation of sending rounded corner layer 1 and rounded corner layer 2 to HWC.

[0140] S410, HWC synthesizes rounded corner layer 1 and rounded corner layer 2 using a rounded corner synthesis channel based on the rounded corner labels of rounded corner layer 1 and rounded corner layer 2.

[0141] SurfaceFlinger sets the rounded corner labels for rounded corner layer 1 and rounded corner layer 2 on the HWC side by calling the software interface provided by HWC. Based on the rounded corner labels of rounded corner layer 1 and rounded corner layer 2, HWC can determine that the currently received rounded corner layer 1 and rounded corner layer 2 are rounded corner layers, and then use a dedicated rounded corner synthesis channel to synthesize rounded corner layer 1 and rounded corner layer 2.

[0142] For electronic devices deployed with processor chips or system-level chips that do not have the rounded corner synthesis function, after generating rounded corner layer 1 and rounded corner layer 2 on the SurfaceFlinger side, SurfaceFlinger can directly send rounded corner layer 1 and rounded corner layer 2 to HWC, and HWC can subsequently use the general synthesis channel to synthesize rounded corner layer 1 and rounded corner layer 2, or use software synthesis to synthesize rounded corner layer 1 and rounded corner layer 2 (SurfaceFlinger calls GPU to synthesize rounded corner layer 1 and rounded corner layer 2).

[0143] exist Figure 4In the software processing flow shown, SurfaceFlinger calls the software interface provided by HWC to set rounded corner labels for rounded corner layer 1 and rounded corner layer 2, which does not support label clearing, which prompts HWC to still use a dedicated rounded corner synthesis channel to synthesize rounded corner layer 1 and rounded corner layer 2 in the scenario where the privacy indicator needs to be displayed. When the privacy indicator needs to be displayed and the privacy indicator needs to be drawn on the rounded corner layer, since the privacy indicator is in color, and HWC does not support layer synthesis in multi-channel color mode, that is, the rounded corner synthesis channel cannot be used to synthesize the rounded corner layer, and the rounded corner label set for the rounded corner layer will prompt HWC to use a dedicated rounded corner synthesis channel to synthesize the rounded corner layer, which may cause HWC to have abnormal layer synthesis.

[0144] Based on this, it is proposed Figure 5 and Figure 6 The software processing flow shown is used to solve the problem of abnormal layer synthesis that may occur in HWC with rounded corner synthesis function.

[0145] Let's combine Figure 5 The software process flow for creating and synthesizing rounded corner layers displayed on electronic devices is described in detail. Figure 5 The following is an example of an electronic device not displaying a privacy indicator after it is turned on.

[0146] S501: When SystemUI is started, SystemUI sends window creation requests for rounded corner layer 1 and rounded corner layer 2 to WMS.

[0147] Step S501 of the embodiment of the present application is similar to step S401 of the aforementioned embodiment, and will not be described again here to avoid repetition.

[0148] S502: The WMS creates corresponding windows for the rounded corner layer 1 and the rounded corner layer 2 based on the received window creation request.

[0149] Step S502 of the embodiment of the present application is similar to step S402 of the aforementioned embodiment, and will not be described again here to avoid repetition.

[0150] S503, WMS sends a window creation notification of rounded corner layer 1 and a window creation notification of rounded corner layer 2 to SurfaceFlinger.

[0151] Step S503 of the embodiment of the present application is similar to step S403 of the aforementioned embodiment, and will not be described again here to avoid repetition.

[0152] S504, SurfaceFlinger creates a first layer corresponding to rounded corner layer 1 based on the window creation notification of rounded corner layer 1 and sets a rounded corner label for the first layer, and creates a second layer corresponding to rounded corner layer 2 based on the window creation notification of rounded corner layer 2, and sets a rounded corner label for the second layer.

[0153] In some embodiments, after receiving a window creation notification of a layer sent by WMS, SurfaceFlinger can create a corresponding Layer for the layer. Layer is the basic operation unit for SurfaceFlinger to perform layer synthesis. After creating the Layer corresponding to the rounded corner layer, SurfaceFlinger can also set a rounded corner label for the Layer corresponding to the rounded corner layer. The rounded corner label is used to identify that the Layer is the Layer corresponding to the rounded corner layer, so that the Layer corresponding to the rounded corner layer can be specified to be synthesized through the rounded corner synthesis channel.

[0154] If the processor chip or system-level chip of the electronic device does not have the rounded corner synthesis function, SurfaceFlinger does not need to set a rounded corner label for the Layer corresponding to the rounded corner layer. For the non-rounded corner layer, SurfaceFlinger will not set a rounded corner label for the Layer either. The embodiment of the present application does not limit the form of the rounded corner label, as long as it can distinguish the Layer corresponding to the rounded corner layer from the Layer corresponding to the non-rounded corner layer. For example, SurfaceFlinger can distinguish the Layer corresponding to the rounded corner layer from the Layer corresponding to the non-rounded corner layer by configuring different attributes for the Layer corresponding to the rounded corner layer and the Layer corresponding to the non-rounded corner layer.

[0155] In some embodiments, WMS may also send a rounded corner label setting notification of the rounded corner layer to SurfaceFlinger, and SurfaceFlinger, in response to the rounded corner label setting notification, sets a rounded corner label for the Layer corresponding to the rounded corner layer.

[0156] S505: WMS sends the handles of the first window and the second window to SystemUI.

[0157] Step S505 of the embodiment of the present application is similar to step S405 of the aforementioned embodiment, and will not be described again here to avoid repetition.

[0158] S506, SystemUI draws the layer content of rounded corner layer 1 based on the handle of the first window, and draws the layer content of rounded corner layer 2 based on the handle of the second window.

[0159] Step S506 of the embodiment of the present application is similar to step S406 of the aforementioned embodiment, and will not be described again here to avoid repetition.

[0160] S507, SystemUI updates the layer content of rounded corner layer 1 to SurfaceFlinger, and updates the layer content of rounded corner layer 2 to SurfaceFlinger.

[0161] Step S507 of the embodiment of the present application is similar to step S407 of the aforementioned embodiment, and will not be described again here to avoid repetition.

[0162] S508, SurfaceFlinger sends the rounded corner layer 1 and the rounded corner layer 2 including the rounded corner tags to the HWC.

[0163] The rounded corner layer 1 and the rounded corner layer 2 generated on the SurfaceFlinger side both contain rounded corner tags. SurfaceFlinger can send the rounded corner layer 1 and the rounded corner layer 2 containing the rounded corner tags to HWC, so that HWC can use the rounded corner synthesis channel to synthesize the rounded corner layer 1 and the rounded corner layer 2.

[0164] S509, HWC synthesizes the rounded corner layer 1 and the rounded corner layer 2 using the rounded corner synthesis channel based on the rounded corner labels of the rounded corner layer 1 and the rounded corner layer 2.

[0165] Step S509 of the embodiment of the present application is similar to step S409 of the aforementioned embodiment, and will not be described again here to avoid repetition.

[0166] In situations where a privacy indicator needs to be displayed (for example, when a camera application or a recording application is turned on in an electronic device), the software process for creating and compositing rounded corner layers is as follows: Figure 6 As shown below. Figure 6 The software process flow for creating and synthesizing rounded corner layers displayed on electronic devices is described in detail.

[0167] S601: SystemUI sends window creation requests for rounded corner layer 1 and rounded corner layer 2 to WMS.

[0168] When an electronic device is turned on and running, it may start a camera application or a recording application in response to a user operation. In this case, it is generally necessary to display a privacy indicator in the upper right corner of the display screen to remind the user. Since the privacy indicator needs to be drawn on the rounded corner layer and will cause the HWC to be unable to use the rounded corner synthesis channel to synthesize the rounded corner layer, SystemUI can re-initiate the drawing of the rounded corner layer, that is, SystemUI sends the window creation request of rounded corner layer 1 and rounded corner layer 2 to WMS.

[0169] S602: The WMS creates corresponding windows for the rounded corner layer 1 and the rounded corner layer 2 based on the received window creation request.

[0170] Step S602 of the embodiment of the present application is similar to step S402 of the aforementioned embodiment, and will not be described again here to avoid repetition.

[0171] S603, WMS sends a window creation notification of rounded corner layer 1 and a window creation notification of rounded corner layer 2 to SurfaceFlinger.

[0172] Step S603 of the embodiment of the present application is similar to step S403 of the aforementioned embodiment, and will not be described again here to avoid repetition.

[0173] S604, SurfaceFlinger creates a first layer corresponding to rounded corner layer 1 based on the window creation notification of rounded corner layer 1 and sets a rounded corner label for the first layer, and creates a second layer corresponding to rounded corner layer 2 based on the window creation notification of rounded corner layer 2, and sets a rounded corner label for the second layer.

[0174] Step S605 of the embodiment of the present application is similar to step S504 of the aforementioned embodiment, and will not be described again here to avoid repetition.

[0175] S605: WMS sends the handles of the first window and the second window to SystemUI.

[0176] Step S605 of the embodiment of the present application is similar to step S405 of the aforementioned embodiment, and will not be described again here to avoid repetition.

[0177] S606, when SystemUI detects that a privacy indicator needs to be displayed, it sends a rounded corner label removal notification to SurfaceFlinger.

[0178] When it is detected that a privacy indicator needs to be displayed, since the privacy indicator is in color, the rounded corner layer with the privacy indicator drawn needs to be synthesized by a synthesis channel that supports multi-channel color mode. That is, the rounded corner synthesis channel cannot synthesize the rounded corner layer with the privacy indicator drawn. SystemUI removes the rounded corner label by sending a rounded corner label removal notification to SurfaceFlinger, so that subsequent HWC can use the general synthesis channel for synthesis.

[0179] S607, SurfaceFlinger removes the rounded corner label set for the first layer based on the rounded corner label removal notification, and removes the rounded corner label set for the second layer.

[0180] After receiving the rounded corner label removal notification sent by SystemUI, SurfaceFlinger can remove the rounded corner label set for the first layer and remove the rounded corner label set for the second layer in response to the rounded corner label removal notification.

[0181] For example, SurfaceFlinger can modify the properties of the first layer and the second layer in response to the rounded corner label removal notification, so that the properties of the first layer and the second layer are the same as the properties of the layer corresponding to the non-rounded corner layer, so that HWC will not use the rounded corner synthesis channel to synthesize the rounded corner layer 1 and the rounded corner layer 2 containing the privacy indicator, but use the general synthesis channel to synthesize the rounded corner layer 1 and the rounded corner layer 2 containing the privacy indicator, or use software synthesis to synthesize the rounded corner layer 1 and the rounded corner layer 2 containing the privacy indicator.

[0182] S608, SystemUI draws the layer content of rounded corner layer 1 and the layer content of the privacy indicator based on the handle of the first window, and draws the layer content of rounded corner layer 2 based on the handle of the second window.

[0183] In some embodiments, the situation in which the privacy indicator needs to be displayed is generally when the electronic device has started a camera application or a recording application. The SystemUI can determine whether the privacy indicator needs to be displayed by actively detecting (for example, detecting once every preset time) whether the currently started application is a camera application or a recording application. The electronic device can also configure the camera application or the recording application to actively send a notification message to the SystemUI when it is started, so that the SystemUI can determine the need to display the privacy indicator in response to the notification message.

[0184] Taking the drawing of the privacy indicator on the ScreenDecorOverlay layer as an example, when SystemUI detects that the privacy indicator needs to be displayed, it can draw the layer content of the rounded corner layer 1 and the privacy indicator based on the handle of the first window, and draw the layer content of the rounded corner layer 2 based on the handle of the second window.

[0185] In some embodiments, S608 and S606 may be executed in parallel or in a sequential order, which is not limited in the embodiments of the present application.

[0186] S609, SystemUI updates the layer content of rounded corner layer 1 and the layer content of the privacy indicator to SurfaceFlinger, and updates the layer content of rounded corner layer 2 to SurfaceFlinger.

[0187] For example, SystemUI can use a BufferQueue to update the layer content of rounded corner layer 1 and the layer content of the privacy indicator to the first Layer created by SurfaceFlinger, and use another BufferQueue to update the layer content of rounded corner layer 2 to the second Layer created by SurfaceFlinger, thereby generating rounded corner layer 1 and rounded corner layer 2 containing the privacy indicator on the SurfaceFlinger side.

[0188] Generating the rounded corner layer 1 including the privacy indicator on the SurfaceFlinger side can be understood as the first Layer carrying the layer content of the rounded corner layer 1 and the layer content of the privacy indicator drawn by SystemUI, and generating the rounded corner layer 2 on the SurfaceFlinger side can be understood as the second Layer carrying the layer content of the rounded corner layer 2 drawn by SystemUI.

[0189] S610, SurfaceFlinger sends rounded corner layer 1 and rounded corner layer 2 including the privacy indicator to HWC.

[0190] S611, HWC determines the synthesis method of rounded corner layer 1 and rounded corner layer 2 including the privacy indicator based on its own synthesis capability, and adopts the corresponding synthesis method to synthesize the rounded corner layer 1 and rounded corner layer 2 including the privacy indicator.

[0191] Because SurfaceFlinger removes the rounded corner labels of the first Layer and the second Layer, after HWC receives the rounded corner layer 1 and rounded corner layer 2 containing the privacy indicator sent by SurfaceFlinger, it will identify the rounded corner layer 1 and rounded corner layer 2 containing the privacy indicator as non-rounded corner layers, and will not use a dedicated rounded corner synthesis channel to synthesize the rounded corner layer 1 and rounded corner layer 2 containing the privacy indicator.

[0192] HWC can determine the synthesis method of rounded corner layer 1 and rounded corner layer 2 containing the privacy indicator based on its own synthesis capability, and the synthesis method includes a hardware synthesis method or a software synthesis method (synthesis using GPU) using the general synthesis channel of HWC. If the layers currently required to be synthesized do not exceed the synthesis capability of HWC (for example, the layers to be synthesized include rounded corner layers and other target layers, and the total number of layers does not exceed the synthesis capability of HWC), HWC can use the general synthesis channel to synthesize rounded corner layer 1 and rounded corner layer 2 containing the privacy indicator. If the layers currently required to be synthesized exceed the synthesis capability of HWC (for example, the total number of layers to be synthesized exceeds the synthesis capability of HWC), HWC will select some layers that cannot be synthesized and return them to SurfaceFlinger, which will call GPU to synthesize these layers that cannot be synthesized. These layers that cannot be synthesized may include rounded corner layers (rounded corner layers 1 and 2 containing privacy indicators).

[0193] In some embodiments, SurfaceFlinger or HWC may also specify that the synthesis method of the rounded corner layer 1 and the rounded corner layer 2 containing the privacy indicator is a software synthesis method, that is, the general synthesis channel of HWC is not used by default to synthesize the rounded corner layer 1 and the rounded corner layer 2 containing the privacy indicator, and HWC does not need to determine the synthesis method of the rounded corner layer 1 and the rounded corner layer 2 containing the privacy indicator based on its own synthesis capability.

[0194] For example, S510 can be modified as follows: SurfaceFlinger calls GPU to synthesize rounded corner layer 1 and rounded corner layer 2 containing the privacy indicator. Alternatively, S511 can be modified as follows: HWC returns information that rounded corner layer 1 and rounded corner layer 2 containing the privacy indicator cannot be synthesized to SurfaceFlinger, and SurfaceFlinger calls GPU to synthesize rounded corner layer 1 and rounded corner layer 2 containing the privacy indicator based on the information.

[0195] When the privacy indicator switches from being displayed to not being displayed (for example, the electronic device closes the camera application and / or the recording application, and no such application is currently running), Figure 6 The software process flow shown may also include the following interactive steps.

[0196] S612, when SystemUI detects that the display privacy indicator changes from needing to be displayed to not needing to be displayed, it sends a rounded corner label restoration notification to SurfaceFlinger, and updates the layer content of rounded corner layer 1 and the layer content of rounded corner layer 2 to SurfaceFlinger.

[0197] In some embodiments, the situation in which the display of the privacy indicator changes from being required to being displayed to not being required is generally when the electronic device has closed the camera application and / or the recording application, and the electronic device currently has no camera application or recording application running. SystemUI can determine whether it is necessary to continue to display the privacy indicator by actively detecting (for example, once every preset time) whether the currently running application includes a camera application or a recording application. The electronic device can also configure the camera application or the recording application to actively send a notification message to SystemUI when exiting, so that SystemUI can respond to the notification message to determine whether it is necessary to display the privacy indicator.

[0198] When it is determined that the privacy indicator does not need to be displayed, SystemUI sends a rounded corner label restoration notification to SurfaceFlinger, and updates the layer content of rounded corner layer 1 and the layer content of rounded corner layer 2 to SurfaceFlinger, so that the rounded corner layer generated on the SurfaceFlinger side does not include the privacy indicator.

[0199] S613, SurfaceFlinger sets a rounded corner label for the first layer based on the rounded corner label recovery notification, and sets a rounded corner label for the second layer.

[0200] After receiving the rounded corner label restoration notification sent by SystemUI, SurfaceFlinger sets a rounded corner label for the first Layer and a rounded corner label for the second Layer, so that when the privacy indicator does not need to be displayed, HWC can re-use the rounded corner synthesis channel to synthesize rounded corner layer 1 and rounded corner layer 2.

[0201] S614, SurfaceFlinger sends the rounded corner layer 1 and the rounded corner layer 2 including the rounded corner label to the HWC.

[0202] The rounded corner layer 1 and rounded corner layer 2 sent by SurfaceFlinger to HWC can be redrawn by SystemUI.

[0203] S615, HWC synthesizes rounded corner layer 1 and rounded corner layer 2 using a rounded corner synthesis channel based on the rounded corner labels of rounded corner layer 1 and rounded corner layer 2.

[0204] Step S615 of the embodiment of the present application is similar to step S509 of the aforementioned embodiment, and will not be described again here to avoid repetition.

[0205] In some embodiments, in order to solve the problem of abnormal layer composition that may occur in HWC with rounded corner composition function, an information transmission channel can be established between SurfaceFlinger and HWC, so that SurfaceFlinger can send labels or notification information of rounded corner layers to HWC. The composition strategy manager (CSM) in HWC can dynamically decide how to handle the rounded corner layer according to the notification information sent by SurfaceFlinger.

[0206] like Figure 7 , which is a schematic diagram of the software architecture of the interaction between SurfaceFlinger and HWC in a scenario where a privacy indicator needs to be displayed.

[0207] A transmission interface specifically used for transmitting identification information (first identification information / second identification information) is constructed between SurfaceFlinger and HWC. For example, the transmission interface can be an AIDL interface. When the privacy indicator needs to be displayed and the privacy indicator is drawn on the rounded corner layer, SystemUI can send a display notification of the privacy indicator to SurfaceFlinger. SurfaceFlinger creates a second identification information in response to the display notification of the privacy indicator. HWC can disable the rounded corner synthesis channel based on the second identification information, so that HWC will not use the rounded corner synthesis channel to synthesize the rounded corner layer, but use the general synthesis channel to synthesize the rounded corner layer. Alternatively, HWC does not disable the rounded corner synthesis channel, and sends all received layers to the general synthesis channel based on the second identification information. Similarly, HWC will not use the rounded corner synthesis channel to synthesize the rounded corner layer, which can solve the problem of layer synthesis abnormality caused by the inability of the rounded corner synthesis channel to synthesize the rounded corner layer drawn with the privacy indicator.

[0208] That is, when the privacy indicator needs to be displayed and the privacy indicator is drawn on the rounded corner layer, SurfaceFlinger can send the layer to be synthesized and the second identification information to the CSM of the HWC, and the CSM can distribute the two rounded corner layers and all non-rounded corner layers to the general synthesis channel for synthesis based on the second identification information. For example, SurfaceFlinger can send the layer to be synthesized and the second identification information to the HWC through two communication interfaces.

[0209] Taking HWC including four general synthesis channels as an example, assuming that the number of non-rounded corner layers is less than or equal to two, that is, the number of layers to be synthesized is less than or equal to four, and it does not exceed the synthesis capacity of the general synthesis channel of HWC, CSM distributes the two rounded corner layers and all non-rounded corner layers to the general synthesis channel for synthesis. Assuming that the number of non-rounded corner layers is greater than two, that is, the number of layers to be synthesized is greater than four, which exceeds the synthesis capacity of the general synthesis channel of HWC, CSM can select some layers from the received layers as layers that cannot be synthesized, and return the information of the layers that cannot be synthesized to SurfaceFlinger. SurfaceFlinger can call the GPU to synthesize these layers that cannot be synthesized. The synthesis results of the GPU can be passed to HWC, and HWC uses the general synthesis channel to synthesize the synthesis results of the GPU with the remaining layers.

[0210] like Figure 8 , which is a schematic diagram of the software architecture of the interaction between SurfaceFlinger and HWC in a scenario where the privacy indicator does not need to be displayed.

[0211] In the case where the privacy indicator does not need to be displayed, SystemUI can send a notification to cancel the display of the privacy indicator to SurfaceFlinger, and SurfaceFlinger creates the first identification information in response to the notification to cancel the display of the privacy indicator, and HWC uses the rounded corner synthesis channel to synthesize the rounded corner layer based on the first identification information. For example, the first identification information may include the identification of the rounded corner layer, and then HWC can locate the rounded corner layer based on the first identification information, and use the rounded corner synthesis channel dedicated to the rounded corner layer to synthesize the rounded corner layer.

[0212] exist Figure 8 In the , the layers sent by SurfaceFlinger to HWC include two rounded corner layers and at least one non-rounded corner layer. The non-rounded corner layer can be other layers except the rounded corner layer. The non-rounded corner layer can be drawn by SystemUI or other applications installed on the electronic device. HWC includes two rounded corner synthesis channels and m general synthesis channels, where m is a positive integer. The number of general synthesis channels included in the existing HWC is generally four. This application does not limit the number of general synthesis channels included in the HWC. Generally speaking, the more powerful the HWC chip, the more general synthesis channels it contains.

[0213] In HWC, CSM distributes layers. Taking the HWC including four general synthesis channels as an example, when there is no need to display the privacy indicator, in order to release the general synthesis channel of HWC for non-rounded corner layers, the rounded corner layers are synthesized using a dedicated rounded corner synthesis channel. SurfaceFlinger can send the layers to be synthesized and the first identification information to the CSM of HWC. Based on the first identification information, the CSM can distribute the two rounded corner layers to the two rounded corner synthesis channels for synthesis. If the number of non-rounded corner layers is less than or equal to four, that is, it does not exceed the synthesis capacity of the general synthesis channel of HWC, the CSM will distribute all non-rounded corner layers to the general synthesis channel for synthesis.

[0214] In some embodiments, if the number of non-rounded corner layers sent by SurfaceFlinger to HWC is greater than four, that is, it exceeds the synthesis capability of the general synthesis channel of HWC, CSM can also select a part of the received non-rounded corner layers as layers that cannot be synthesized, and send the information of the layers that cannot be synthesized back to SurfaceFlinger. SurfaceFlinger can call GPU to synthesize these layers that cannot be synthesized, and the synthesis results of GPU can be passed to HWC, which then uses the general synthesis channel to synthesize the synthesis results of GPU with the remaining layers.

[0215] See also Fig. 9A The interface display method provided by the embodiment of the present application is shown in FIG. The interface display method can be applied to an electronic device, the electronic device includes a processing chip and a display screen, the processing chip can refer to a central processing unit chip or a system-level chip, and the processing chip includes a general synthesis channel for layer synthesis and a rounded corner synthesis channel dedicated to the rounded corner layer. The interface display method includes:

[0216] S91: receiving a first operation from a user.

[0217] In some embodiments, the electronic device is installed with a first application, and the icon of the first application can be displayed on the desktop of the electronic device. The first operation can refer to clicking the icon of the first application displayed on the desktop of the electronic device. The first application can be an application that has a privacy indicator display requirement. For example, the first application can be a camera application or a recording application. For a camera application, the electronic device generally displays the privacy indicator when the display screen displays the camera interface. When the camera application is closed or the camera application is switched to the background, the privacy indicator disappears; for a recording application, the electronic device generally displays the privacy indicator when the recording is started. At this time, even if the recording application is switched to the background, the privacy indicator will not disappear. When the recording is stopped, the privacy indicator disappears.

[0218] S92: In response to the first operation, start a first application.

[0219] In some embodiments, the user clicks on the icon of the first application, and the electronic device can launch the first application in response to the click operation.

[0220] S93, drawing a first rounded corner layer, where the first rounded corner layer includes a privacy indicator.

[0221] S94, drawing an application layer including image information of the first application.

[0222] During the process of launching the first application, by drawing a first rounded corner layer including a privacy indicator and drawing an application layer including image information of the first application, the first rounded corner layer and the application layer can be subsequently synthesized to obtain an image frame for display on the display screen, that is, after launching the first application, the first application interface can be displayed on the display screen.

[0223] In some embodiments, the rounded corner layer is generally drawn by a system-level application (SystemUI), and SystemUI can be started when the electronic device is turned on, that is, the first rounded corner layer including the privacy indicator can be drawn by the thread of SystemUI, and the application map including the image information of the first application can be drawn by the thread of the first application. The first rounded corner layer can include a ScreenDecorOverlay layer and a ScreenDecorOverlayBottom layer, and the privacy indicator can be drawn on the ScreenDecorOverlay layer.

[0224] In some embodiments, step S93 and step S94 may be executed in parallel, or step S94 may be executed before step S93.

[0225] S95, synthesize the first rounded corner layer and the application layer using a general synthesis channel to obtain an image frame.

[0226] Since the first rounded corner layer includes a privacy indicator, in order to avoid the layer synthesis abnormality problem caused by the rounded corner synthesis channel being unable to synthesize the rounded corner layer with the privacy indicator drawn on it, a general synthesis channel is used to synthesize the first rounded corner layer and the application layer to obtain an image frame.

[0227] For example, the thread of the first application can pass the application layer containing the image information of the first application to SurfaceFlinger, and the thread of SystemUI passes the first rounded corner layer containing the privacy indicator to SurfaceFlinger. SurfaceFlinger uses a general synthesis channel to synthesize the first rounded corner layer and the application layer to obtain an image frame.

[0228] In some embodiments, when SystemUI determines that it is necessary to draw the first rounded corner layer including the privacy indicator, or in the process of drawing the first rounded corner layer including the privacy indicator, it can create a display notification of the privacy indicator to facilitate the subsequent notification of SurfaceFlinger to use the general synthesis channel to synthesize the rounded corner layer, thereby avoiding the layer synthesis abnormality caused by the inability of the rounded corner synthesis channel to synthesize the rounded corner layer drawn with the privacy indicator.

[0229] For example, when the layer to be synthesized includes a rounded corner tag, HWC uses the rounded corner synthesis channel to synthesize the layer to be synthesized. SurfaceFlinger can remove the rounded corner tag set for the rounded corner layer in response to the display notification of the privacy indicator. SurfaceFlinger sends the first rounded corner layer and the application layer that do not include the rounded corner tag to HWC for synthesis. The first rounded corner layer that does not include the rounded corner tag will be considered by HWC as a non-rounded corner layer, and then HWC will not use the rounded corner synthesis channel to synthesize the rounded corner layer, but use the general synthesis channel to synthesize the first rounded corner layer and the application layer.

[0230] For example, SurfaceFlinger can also create a second identification information in response to the display notification of the privacy indicator, and HWC disables the rounded corner synthesis channel based on the second identification information, or does not disable the rounded corner synthesis channel, and sends all received layers to the general synthesis channel based on the second identification information, so that HWC does not use the rounded corner synthesis channel to synthesize the rounded corner layer, and uses the general synthesis channel to synthesize the first rounded corner layer and the application layer. In order to realize the transmission of identification information, a transmission interface dedicated to transmitting the first identification information or the second identification information can be constructed between SurfaceFlinger and HWC.

[0231] In some embodiments, when the synthesis capability of the general synthesis channel of the HWC meets the synthesis requirements of the first rounded corner layer and the application layer, the general synthesis channel is directly used to synthesize the first rounded corner layer and the application layer, which can reduce the power consumption of the electronic device and improve the display performance of the electronic device. When the synthesis capability of the general synthesis channel does not meet the requirements of the first rounded corner layer and the application layer (for example, the number of layers to be synthesized exceeds the synthesis capability of the general synthesis channel, or the layers to be synthesized include layers with specific display effects that cannot be synthesized by the general synthesis channel), the first rounded corner layer and the application layer can be synthesized by mixing the GPU and the general synthesis channel. Compared with simply using the GPU for layer synthesis, the layer synthesis efficiency is higher and the device power consumption is lower.

[0232] In some embodiments, after launching the first application, the electronic device may also receive a second operation from the user, where the second operation may refer to an operation of exiting the first application, where the operation of exiting the first application may refer to switching the first application to the background or ending the running of the first application; the electronic device may exit the first application in response to the second operation; SystemUI draws a second rounded corner layer, where the second rounded corner layer does not include a privacy indicator, and SurfaceFlinger may use a rounded corner synthesis channel to synthesize the second rounded corner layer.

[0233] For example, SystemUI can create a notification to cancel the display of the privacy indicator during the process of drawing the second rounded corner layer; SystemUI can send the notification to cancel the display of the second rounded corner layer and the privacy indicator to SurfaceFlinger, and SurfaceFlinger responds to the notification to cancel the display of the privacy indicator and uses the rounded corner synthesis channel to synthesize the second rounded corner layer.

[0234] For example, SurfaceFlinger adds a rounded corner label to the rounded corner layer in response to the notification of canceling the display of the privacy indicator, and SurfaceFlinger sends a second rounded corner layer containing the rounded corner label to HWC, and HWC can synthesize the second rounded corner layer based on the rounded corner label of the second rounded corner layer using the rounded corner synthesis channel.

[0235] For example, SurfaceFlinger creates first identification information in response to a notification to cancel display of the privacy indicator. The first identification information may include an identification of the second rounded corner layer. SurfaceFlinger can send the second rounded corner layer, other application layers (application layers other than the first application) and the first identification information to HWC. HWC can synthesize the second rounded corner layer using the rounded corner synthesis channel based on the first identification information.

[0236] S96, displaying the image frame on a display screen.

[0237] After the image frame is synthesized, the image frame can be sent for display, and the image frame can be displayed on the display screen, so that the user can see the interface of the first application on the display screen after starting the first application.

[0238] See also Fig. 9B The interface display method provided by the embodiment of the present application is shown in FIG. The interface display method can be applied to an electronic device, the electronic device includes a processing chip and a display screen, the processing chip can refer to a central processing unit chip or a system-level chip, the processing chip includes a general synthesis channel for layer synthesis and a rounded corner synthesis channel dedicated to the rounded corner layer, and the electronic device is installed with a camera application. The interface display method includes:

[0239] S901: Receive a first operation from a user.

[0240] The first operation may refer to a click operation on an icon of a camera application displayed on the desktop of the electronic device.

[0241] S902: In response to a first operation, start a camera application.

[0242] In some embodiments, the user clicks on the icon of the camera application, and the electronic device can launch the camera application in response to the click operation.

[0243] S903, drawing a first rounded corner layer, where the first rounded corner layer includes a privacy indicator.

[0244] S904, drawing a camera preview layer of the camera application.

[0245] During the process of launching the camera application, by drawing a first rounded corner layer including a privacy indicator and a camera preview layer including image information of a preview interface of the camera application, the first rounded corner layer and the camera preview layer can be subsequently synthesized to obtain a camera preview interface for display on the display screen, that is, after launching the camera application, the camera preview interface can be displayed on the display screen.

[0246] In some embodiments, step S903 and step S904 may be executed in parallel, or step S904 may be executed before step S903.

[0247] S905, using a general synthesis channel to synthesize the first rounded corner layer and the camera preview layer to obtain a camera preview interface.

[0248] Since the first rounded corner layer includes a privacy indicator, in order to avoid the layer synthesis abnormality problem caused by the rounded corner synthesis channel being unable to synthesize the rounded corner layer with the privacy indicator drawn on it, a general synthesis channel is used to synthesize the first rounded corner layer and the camera preview layer to obtain the camera preview interface.

[0249] S906, displaying a camera preview interface on the display screen.

[0250] After the camera preview interface is synthesized, it can be displayed on the display screen, so that the user can see the camera preview interface on the display screen after starting the camera application.

[0251] See also Fig. 9C The interface display method provided by the embodiment of the present application is shown in FIG. The interface display method can be applied to an electronic device, the electronic device includes a processing chip and a display screen, the processing chip can refer to a central processing unit chip or a system-level chip, the processing chip includes a general synthesis channel for layer synthesis and a rounded corner synthesis channel dedicated to the rounded corner layer, and the electronic device is installed with a recording application. The interface display method includes:

[0252] S911, receiving a first operation from a user.

[0253] The first operation may refer to clicking on the icon of the recording application displayed on the desktop of the electronic device, and after entering the recording application interface, starting the recording operation of the recording application.

[0254] S912: In response to the first operation, start recording of the recording application.

[0255] In some embodiments, the electronic device may initiate recording of a recording application in response to the first operation.

[0256] S913, drawing a first rounded corner layer, where the first rounded corner layer includes a privacy indicator.

[0257] S914, drawing a recording layer of the recording application.

[0258] In the process of starting the recording of the recording application, by drawing the first rounded corner layer including the privacy indicator and drawing the recording layer including the image information of the recording interface of the recording application, it is convenient to subsequently synthesize the first rounded corner layer and the recording layer to obtain the recording interface for display on the display screen, that is, after starting the recording of the recording application, the recording interface (for example, Figure 3C The recording interface shown).

[0259] In some embodiments, step S913 and step S914 may be executed in parallel, or step S914 may be executed before step S913.

[0260] S915, synthesize the first rounded corner layer and the recording layer using a general synthesis channel to obtain a recording interface.

[0261] Since the first rounded corner layer includes a privacy indicator, in order to avoid the layer synthesis abnormality problem caused by the rounded corner synthesis channel being unable to synthesize the rounded corner layer with the privacy indicator drawn on it, a general synthesis channel is used to synthesize the first rounded corner layer and the recording layer to obtain a recording interface.

[0262] S916, displaying the recording interface on the display screen.

[0263] After the recording interface is synthesized, the recording interface can be displayed on the display screen, so that the user can see the recording interface on the display screen after starting the recording of the recording application.

[0264] See also Fig.10 As shown, it is a software architecture diagram of the electronic device provided in the embodiment of the present application. The layered architecture divides the software into several layers, and each layer has a clear role and division of labor. The layers communicate with each other through software interfaces. The following is an example of an Android operating system installed in an electronic device, but the present application is not limited to this, and other types of operating systems can also be installed in the electronic device.

[0265] For example, the Android system is divided into four layers, which are, from top to bottom, an application layer 101 , a framework layer 102 , an Android runtime and system library 103 , a kernel layer 104 , and a hardware layer 105 .

[0266] The application layer can include a series of application packages. For example, an application package can include applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, short message, device control service, etc.

[0267] The framework layer provides an application programming interface (API) and a programming framework for the applications in the application layer. The application framework layer includes some predefined functions. For example, the application framework layer may include a window manager, a content provider, a view system, a phone manager, a resource manager, a notification manager, etc.

[0268] Among them, the window manager is used to manage window programs. The window manager can obtain the size of the display screen, determine whether there is a status bar, lock the screen, capture the screen, etc. The content provider is used to store and obtain data and make the data accessible to the application. The data may include video, images, audio, calls made and received, browsing history and bookmarks, phone books, etc. The view system includes visual controls, such as controls for displaying text, controls for displaying pictures, etc. The view system can be used to build applications. The display interface can be composed of one or more views. For example, a display interface including a text notification icon can include a view for displaying text and a view for displaying pictures. The phone manager is used to provide communication functions for electronic devices. For example, the management of call status (including connected, hung up, etc.). The resource manager provides various resources for the application, such as localized strings, icons, pictures, layout files, video files, etc. The notification manager enables the application to display notification information in the status bar, which can be used to convey notification-type messages and can disappear automatically after a short stay without user interaction. For example, the notification manager is used to notify the completion of downloads, message reminders, etc. The notification manager can also be a notification that appears in the top status bar of the system in the form of an icon or scroll bar text, such as a notification of an application running in the background, or a notification that appears on the screen in the form of a dialog window. For example, a text message is prompted in the status bar, a prompt sound is emitted, an electronic device vibrates, an indicator light flashes, etc.

[0269] Android Runtime includes core libraries and virtual machines. Android runtime is responsible for scheduling and management of the Android system. The core library contains two parts: one is the function that the Java language needs to call, and the other is the Android core library.

[0270] The application layer and framework layer run in the virtual machine. The virtual machine executes the java files of the application layer and framework layer as binary files. The virtual machine is used to perform functions such as object life cycle management, stack management, thread management, security and exception management, and garbage collection.

[0271] The system library may include multiple functional modules, such as a surface manager, a media library, a 3D graphics processing library (such as OpenGL ES), a 2D graphics engine (such as SGL), etc.

[0272] Among them, the surface manager is used to manage the display subsystem and provide fusion of 2D and 3D layers for multiple applications. The media library supports playback and recording of multiple commonly used audio and video formats, as well as static image files. The media library can support multiple audio and video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc. The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, synthesis, and layer processing. The 2D graphics engine is a drawing engine for 2D drawing.

[0273] The kernel layer is the layer between hardware and software. The kernel layer contains at least display driver, camera driver, audio driver, and sensor driver.

[0274] The kernel layer is the core of the operating system of an electronic device. It is the first layer of software expansion based on hardware. It provides the most basic functions of the operating system and is the basis for the operation of the operating system. It is responsible for managing the system's processes, memory, device drivers, files, and network systems, and determines the performance and stability of the system. For example, the kernel can determine the operating time of an application on a certain part of the hardware.

[0275] The kernel layer includes programs that are closely related to the hardware, such as interrupt handlers, device drivers, etc. It also includes basic, common, and high-frequency modules, such as clock management modules, process scheduling modules, etc. It also includes key data structures. The kernel layer can be set in the processor or solidified in the internal memory.

[0276] The hardware layer is the hardware of the electronic device, and the hardware layer at least includes a display screen.

[0277] See also Fig.11 The figure is a schematic diagram of an application scenario of the interface display method provided in one embodiment of the present application.

[0278] After the electronic device is started, in the application layer 101, SystemUI sends a window creation request for the rounded corner layer to the WMS of the framework layer 102. In the framework layer 102, WMS creates a corresponding window for the rounded corner layer and returns the window handle to SystemUI. WMS can also send a window creation notification for the rounded corner layer to SurfaceFlinger. SurfaceFlinger creates a layer corresponding to the rounded corner layer based on the window creation notification and sets a rounded corner label for the layer. In the application layer 101, SystemUI draws and renders the layer content of the rounded corner layer based on the window handle, and updates the layer content of the rendered rounded corner layer to SurfaceFlinger.

[0279] In the framework layer 102, SurfaceFlinger sends the rounded corner layer containing the rounded corner label to the hardware synthesis service (Hardware Composer HAL) of the kernel layer 104 for synthesis. In the kernel layer 104, the Hardware Composer HAL can call the rounded corner synthesis channel to synthesize the rounded corner layer, and transmit the synthesis result (including the rounded corner layer and at least one target layer) to the display layer of the display screen for caching. In the hardware layer 105, the display layer of the display screen can display the user interface under the display driver of the kernel layer 104. For example, SurfaceFlinger can transmit the current screen refresh rate of the display screen to the display driver, and the display driver can drive the display layer to refresh the display based on the screen refresh rate. At this time, the user can see the user interface with rounded corner jaggies occlusion on the display screen.

[0280] See also Fig.12 The figure is a schematic diagram of an application scenario of an interface display method provided in another embodiment of the present application.

[0281] In the scenario where the privacy indicator needs to be displayed, at the application layer 101, SystemUI sends a window creation request for the rounded corner layer to the WMS of the framework layer 102. At the framework layer 102, WMS creates a corresponding window for the rounded corner layer and returns the window handle to SystemUI. WMS can also send a window creation notification for the rounded corner layer to SurfaceFlinger. SurfaceFlinger creates a layer corresponding to the rounded corner layer based on the window creation notification and sets a rounded corner label for the layer. At the application layer 101, SystemUI detects that the privacy indicator needs to be displayed. SystemUI sends a rounded corner label removal notification to SurfaceFlinger, and draws and renders the layer content of the rounded corner layer and the layer content of the privacy indicator based on the window handle. SystemUI can also update the rendered layer content of the rounded corner layer and the layer content of the privacy indicator to SurfaceFlinger.

[0282] In the framework layer 102, SurfaceFlinger removes the rounded corner label set for the Layer corresponding to the rounded corner layer based on the rounded corner label removal notification, and sends the rounded corner layer containing the privacy indicator to the HardwareComposer HAL of the kernel layer 104 for synthesis. In the kernel layer 104, the Hardware Composer HAL can call a general synthesis channel or use software synthesis to synthesize the rounded corner layer, and transmit the synthesis result (including the rounded corner layer and at least one target layer) to the display layer of the display screen for caching. In the hardware layer 105, the display layer of the display screen can display the user interface under the display driver of the kernel layer 104. At this time, the user can see the user interface containing the privacy indicator and the rounded corner jaggies occlusion on the display screen.

[0283] When the privacy indicator is switched from being displayed to not being displayed, at the application layer 101, SystemUI sends a rounded corner label recovery notification to SurfaceFlinger of the framework layer 102, and updates the layer content of the rounded corner layer (excluding the privacy indicator) to SurfaceFlinger. At the framework layer 102, SurfaceFlinger sets a rounded corner label for the Layer corresponding to the rounded corner layer based on the rounded corner label recovery notification, and sends the rounded corner layer containing the rounded corner label to the Hardware Composer HAL of the kernel layer 104 for synthesis. At the kernel layer 104, the Hardware Composer HAL can call the rounded corner synthesis channel to synthesize the rounded corner layer, and transmit the synthesis result (including the rounded corner layer and at least one target layer) to the display layer of the display screen for caching. At the hardware layer 105, the display layer of the display screen can display the user interface under the display driver of the kernel layer 104. At this time, the user can see the user interface that does not contain the privacy indicator and is occluded by rounded corners on the display screen.

[0284] See also Fig.13 The figure is a schematic diagram of an application scenario of an interface display method provided in another embodiment of the present application.

[0285] In the scenario where the privacy indicator needs to be displayed, at the application layer 101, SystemUI sends a window creation request for the rounded corner layer to the WMS of the framework layer 102. At the framework layer 102, WMS creates a corresponding window for the rounded corner layer and returns the window handle to SystemUI. WMS can also send a window creation notification for the rounded corner layer to SurfaceFlinger, and SurfaceFlinger creates a layer corresponding to the rounded corner layer based on the window creation notification. At the application layer 101, SystemUI detects that the privacy indicator needs to be displayed. SystemUI sends a privacy indicator display notification to SurfaceFlinger, and draws and renders the layer content of the rounded corner layer and the layer content of the privacy indicator based on the window handle. SystemUI can also update the rendered layer content of the rounded corner layer and the layer content of the privacy indicator to SurfaceFlinger.

[0286] In the framework layer 102, SurfaceFlinger displays a notification based on the privacy indicator, and sends the rounded corner layer containing the privacy indicator and the second identification information to the Hardware Composer HAL of the kernel layer 104. In the kernel layer 104, the Hardware Composer HAL can call a general synthesis channel or synthesize the rounded corner layer using software synthesis based on the second identification information, and transmit the synthesis result (including the rounded corner layer and at least one target layer) to the display layer of the display screen for caching. In the hardware layer 105, the display layer of the display screen can display the user interface under the display driver of the kernel layer 104. At this time, the user can see the user interface containing the privacy indicator and occluded with rounded corners on the display screen.

[0287] When the privacy indicator is switched from being displayed to not being displayed, at the application layer 101, SystemUI sends a notification that the privacy indicator is not displayed to SurfaceFlinger of the framework layer 102, and updates the layer content of the rounded corner layer (excluding the privacy indicator) to SurfaceFlinger. At the framework layer 102, SurfaceFlinger sends the rounded corner layer and the first identification information to the Hardware Composer HAL of the kernel layer 104 based on the notification that the privacy indicator is not displayed. At the kernel layer 104, the Hardware Composer HAL can call the rounded corner synthesis channel to synthesize the rounded corner layer based on the first identification information, and transmit the synthesis result (including the rounded corner layer and at least one target layer) to the display layer of the display screen for caching. At the hardware layer 105, the display layer of the display screen can display the user interface under the display driver of the kernel layer 104. At this time, the user can see the user interface that does not contain the privacy indicator and is occluded with rounded corners on the display screen.

[0288] See also Fig.14 As shown, the electronic device 100 involved in the embodiment of the present application is introduced below. The electronic device in the embodiment of the present application can be a mobile phone, a tablet computer, a desktop, a laptop, a handheld computer, a notebook computer, an ultra-mobile personal computer (ultra-mobile personal computer, UMPC), a netbook, a cellular phone, a personal digital assistant (personal digital assistant, PDA), an augmented reality (augmented reality, AR)\virtual reality (virtual reality, VR) device and other devices including a touch screen. The embodiment of the present application does not impose any special restrictions on the specific form of the electronic device. Please refer to Fig.14 , Fig.14 It is a schematic diagram of the structure of the electronic device 100 provided in an embodiment of the present application.

[0289] 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, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a button 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 pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.

[0290] It is to be understood that the structure illustrated in the embodiment of the present invention does not constitute a specific limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may include more or fewer components than shown in the figure, or combine some components, or separate some components, or arrange the components differently. The components shown in the figure may be implemented in hardware, software, or a combination of software and hardware.

[0291] The processor 110 may include one or more processing units, for example, the processor 110 may include an application processor (AP), a modem processor, a graphics processor (GPU), an image signal processor (ISP), a controller, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU), etc. Different processing units may be independent devices or integrated into one or more processors.

[0292] The controller can generate operation control signals according to the instruction operation code and timing signal to complete the control of instruction fetching and execution.

[0293] The processor 110 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory may store instructions or data that the processor 110 has just used or cyclically used. If the processor 110 needs to use the instructions or data again, it may be directly called from the memory. This avoids repeated access, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.

[0294] In some embodiments, the processor 110 may include one or more interfaces. The interface may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.

[0295] The I2C interface is a bidirectional synchronous serial bus, including a serial data line (SDA) and a serial clock line (SCL). In some embodiments, the processor 110 may include multiple groups of I2C buses. The processor 110 may be coupled to the touch sensor 180K, the charger, the flash, the camera 193, etc. through different I2C bus interfaces. For example: the processor 110 may be coupled to the touch sensor 180K through the I2C interface, so that the processor 110 communicates with the touch sensor 180K through the I2C bus interface to realize the touch function of the electronic device 100.

[0296] The I2S interface can be used for audio communication. In some embodiments, the processor 110 can include multiple I2S buses. The processor 110 can be coupled to the audio module 170 via the I2S bus to achieve communication between the processor 110 and the audio module 170. In some embodiments, the audio module 170 can transmit an audio signal to the wireless communication module 160 via the I2S interface to achieve the function of answering a call through a Bluetooth headset.

[0297] The PCM interface can also be used for audio communication, sampling, quantizing and encoding analog signals. In some embodiments, the audio module 170 and the wireless communication module 160 can be coupled via a PCM bus interface. In some embodiments, the audio module 170 can also transmit audio signals to the wireless communication module 160 via the PCM interface to realize the function of answering calls via a Bluetooth headset. Both the I2S interface and the PCM interface can be used for audio communication.

[0298] The UART interface is a universal serial data bus for asynchronous communication. The bus can be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication. In some embodiments, the UART interface is generally used to connect the processor 110 and the wireless communication module 160. For example, the processor 110 communicates with the Bluetooth module in the wireless communication module 160 through the UART interface to implement the Bluetooth function. In some embodiments, the audio module 170 can transmit an audio signal to the wireless communication module 160 through the UART interface to implement the function of playing music through a Bluetooth headset.

[0299] The MIPI interface can be used to connect the processor 110 with peripheral devices such as the display screen 194 and the camera 193. The MIPI interface includes a camera serial interface (CSI), a display serial interface (DSI), etc. In some embodiments, the processor 110 and the camera 193 communicate via the CSI interface to implement the shooting function of the electronic device 100. The processor 110 and the display screen 194 communicate via the DSI interface to implement the display function of the electronic device 100.

[0300] The GPIO interface can be configured by software. The GPIO interface can be configured as a control signal or as a data signal. In some embodiments, the GPIO interface can be used to connect the processor 110 with the camera 193, the display 194, the wireless communication module 160, the audio module 170, the sensor module 180, etc. The GPIO interface can also be configured as an I2C interface, an I2S interface, a UART interface, a MIPI interface, etc.

[0301] The USB interface 130 is an interface that complies with the USB standard specification, and specifically can be a Mini USB interface, a Micro USB interface, a USB Type C interface, etc. The USB interface 130 can be used to connect a charger to charge the electronic device 100, and can also be used to transfer data between the electronic device 100 and a peripheral device. It can also be used to connect headphones to play audio through the headphones. The interface can also be used to connect other electronic devices 100, such as AR devices, etc.

[0302] It is understandable that the interface connection relationship between the modules illustrated in the embodiment of the present invention is only a schematic illustration and does not constitute a structural limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may also adopt different interface connection methods in the above embodiments, or a combination of multiple interface connection methods.

[0303] The charging management module 140 is used to receive charging input from a charger. The charger may be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 may receive charging input from a wired charger through the USB interface 130. In some wireless charging embodiments, the charging management module 140 may receive wireless charging input through a wireless charging coil of the electronic device 100. While the charging management module 140 is charging the battery 142, it may also power the electronic device 100 through the power management module 141.

[0304] The power management module 141 is used to connect 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, and supplies power to the processor 110, the internal memory 121, the display screen 194, the camera 193, and the wireless communication module 160. The power management module 141 can also be used to monitor parameters such as battery capacity, battery cycle number, battery health status (leakage, impedance), etc. In some other embodiments, the power management module 141 can also be set in the processor 110. In other embodiments, the power management module 141 and the charging management module 140 can also be set in the same device.

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

[0306] Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in electronic device 100 can be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve the utilization of antennas. For example, antenna 1 can be reused as a diversity antenna for a wireless local area network. In some other embodiments, the antenna can be used in combination with a tuning switch.

[0307] The mobile communication module 150 can provide solutions for wireless communications including 2G / 3G / 4G / 5G, etc., applied to the electronic device 100. The mobile communication module 150 may include at least one filter, a switch, a power amplifier, a low noise amplifier (LNA), etc. The mobile communication module 150 can receive electromagnetic waves from the antenna 1, and filter, amplify, and process the received electromagnetic waves, and transmit them to the modulation and demodulation processor for demodulation. The mobile communication module 150 can also amplify the signal modulated by the modulation and demodulation processor, and convert it into electromagnetic waves for radiation through the antenna 1. In some embodiments, at least some of the functional modules of the mobile communication module 150 can be set in the processor 110. In some embodiments, at least some of the functional modules of the mobile communication module 150 can be set in the same device as at least some of the modules of the processor 110.

[0308] The modem processor may include a modulator and a demodulator. Among them, the modulator is used to modulate the low-frequency baseband signal to be sent into a medium-high frequency signal. The demodulator is used to demodulate the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After the low-frequency baseband signal is processed by the baseband processor, it is passed to the application processor. The application processor outputs a sound signal through an audio device (not limited to a speaker 170A, a receiver 170B, etc.), or displays an image or video through a display screen 194. In some embodiments, the modem processor may be an independent device. In other embodiments, the modem processor may be independent of the processor 110 and be set in the same device as the mobile communication module 150 or other functional modules.

[0309] The wireless communication module 160 can provide wireless communication solutions including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared (IR), etc., which are applied to the electronic device 100. The wireless communication module 160 can be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via the antenna 2, modulates the frequency of the electromagnetic wave signal and performs filtering, and sends the processed signal to the processor 110. The wireless communication module 160 can also receive the signal to be sent from the processor 110, modulate the frequency of it, amplify it, and convert it into electromagnetic waves for radiation through the antenna 2.

[0310] In some embodiments, the antenna 1 of the electronic device 100 is coupled to the mobile communication module 150, and the antenna 2 is coupled to the wireless communication module 160, so that the electronic device 100 can communicate with the network and other devices through wireless communication technology. The wireless communication technology may include global system for mobile communications (GSM), general packet radio service (GPRS), code division multiple access (CDMA), wideband code division multiple access (WCDMA), time-division code division multiple access (TD-SCDMA), long term evolution (LTE), BT, GNSS, WLAN, NFC, FM, and / or IR technology. The GNSS may include a global positioning system (GPS), a global navigation satellite system (GLONASS), a Beidou navigation satellite system (BDS), a quasi-zenith satellite system (QZSS) and / or a satellite based augmentation system (SBAS).

[0311] The electronic device 100 implements the display function through a GPU, a display screen 194, and an application processor. The GPU is a microprocessor for image processing, which connects the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 110 may include one or more GPUs that execute program instructions to generate or change display information.

[0312] The display screen 194 is used to display images, videos, etc. The display screen 194 includes a display panel. The display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode or an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), Miniled, MicroLed, Micro-oled, a quantum dot light-emitting diode (QLED), etc. In some embodiments, the electronic device 100 may include 1 or N display screens 194, where N is a positive integer greater than 1. Among them, the display screen 194 in the embodiment of the present application may be a touch screen. That is, the touch sensor 180K is integrated in the display screen 194.

[0313] The electronic device 100 can realize the shooting function through ISP, camera 193, video codec, GPU, display screen 194 and application processor.

[0314] ISP is used to process the data fed back by camera 193. For example, when taking a photo, the shutter is opened, and the light is transmitted to the camera photosensitive element through the lens. The light signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to ISP for processing and converts it into an image visible to the naked eye. ISP can also perform algorithm optimization on the noise, brightness, and skin color of the image. ISP can also optimize the exposure, color temperature and other parameters of the shooting scene. In some embodiments, ISP can be set in camera 193.

[0315] The camera 193 is used to capture still images or videos. The object generates an optical image through the lens and projects it onto the photosensitive element. The photosensitive element can be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the optical signal into an electrical signal, and then passes the electrical signal to the ISP to be converted into a digital image signal. The ISP outputs the digital image signal to the DSP for processing. The DSP converts the digital image signal into an image signal in a standard RGB, YUV or other format. In some embodiments, the electronic device 100 may include 1 or N cameras 193, where N is a positive integer greater than 1.

[0316] The digital signal processor is used to process digital signals, and can process not only digital image signals but also other digital signals. For example, when the electronic device 100 is selecting a frequency point, the digital signal processor is used to perform Fourier transform on the frequency point energy.

[0317] Video codecs are used to compress or decompress digital videos. The electronic device 100 may support one or more video codecs. Thus, the electronic device 100 may play or record videos in a variety of coding formats, such as Moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, MPEG4, etc.

[0318] NPU is a neural network (NN) computing processor. By drawing on the structure of biological neural networks, such as the transmission mode between neurons in the human brain, it can quickly process input information and can also continuously self-learn. Through NPU, applications such as intelligent cognition of electronic device 100 can be realized, such as image recognition, face recognition, voice recognition, text understanding, etc.

[0319] The internal memory 121 may include one or more random access memories (RAM) and one or more non-volatile memories (NVM).

[0320] Random access memory may include static random-access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM, for example, the fifth generation DDR SDRAM is generally referred to as DDR5 SDRAM), etc.;

[0321] Non-volatile memory may include disk storage devices and flash memory.

[0322] Flash memory can be divided into NOR FLASH, NAND FLASH, 3D NAND FLASH, etc. according to the operating principle; can be divided into single-level cell (SLC), multi-level cell (MLC), triple-level cell (TLC), quad-level cell (QLC), etc. according to the storage unit potential level; can be divided into universal flash storage (UFS), embedded multi media card (eMMC), etc. according to the storage specification.

[0323] The random access memory can be directly read and written by the processor 110, and can be used to store executable programs (such as machine instructions) of the operating system or other running programs, and can also be used to store user and application data.

[0324] The non-volatile memory may also store executable programs and user and application data, etc., and may be loaded into the random access memory in advance for direct reading and writing by the processor 110 .

[0325] The external memory interface 120 can be used to connect to an external non-volatile memory to expand the storage capacity of the electronic device 100. The external non-volatile memory communicates with the processor 110 through the external memory interface 120 to implement a data storage function. For example, files such as music and videos are stored in the external non-volatile memory.

[0326] The electronic device 100 can implement audio functions such as media data playback and recording through the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the headphone jack 170D, and the application processor.

[0327] The audio module 170 is used to convert digital audio information into analog audio signal output, and is also used to convert analog audio input into digital audio signals. The audio module 170 can also be used to encode and decode audio signals. In some embodiments, the audio module 170 can be arranged in the processor 110, or some functional modules of the audio module 170 can be arranged in the processor 110. The speaker 170A, also called a "speaker", is used to convert audio electrical signals into sound signals. The electronic device 100 can listen to music or listen to hands-free calls through the speaker 170A.

[0328] The receiver 170B, also called a "earpiece", is used to convert audio electrical signals into sound signals. When the electronic device 100 receives a call or voice message, the voice can be received by placing the receiver 170B close to the human ear.

[0329] Microphone 170C, also called "microphone" or "microphone", is used to convert sound signals into electrical signals. When making a call or sending a voice message, the user can speak by putting their mouth close to microphone 170C to input the sound signal into microphone 170C. The electronic device 100 can be provided with at least one microphone 170C. In other embodiments, the electronic device 100 can be provided with two microphones 170C, which can not only collect sound signals but also realize noise reduction function. In other embodiments, the electronic device 100 can also be provided with three, four or more microphones 170C to collect sound signals, reduce noise, identify the sound source, realize directional recording function, etc.

[0330] The earphone interface 170D is used to connect a wired earphone and can be a USB interface 130 or a 3.5 mm open mobile terminal platform (OMTP) standard interface or a cellular telecommunications industry association of the USA (CTIA) standard interface.

[0331] The pressure sensor 180A is used to sense the pressure signal and can convert the pressure signal into an electrical signal. In some embodiments, the pressure sensor 180A can be set on the display screen 194. There are many types of pressure sensors 180A, such as resistive pressure sensors, inductive pressure sensors, capacitive pressure sensors, etc. A capacitive pressure sensor can be a parallel plate including at least two conductive materials. When a force acts on the pressure sensor 180A, the capacitance between the electrodes changes. The electronic device 100 determines the intensity of the pressure based on the change in capacitance. When a touch operation acts on the display screen 194, the electronic device 100 detects the touch operation intensity according to the pressure sensor 180A. The electronic device 100 can also calculate the touch position according to the detection signal of the pressure sensor 180A. In some embodiments, touch operations acting on the same touch position but with different touch operation intensities can correspond to different operation instructions. For example: when a touch operation with a touch operation intensity less than the first pressure threshold acts on the short message application icon, an instruction to view the short message is executed. When a touch operation with a touch operation intensity greater than or equal to a first pressure threshold acts on the short message application icon, an instruction to create a new short message is executed.

[0332] The gyro sensor 180B can be used to determine the motion posture of the electronic device 100. In some embodiments, the angular velocity of the electronic device 100 around three axes (i.e., x, y, and z axes) can be determined by the gyro sensor 180B. The gyro sensor 180B can be used for anti-shake shooting. For example, when the shutter is pressed, the gyro sensor 180B detects the angle of the electronic device 100 shaking, calculates the distance that the lens module needs to compensate based on the angle, and allows the lens to offset the shaking of the electronic device 100 through reverse movement to achieve anti-shake. The gyro sensor 180B can also be used for navigation and somatosensory game scenes.

[0333] The air pressure sensor 180C is used to measure air pressure. In some embodiments, the electronic device 100 calculates the altitude through the air pressure value measured by the air pressure sensor 180C to assist positioning and navigation.

[0334] The magnetic sensor 180D includes a Hall sensor. The electronic device 100 can use the magnetic sensor 180D to detect the opening and closing of the flip leather case. In some embodiments, when the electronic device 100 is a flip phone, the electronic device 100 can detect the opening and closing of the flip cover according to the magnetic sensor 180D. Then, according to the detected opening and closing state of the leather case or the opening and closing state of the flip cover, the flip cover can be automatically unlocked.

[0335] The acceleration sensor 180E can detect the magnitude of the acceleration of the electronic device 100 in all directions (generally three axes). When the electronic device 100 is stationary, the magnitude and direction of gravity can be detected. It can also be used to identify the posture of the electronic device 100 and is applied to applications such as horizontal and vertical screen switching and pedometers.

[0336] The distance sensor 180F is used to measure the distance. The electronic device 100 can measure the distance by infrared or laser. In some embodiments, when shooting a scene, the electronic device 100 can use the distance sensor 180F to measure the distance to achieve fast focusing.

[0337] The proximity light sensor 180G may include, for example, a light emitting diode (LED) and a light detector, such as a photodiode. The light emitting diode may be an infrared light emitting diode. The electronic device 100 emits infrared light outward through the light emitting diode. The electronic device 100 uses a photodiode to detect infrared reflected light from nearby objects. When sufficient reflected light is detected, it can be determined that there is an object near the electronic device 100. When insufficient reflected light is detected, the electronic device 100 can determine that there is no object near the electronic device 100. The electronic device 100 can use the proximity light sensor 180G to detect that the user holds the electronic device 100 close to the ear to talk, so as to automatically turn off the screen to save power. The proximity light sensor 180G can also be used in leather case mode and pocket mode to automatically unlock and lock the screen.

[0338] The ambient light sensor 180L is used to sense the ambient light brightness. The electronic device 100 can adaptively adjust the brightness of the display screen 194 according to the perceived ambient light brightness. The ambient light sensor 180L can also be used to automatically adjust the white balance when taking pictures. The ambient light sensor 180L can also cooperate with the proximity light sensor 180G to detect whether the electronic device 100 is in a pocket to prevent accidental touches.

[0339] The fingerprint sensor 180H is used to collect fingerprints. The electronic device 100 can use the collected fingerprint characteristics to implement fingerprint unlocking, access application locks, fingerprint photography, fingerprint call answering, etc.

[0340] The temperature sensor 180J is used to detect temperature. In some embodiments, the electronic device 100 uses the temperature detected by the temperature sensor 180J to execute a temperature processing strategy. For example, when the temperature reported by the temperature sensor 180J exceeds a threshold, the electronic device 100 reduces the performance of a processor located near the temperature sensor 180J to reduce power consumption and implement thermal protection. In other embodiments, when the temperature is lower than another threshold, the electronic device 100 heats the battery 142 to avoid abnormal shutdown of the electronic device 100 due to low temperature. In other embodiments, when the temperature is lower than another threshold, the electronic device 100 performs a boost on the output voltage of the battery 142 to avoid abnormal shutdown caused by low temperature.

[0341] The touch sensor 180K is also called a "touch device". The touch sensor 180K can be set on the display screen 194. The touch sensor 180K and the display screen 194 form a touch screen, also called a "touch screen". The touch sensor 180K is used to detect touch operations acting on or near it. The touch sensor can pass the detected touch operation to the application processor to determine the type of touch event. Visual output related to the touch operation can be provided through the display screen 194. In other embodiments, the touch sensor 180K can also be set on the surface of the electronic device 100, which is different from the position of the display screen 194.

[0342] The bone conduction sensor 180M can obtain a vibration signal. In some embodiments, the bone conduction sensor 180M can obtain a vibration signal of a vibrating bone block of the vocal part of the human body. The bone conduction sensor 180M can also contact the human pulse to receive a blood pressure beat signal. In some embodiments, the bone conduction sensor 180M can also be set in an earphone and combined into a bone conduction earphone. The audio module 170 can parse out a voice signal based on the vibration signal of the vibrating bone block of the vocal part obtained by the bone conduction sensor 180M to realize a voice function. The application processor can parse the heart rate information based on the blood pressure beat signal obtained by the bone conduction sensor 180M to realize a heart rate detection function.

[0343] The key 190 includes a power key, a volume key, etc. The key 190 may be a mechanical key or a touch key. The electronic device 100 may receive key input and generate key signal input related to user settings and function control of the electronic device 100.

[0344] Motor 191 can generate vibration prompts. Motor 191 can be used for incoming call vibration prompts, and can also be used for touch vibration feedback. For example, touch operations acting on different applications (such as taking pictures, audio playback, etc.) can correspond to different vibration feedback effects. For touch operations acting on different areas of the display screen 194, motor 191 can also correspond to different vibration feedback effects. Different application scenarios (for example: time reminders, receiving messages, alarm clocks, games, etc.) can also correspond to different vibration feedback effects. The touch vibration feedback effect can also support customization.

[0345] Indicator 192 may be an indicator light, which may be used to indicate charging status, power changes, messages, missed calls, notifications, etc.

[0346] The SIM card interface 195 is used to connect a SIM card. The SIM card can be connected to and separated from the electronic device 100 by inserting it into the SIM card interface 195 or pulling it out from the SIM card interface 195. The electronic device 100 can support 1 or N SIM card interfaces, where N is a positive integer greater than 1. The SIM card interface 195 can support Nano SIM cards, Micro SIM cards, SIM cards, and the like. Multiple cards can be inserted into the same SIM card interface 195 at the same time. The types of the multiple cards can be the same or different. The SIM card interface 195 can also be compatible with different types of SIM cards. The SIM card interface 195 can also be compatible with external memory cards. The electronic device 100 interacts with the network through the SIM card to implement functions such as calls and data communications. In some embodiments, the electronic device 100 uses an eSIM, i.e., an embedded SIM card. The eSIM card can be embedded in the electronic device 100 and cannot be separated from the electronic device 100.

[0347] The interface display methods in the above embodiments can all be implemented in the electronic device 100 having the above hardware structure.

[0348] This embodiment further provides a computer-readable storage medium, in which computer instructions are stored. When the computer instructions are executed on the electronic device 100, the electronic device 100 executes the above-mentioned related method steps to implement the interface display method in the above-mentioned embodiment.

[0349] This embodiment also provides a computer program product. When the computer program product is run on a computer, the computer is caused to execute the above-mentioned related steps to implement the interface display method in the above-mentioned embodiment.

[0350] In addition, an embodiment of the present application also provides a device, which can specifically be a chip, component or module, and the device may include a connected processor and memory; wherein the memory is used to store computer execution instructions, and when the device is running, the processor can execute the computer execution instructions stored in the memory so that the chip executes the interface display method in the above-mentioned method embodiments.

[0351] Through the description of the above implementation methods, technical personnel in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional modules is used as an example. In actual applications, the above-mentioned 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.

[0352] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0353] The unit described as a separate component may or may not be physically separated, and the component shown as a unit may be one physical unit or multiple physical units, that is, it may be located in one place or distributed in multiple different places. Some or all of the units may be selected according to actual needs to achieve the purpose of the embodiment.

[0354] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0355] If the integrated unit is implemented in the form of 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 embodiment of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium, including several instructions to enable a device (which can be a single-chip microcomputer, chip, etc.) or a processor (processor) to perform all or part of the steps of each embodiment method of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), disk or optical disk and other media that can store program code.

[0356] The above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, a person skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the scope of the technical solutions of the embodiments of the present application.

Claims

1. An interface display method is applied to an electronic device, wherein the electronic device comprises a processing chip and a display screen, wherein the processing chip comprises a general synthesis channel for layer synthesis and a rounded corner synthesis channel dedicated to a rounded corner layer, wherein: The method comprises: Receiving a first operation from a user; In response to the first operation, starting a first application, where the first application is an application having a privacy indicator display requirement; Drawing a first rounded corner layer, wherein the first rounded corner layer includes the privacy indicator; Drawing an application layer including image information of the first application program; Using the general synthesis channel to synthesize the first rounded corner layer and the application layer to obtain an image frame; The image frame is displayed on the display screen.

2. The interface display method according to claim 1, characterized in that: The method further comprises: receiving a second operation from the user; In response to the second operation, exiting the first application; Drawing a second rounded corner layer, wherein the second rounded corner layer does not include the privacy indicator; The second rounded corner layer is synthesized using the rounded corner synthesis channel.

3. The interface display method according to claim 2, characterized in that: After exiting the first application, the method further includes: Creating a notification to cancel display of the privacy indicator; The step of synthesizing the second rounded corner layer using the rounded corner synthesis channel includes: Based on the notification of canceling display of the privacy indicator, the second rounded corner layer is synthesized using the rounded corner synthesis channel.

4. The interface display method according to claim 3, characterized in that: The processing chip includes a hardware synthesizer HWC, the HWC includes the rounded corner synthesis channel and the general synthesis channel, the HWC is used to use the rounded corner synthesis channel to synthesize the layer to be synthesized when the layer to be synthesized includes a rounded corner label, and the canceling display notification based on the privacy indicator uses the rounded corner synthesis channel to synthesize the second rounded corner layer, including: The synthesis service SurfaceFlinger adds the rounded corner label to the second rounded corner layer in response to the notification of canceling display of the privacy indicator; The SurfaceFlinger sends the second rounded corner layer including the rounded corner label to the HWC; The HWC uses the rounded corner synthesis channel to synthesize the second rounded corner layer.

5. The interface display method according to claim 3, characterized in that: The processing chip includes a HWC, the HWC includes the rounded corner synthesis channel and the general synthesis channel, and the canceling display notification based on the privacy indicator uses the rounded corner synthesis channel to synthesize the second rounded corner layer, including: SurfaceFlinger creates first identification information in response to the notification of canceling display of the privacy indicator, wherein the first identification information includes an identification of the second rounded corner layer; The SurfaceFlinger sends the second rounded corner layer and the first identification information to the HWC; The HWC enables the rounded corner synthesis channel based on the first identification information, and uses the rounded corner synthesis channel to synthesize the second rounded corner layer.

6. The interface display method according to claim 1, characterized in that: After starting the first application, the method further includes: creating a display notification of the privacy indicator; The synthesizing the first rounded corner layer and the application layer by using the universal synthesis channel includes: Based on the display notification of the privacy indicator, the first rounded corner layer and the application layer are synthesized using the universal synthesis channel.

7. The interface display method according to claim 6, characterized in that: The processing chip includes an HWC, the HWC includes the rounded corner synthesis channel and the general synthesis channel, the HWC is used to use the rounded corner synthesis channel to synthesize the layer to be synthesized when the layer to be synthesized includes a rounded corner label, and the display notification based on the privacy indicator uses the general synthesis channel to synthesize the first rounded corner layer and the application layer, including: SurfaceFlinger removes the rounded corner label set for the first rounded corner layer in response to the display notification of the privacy indicator; The SurfaceFlinger sends the first rounded corner layer and the application layer that do not include the rounded corner label to the HWC; The HWC uses the universal synthesis channel to synthesize the first rounded corner layer and the application layer.

8. The interface display method according to claim 6, characterized in that: The processing chip includes a HWC, the HWC includes the rounded corner synthesis channel and the general synthesis channel, and the display notification based on the privacy indicator uses the general synthesis channel to synthesize the first rounded corner layer and the application layer, including: SurfaceFlinger creates second identification information in response to the display notification of the privacy indicator; The SurfaceFlinger sends the first fillet layer, the application layer, and the second identification information to the HWC; The HWC disables the rounded corner synthesis channel based on the second identification information, and uses the general synthesis channel to synthesize the first rounded corner layer and the application layer.

9. The interface display method according to claim 5 or 8, characterized in that: The method further comprises: A transmission interface for transmitting the first identification information or the second identification information is established between the SurfaceFlinger and the HWC.

10. The interface display method according to claim 1, characterized in that: The synthesizing the first rounded corner layer and the application layer by using the universal synthesis channel includes: In a case where the synthesis capability of the general synthesis channel meets the synthesis requirements of the first rounded corner layer and the application layer, the first rounded corner layer and the application layer are synthesized by using the general synthesis channel; In the case where the synthesis capability of the general synthesis channel does not meet the synthesis requirements of the first rounded corner layer and the application layer, the first rounded corner layer and the application layer are synthesized using a graphics processor GPU and the general synthesis channel.

11. The interface display method according to any one of claims 1 to 10, characterized in that: The first application is a camera application or a recording application.

12. An interface display method is applied to an electronic device, wherein the electronic device comprises a processing chip and a display screen, wherein the processing chip comprises a general synthesis channel for layer synthesis and a rounded corner synthesis channel dedicated to a rounded corner layer, wherein: The method comprises: Receiving a first operation from a user; In response to the first operation, starting a camera application; Drawing a first rounded corner layer, wherein the first rounded corner layer includes a privacy indicator; Draw the camera preview layer of the camera application; The first rounded corner layer and the camera preview layer are synthesized by using the universal synthesis channel to obtain a camera preview interface; The camera preview interface is displayed on the display screen.

13. The interface display method according to claim 12, characterized in that: The method further comprises: receiving a second operation from the user; In response to the second operation, switching to an interface of another application, where the other application does not have a display requirement for the privacy indicator; Drawing a second rounded corner layer, wherein the second rounded corner layer does not include the privacy indicator; The second rounded corner layer is synthesized using the rounded corner synthesis channel.

14. The interface display method according to claim 13, characterized in that: After switching to the interface of another application, the method further includes: Creating a notification to cancel display of the privacy indicator; The step of synthesizing the second rounded corner layer using the rounded corner synthesis channel includes: Based on the notification of canceling display of the privacy indicator, the second rounded corner layer is synthesized using the rounded corner synthesis channel.

15. The interface display method according to claim 14, characterized in that: The processing chip includes a hardware synthesizer HWC, the HWC includes the rounded corner synthesis channel and the general synthesis channel, the HWC is used to use the rounded corner synthesis channel to synthesize the layer to be synthesized when the layer to be synthesized includes a rounded corner label, and the canceling display notification based on the privacy indicator uses the rounded corner synthesis channel to synthesize the second rounded corner layer, including: The synthesis service SurfaceFlinger adds the rounded corner label to the second rounded corner layer in response to the notification of canceling display of the privacy indicator; The SurfaceFlinger sends the second rounded corner layer including the rounded corner label to the HWC; The HWC uses the rounded corner synthesis channel to synthesize the second rounded corner layer.

16. The interface display method according to claim 12, characterized in that: After starting the camera application, the method further includes: creating a display notification of the privacy indicator; The step of synthesizing the first rounded corner layer and the camera preview layer by using the universal synthesis channel includes: Based on the display notification of the privacy indicator, the first rounded corner layer and the camera preview layer are synthesized using the universal synthesis channel.

17. The interface display method according to claim 16, characterized in that: The processing chip includes an HWC, the HWC includes the rounded corner synthesis channel and the general synthesis channel, the HWC is used to use the rounded corner synthesis channel to synthesize the layer to be synthesized when the layer to be synthesized includes a rounded corner label, and the display notification based on the privacy indicator uses the general synthesis channel to synthesize the first rounded corner layer and the camera preview layer, including: SurfaceFlinger removes the rounded corner label set for the first rounded corner layer in response to the display notification of the privacy indicator; The SurfaceFlinger sends the first rounded corner layer and the camera preview layer that do not include the rounded corner label to the HWC; The HWC uses the universal synthesis channel to synthesize the first rounded corner layer and the camera preview layer.

18. An electronic device, characterized in that: The electronic device comprises a display screen, a memory and a processor; The display screen, the memory and the processor are coupled; The memory is used to store program instructions; The processor is used to read the program instructions stored in the memory to implement the interface display method as described in any one of claims 1 to 11, or to implement the interface display method as described in any one of claims 12 to 17.

19. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-readable instructions, and when the computer-readable instructions are executed by the processor, they implement the interface display method as described in any one of claims 1 to 11, or implement the interface display method as described in any one of claims 12 to 17.

20. A chip coupled to a memory in an electronic device, characterized in that: The chip is used to control the electronic device to execute the interface display method as described in any one of claims 1 to 11, or to execute the interface display method as described in any one of claims 12 to 17.