CN112083905A - Electronic equipment and layer drawing method thereof - Google Patents

Electronic equipment and layer drawing method thereof Download PDF

Info

Publication number
CN112083905A
CN112083905A CN202010974851.1A CN202010974851A CN112083905A CN 112083905 A CN112083905 A CN 112083905A CN 202010974851 A CN202010974851 A CN 202010974851A CN 112083905 A CN112083905 A CN 112083905A
Authority
CN
China
Prior art keywords
display screen
layer
screen
state
display
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202010974851.1A
Other languages
Chinese (zh)
Inventor
梅正怡
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hisense Mobile Communications Technology Co Ltd
Original Assignee
Hisense Mobile Communications Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hisense Mobile Communications Technology Co Ltd filed Critical Hisense Mobile Communications Technology Co Ltd
Priority to CN202010974851.1A priority Critical patent/CN112083905A/en
Publication of CN112083905A publication Critical patent/CN112083905A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/14Digital output to display device ; Cooperation and interconnection of the display device with other functional units
    • G06F3/1423Digital output to display device ; Cooperation and interconnection of the display device with other functional units controlling a plurality of local displays, e.g. CRT and flat panel display

Abstract

The application discloses electronic equipment and a layer drawing method thereof, and relates to the technical field of layer processing. After the electronic device obtains the layer source data, the on-off state of each display screen in the at least two display screens can be determined. Then, the electronic device may only draw a layer corresponding to the display screen in the bright screen state, and prohibit drawing a layer corresponding to the display screen in the off screen state. Therefore, the flexibility of drawing the layers by the electronic equipment is effectively improved. In addition, because the display screen in the screen-off state does not display the image, drawing of the layer corresponding to the display screen in the screen-off state is prohibited, and waste of processor resources can be avoided.

Description

Electronic equipment and layer drawing method thereof
Technical Field
The present disclosure relates to the field of layer processing technologies, and in particular, to an electronic device and a layer drawing method thereof.
Background
An electronic device may include a processor, a primary display screen, and a secondary display screen.
After an application installed in the electronic device is started, the processor may receive layer source data sent by the application, and may draw a layer corresponding to the main display screen and a layer corresponding to the secondary display screen based on the layer source data. However, the layer drawing method has poor flexibility.
Disclosure of Invention
The application provides electronic equipment and a layer drawing method thereof, which can solve the problem of poor flexibility of the layer drawing method in the related art. The technical scheme is as follows:
in one aspect, an electronic device is provided, which includes: a processor and at least two display screens; the processor is configured to:
obtaining layer source data;
determining the on-off state of each display screen in the at least two display screens;
prohibiting drawing of a layer corresponding to the display screen in a screen-off state based on the layer source data;
drawing a layer corresponding to the display screen in a bright screen state based on the layer source data;
the display screen in the bright screen state is used for displaying the layer corresponding to the display screen in the bright screen state.
Optionally, the processor includes: a central processing unit and a graphics processor;
the central processing unit is used for sending a first storage position of a layer corresponding to the display screen in the bright screen state to the graphic processor and forbidding sending a second storage position of the layer corresponding to the display screen in the screen-off state to the graphic processor;
and the graphic processor is used for drawing a layer corresponding to the display screen in the bright screen state according to the layer source data based on the first storage position sent by the central processing unit, and storing the layer to the first storage position.
Optionally, the processor includes: a central processing unit and a graphics processor;
the central processing unit is used for sending a first drawing instruction for indicating drawing of a layer corresponding to the display screen in the bright screen state to the graphic processor, and forbidding sending a second layer drawing instruction for indicating drawing of a layer corresponding to the display screen in the screen-off state to the graphic processor;
and the graphics processor is used for responding to the first drawing instruction and drawing the layer corresponding to the display screen in the bright screen state based on the layer source data.
Optionally, the source data of the layer includes: the display screen comprises first sub-layer source data corresponding to the display screen in the screen-off state and second sub-layer source data corresponding to the display screen in the screen-on state, wherein the first sub-layer source data are different from the second sub-layer source data, and the storage position of the first sub-layer source data is different from that of the second sub-layer source data; the processor is configured to:
and forbidding to distribute a storage area for the first sub-layer source data.
Optionally, the processor includes: the system comprises a central processing unit, a graphic processor and a display processor;
the graphic processor is used for drawing a layer corresponding to the display screen in the bright screen state based on the layer source data;
the central processing unit is used for sending the layer corresponding to the display screen in the bright screen state to the display processor;
and the display processor is used for driving the display screen in the bright screen state to display the layer.
Optionally, the processor is configured to:
and drawing a layer corresponding to the display screen in the bright screen state based on the layer source data and the resolution of the display screen in the bright screen state.
Optionally, the at least two display screens include a main display screen located on a front side of the electronic device, and a sub display screen located on a back side of the electronic device.
In another aspect, an electronic device is provided, the electronic device being connected with at least two display devices, each of the display devices comprising at least one display screen; the electronic device includes: a processor to:
obtaining layer source data;
determining the on-off state of each display screen;
prohibiting drawing of a layer corresponding to the display screen in a screen-off state based on the layer source data;
drawing a layer corresponding to the display screen in a bright screen state based on the layer source data;
and sending the layer to the display equipment to which the display screen in the bright screen state belongs.
In another aspect, a method for drawing a layer of an electronic device is provided, where the method includes:
obtaining layer source data;
determining the on-off state of each display screen in at least two display screens;
prohibiting drawing of a layer corresponding to the display screen in a screen-off state based on the layer source data;
drawing a layer corresponding to the display screen in the bright screen state based on the layer source data, and displaying the layer corresponding to the display screen in the bright screen state on the display screen in the bright screen state.
Optionally, the electronic device includes a graphics processor; the prohibiting drawing of the layer corresponding to the display screen in the screen-off state based on the layer source data includes:
and forbidding sending the second storage position of the layer corresponding to the display screen in the screen-off state to the graphics processor.
In still another aspect, an electronic device is provided, which includes: the device comprises a memory, a processor and a computer program which is stored on the memory and can run on the processor, wherein the processor realizes the layer drawing method of the electronic device according to the above aspect when executing the computer program.
In still another aspect, a computer-readable storage medium is provided, in which a computer program is stored, and when the computer program is executed by a processor, the computer program implements the layer drawing method of the electronic device according to the above aspect.
In still another aspect, a computer program product containing instructions is provided, which when run on the computer, causes the computer to execute the layer drawing method of the electronic device according to the above aspect.
The beneficial effect that technical scheme that this application provided brought includes at least:
the application provides electronic equipment and a layer drawing method thereof. Then, the electronic device may only draw a layer corresponding to the display screen in the bright screen state, and prohibit drawing a layer corresponding to the display screen in the off screen state. Therefore, the flexibility of drawing the layers by the electronic equipment is effectively improved. In addition, because the display screen in the screen-off state does not display the image, drawing of the layer corresponding to the display screen in the screen-off state is prohibited, and waste of processor resources can be avoided.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a flowchart of a layer drawing method of an electronic device according to an embodiment of the present application;
fig. 2 is a flowchart of a layer drawing method of another electronic device according to an embodiment of the present application;
FIG. 3 is a schematic diagram of an electronic device including a main display and a secondary display provided by an embodiment of the present application;
FIG. 4 is a schematic diagram of another electronic device including a main display and a secondary display provided by an embodiment of the present application;
FIG. 5 is a schematic diagram of at least two display screens independent of an electronic device according to an embodiment of the present application;
fig. 6 is a schematic structural diagram of another at least two display screens independent of an electronic device according to an embodiment of the present application;
fig. 7 is a schematic structural diagram of an electronic device according to an embodiment of the present application;
fig. 8 is a block diagram of a software structure of an electronic device according to an embodiment of the present application.
Detailed Description
To make the objects, technical solutions and advantages of the present application more clear, embodiments of the present application will be described in further detail below with reference to the accompanying drawings.
The embodiment of the application provides a layer drawing method of electronic equipment, and the method can be applied to a processor of the electronic equipment. Optionally, the electronic device may be a mobile phone or a tablet computer, and the like, for example, the electronic device may be a mobile phone. Moreover, the operating system of the electronic device may be an Android (Android) operating system. Referring to fig. 1, the method may include:
step 101, obtaining layer source data.
An Application (APP) may be installed in the electronic device, and after the APP is started, the APP may send the layer source data to a processor of the electronic device. Accordingly, the processor may obtain the layer source data sent by the application program.
Wherein the layer source data may be used for rendering by a processor to synthesize the layer. The layer may refer to a picture containing elements such as text or graphics.
And 102, determining the on-off state of each display screen in at least two display screens.
After obtaining the layer source data sent by the application program, the electronic device may determine an on-off state of each of the at least two display screens.
And 103, prohibiting drawing of the layer corresponding to the display screen in the screen-off state based on the layer source data.
After the processor of the electronic device determines the on-off state of each display screen, the processor may determine the display screen in the off-screen state, and prohibit drawing a layer corresponding to the display screen in the off-screen state based on the layer source data.
And 104, drawing a layer corresponding to the display screen in the bright screen state based on the layer source data, and displaying the layer corresponding to the display screen in the bright screen state on the display screen in the bright screen state.
After the processor of the electronic device determines the on-off state of each display screen, the processor can determine the display screen in the on-screen state, and draw the layer corresponding to the display screen in the on-screen state based on the layer source data. After the drawing of the layer is completed, the processor can display the layer corresponding to the display screen in the bright screen state on the display screen in the bright screen state.
To sum up, the embodiment of the present application provides a layer drawing method for an electronic device, where after obtaining layer source data, the electronic device may determine an on-off state of each display screen in at least two display screens. Then, the electronic device may only draw a layer corresponding to the display screen in the bright screen state, and prohibit drawing a layer corresponding to the display screen in the off screen state. Therefore, the flexibility of drawing the layers by the electronic equipment is effectively improved. In addition, because the display screen in the screen-off state does not display the image, drawing of the layer corresponding to the display screen in the screen-off state is prohibited, and waste of processor resources can be avoided.
Fig. 2 is a drawing method for a layer of an electronic device according to another embodiment of the present application, where the method may be applied to a processor of the electronic device. Optionally, the electronic device may be a mobile phone or a tablet computer, and the like, for example, the electronic device may be a mobile phone. And, the operating system of the electronic device may be an android operating system. Referring to fig. 2, the method may include:
step 201, obtaining layer source data.
An application program may be installed in the electronic device, and after the application program is started, the application program may send the layer source data to a processor of the electronic device. Correspondingly, the processor can obtain the layer source data sent by the application program. Wherein the layer source data may be used for rendering by a processor to synthesize the layer. The layer may refer to a picture containing elements such as text or graphics.
In an embodiment of the present application, the processor may include: a Central Processing Unit (CPU) and a Graphics Processing Unit (GPU). After the application program is started, the layer source data can be sent to a CPU of the electronic device. Correspondingly, the CPU may obtain the layer source data sent by the application program. The layer source data may be used for drawing by the GPU to synthesize a layer.
Alternatively, the CPU of the electronic device may be run with a surfefinger process. After the application installed in the electronic device is started, the layer source data may be sent to the surfaflinger process. Correspondingly, the surfeFinger process can obtain the layer source data sent by the application program.
It should be noted that the layer source data sent by the application program to the CPU may carry an identifier of the display screen. Optionally, the layer source data sent by the application program to the CPU may only carry the identifier of the display screen with higher priority in the at least two display screens. In this case, if other display screens with lower priorities in the at least two display screens also currently display layers, the layers displayed by the other display screens may be the same as the layers displayed by the display screens with higher priorities, that is, the layers displayed by each display screen in the at least two display screens may be the same. Or, the layer source data sent by the application program to the CPU may include at least two different sub-layer source data that correspond to at least two display screens one to one, and each sub-layer source data may carry an identifier of a corresponding display screen. That is, the layer source data may carry the identifiers of at least two display screens. In this case, each display screen may display a layer synthesized based on the sub-image layer source data corresponding thereto, that is, layers displayed by at least two display screens may be different.
Wherein, the identifier of each display screen in the at least two display screens can be the number of the display screen in the at least two display screens. For example, if the at least two display screens include a main display screen and a sub display screen, the main display screen may be identified as display device0, and the sub display screen may be identified as display device 1.
Step 202, determining the on-off state of each display screen in at least two display screens.
After receiving the layer source data sent by the application program, the CPU of the electronic device may determine an on-off state of each of the at least two display screens.
Optionally, the at least two display screens may be display screens of the electronic device, that is, the electronic device may include at least two display screens. For example, as can be seen in fig. 3 and 4, the at least two display screens may include two oppositely disposed display screens, one of the two display screens is a main display screen located on the front side of the electronic device, and the other display screen is a sub-display screen located on the back side of the electronic device. As can also be seen from fig. 3, the front face of the electronic device is also provided with a front camera 03 and an earpiece 04. As can be seen from fig. 4, the rear camera 05 is also disposed on the back of the electronic device. As shown in fig. 3 and 4, the side of the electronic device is further provided with a card slot 06 and a power button 07.
Alternatively, the electronic device may be separate from the at least two display screens and connected to each of the at least two display screens. For example, the electronic device may be connected with at least two display devices, each of which may include at least one display screen. Alternatively, the display device may be a High Definition Multimedia Interface (HDMI) device, such as a projector. Alternatively, the display device may be a device having a display screen, such as a television, a wearable device, or a vehicle-mounted display device.
For example, assuming that the display device includes a television and a projector, referring to fig. 5, the electronic device 00 may be connected to the television 20 and the projector 30, respectively. The television 20 may include a display screen 201 and the projector may include a projection screen 301.
Alternatively, assuming that the display device includes a tablet pc and an in-vehicle display device, referring to fig. 6, the electronic device may be connected with the tablet pc 40 and the in-vehicle display device 50, respectively. The tablet 40 may include a display 401 and the in-vehicle display device 50 may include a display 501.
In the embodiment of the application, a plurality of flag bits corresponding to at least two display screens one to one are stored in the electronic device. Each flag bit can be used for recording the on-off state of the display screen corresponding to the flag bit. Correspondingly, if the CPU needs to determine the on-off state of a certain display screen, the flag bit can be directly read, and the on-off state of the display screen is determined based on the read flag bit. For example, assume that the flag is 0, indicating that the display screen is in a bright screen state, and the flag is 1, indicating that the display screen is in a dead screen state. If the flag bit of a certain display screen read by the CPU is 0, it can be determined that the display screen is in a bright screen state. If the flag bit of a certain display screen read by the CPU is 1, the display screen can be determined to be in a screen-off state.
Optionally, the electronic device may control the on-off state of the display screen based on the detected on-screen instruction or the off-screen instruction for the display screen, and then update the flag bit corresponding to the display screen based on the on-off state. For each display screen in at least two display screens, if the CPU determines that a screen-off instruction for the display screen is received and a screen-on instruction for the display screen is not received, the display screen can be controlled to be in a screen-off state, and a flag bit corresponding to the display screen can be set to 1. If the CPU receives a screen-on instruction for the display screen and does not receive a screen-off instruction for the display screen, the display screen can be controlled to be in a screen-on state, and the flag bit corresponding to the display screen can be set to be 0.
Optionally, the CPU may detect whether a touch operation of a user on a power key of the electronic device or the display device is received, or may detect whether a fingerprint input operation of the user on the electronic device or the display device is received, so as to detect whether a screen turn-off instruction or a screen turn-on instruction for the display screen is received.
It should be noted that, for a scene in which the electronic device includes two display screens (i.e., the aforementioned main display screen and the auxiliary display screen) that are arranged oppositely, the CPU may further control the on-off state of the display screen based on a signal sent by the acceleration sensor, and then update the flag bit corresponding to the display screen based on the on-off state. Wherein the acceleration sensor may be used to measure acceleration due to gravity.
For example, the acceleration sensor may transmit the detected acceleration to the CPU. The CPU may determine the tilt angle of the electronic device based on the acceleration transmitted by the acceleration sensor. Then, the CPU may determine the display screen currently facing the gravity direction based on the inclination angle, control the display screen to be in a screen-off state, and set the flag bit of the display screen to 1. And the CPU can control the display screen which is arranged opposite to the display screen to be in a bright screen state, and set the zone bit of the display screen to be 0.
Step 203, determining the display screen in the screen-off state and the display screen in the screen-on state based on the on-off state of each display screen.
After determining the on-off state of each display screen, the CPU may determine, from the at least two display screens, the display screen in the off-screen state and the display screen in the on-screen state (i.e., the awake state).
For example, assume that the at least two display screens include: display screen 0, display screen 1 and display screen 2, wherein display screen 0 and display screen 2 are in the state of going out the screen, and display screen 1 is in bright screen state. The display screen in the off-screen state determined by the CPU may include: display screen 0 and display screen 2, the display screen of the bright screen state of affirmation includes: a display screen 1.
And 204, prohibiting drawing of the layer corresponding to the display screen in the screen-off state based on the layer source data.
After determining the display screen in the screen-off state, the processor may prohibit drawing a layer corresponding to the display screen in the screen-off state based on the layer source data. Optionally, the CPU in the processor may prohibit the GPU from drawing a layer corresponding to the display screen in the screen-off state based on the layer source data.
In this embodiment of the present application, for each display screen of the at least two display screens, a process of the GPU for drawing, based on the layer source data, a layer corresponding to the display screen may include: the GPU needs to first read the layer source data from the storage area storing the layer source data (the layer source data may be written into the storage area by the CPU), and obtain the storage location of the layer sent by the CPU after the drawing is completed (i.e., synthesized). Then, the GPU may draw a corresponding layer based on the layer source data based on the layer drawing instruction sent by the CPU. The storage area for storing the layer source data may be allocated by the CPU for the layer source data, and if the layer source data includes a plurality of different sub-layer source data, each sub-layer source data in the plurality of sub-layer source data may carry an identifier of a display screen. The CPU may allocate a storage area to each of the plurality of sub-layer source data, so that a subsequent GPU may read sub-layer source data from a certain storage area, and then draw a layer based on the sub-layer source data.
Based on this, in the embodiment of the present application, the following several optional implementation manners are taken as examples, and an exemplary description is given to a process in which the CPU prohibits the GPU from drawing a layer corresponding to the display screen in the screen-off state based on the layer source data.
In a first optional implementation manner, the CPU may prohibit sending, to the GPU, the second storage location of the layer corresponding to the display screen in the screen-off state. Because the GPU cannot acquire the to-be-stored position of the synthesized layer, the drawing operation of the layer corresponding to the display screen in the screen-off state cannot be executed, thereby achieving the effect of prohibiting drawing the layer corresponding to the display screen in the screen-off state.
In a second optional implementation manner, the CPU may prohibit sending, to the GPU, a second layer drawing instruction for instructing to draw a layer corresponding to the display screen in the screen-off state. Because the GPU does not receive the second layer drawing instruction sent by the CPU, the drawing operation of the layer corresponding to the display screen in the screen-off state cannot be executed, thereby achieving an effect of prohibiting drawing the layer corresponding to the display screen in the screen-off state.
In a third optional implementation manner, if the layer source data includes: the display screen display control method comprises a first sub-layer source data corresponding to a display screen in a screen-off state and a second sub-layer source data corresponding to a display screen in a screen-on state. The first sub-layer source data is different from the second sub-layer source data, and the storage position of the first sub-layer source data is different from the storage position of the second sub-layer source data. The CPU may prohibit allocation of a storage area for the first sub-layer source data. Therefore, in the process of executing the drawing of the picture layer, the GPU cannot read the first sub-picture layer source data corresponding to the display screen in the screen-off state, and then cannot execute the drawing operation of the picture layer corresponding to the display screen in the screen-off state, so that the effect of prohibiting the drawing of the picture layer corresponding to the display screen in the screen-off state can be achieved.
And step 205, drawing a layer corresponding to the display screen in the bright screen state based on the layer source data.
After determining the display screen in the bright screen state, the processor may draw a layer corresponding to the display screen in the bright screen state based on the layer source data. Optionally, the CPU in the processor may control the GPU to draw a layer corresponding to the display screen in the bright screen state based on the layer source data.
The process of the GPU for drawing the layer corresponding to the display screen in the bright screen state based on the layer source data may include: and the GPU reads the layer source data from the storage area for storing the layer source data and receives the first storage position of the layer after the drawing is finished, which is sent by the CPU. Then, the GPU may respond to a first layer drawing instruction sent by the CPU to instruct drawing of a layer corresponding to the display screen in the bright screen state, draw a layer corresponding to the display screen in the bright screen state based on the read layer source data, and store the synthesized layer to the first storage location.
Optionally, in this embodiment of the application, before the GPU in the processor draws the image layer, the resolution of the display screen in the bright screen state may also be obtained. Then, the GPU may draw a layer corresponding to the display screen in the bright screen state based on the read layer source data and the acquired resolution of the display screen in the bright screen state under the control of the CPU, so that the drawn layer is adapted to the display screen in the bright screen state, thereby ensuring a display effect of the layer on the display screen in the bright screen state.
And step 206, displaying the layer corresponding to the display screen in the bright screen state on the display screen in the bright screen state.
After the processor of the electronic device synthesizes the layer corresponding to the display screen in the bright screen state, the layer corresponding to the display screen in the bright screen state may be displayed on the display screen in the bright screen state.
In this embodiment, the processor of the electronic device may further include: mobile Display Processor (MDP). After the GPU in the processor synthesizes the layer corresponding to the display screen in the bright screen state, the GPU may send the layer to the MDP. Correspondingly, after receiving the layer sent by the GPU, the MDP may determine, based on the correspondence between the display screen and the layer, the display screen in the bright screen state corresponding to the layer, and drive the display screen in the bright screen state to display the layer.
Taking an example that the electronic device includes a main display screen and a sub display screen, and the main display screen is in a bright screen state, and the sub display screen is in a dead screen state, a layer drawing method of the electronic device in the related art is explained. After receiving the layer source data, the CPU may control the GPU to draw a layer corresponding to the main display screen based on the layer source data, and draw a layer corresponding to the sub display screen. However, at this time, the secondary display screen is in a screen-off state, that is, the layer cannot be displayed on the secondary display screen, which may cause waste of GPU resources and waste of CPU resources, thereby reducing the performance of the electronic device and increasing the power consumption of the electronic device.
By adopting the layer drawing method provided by the embodiment of the application, after receiving the layer source data sent by the application program, the CPU of the electronic device prohibits the GPU from drawing the layer corresponding to the display screen in the screen-off state, and only draws the layer corresponding to the display screen in the screen-on state. For example, taking the electronic device including the main display and the sub display as an example, if the sub display is in the off state and the main display is in the on state, the CPU may prohibit the GPU from drawing the layer corresponding to the sub display and only draw the layer corresponding to the main display. If the main display screen is in a screen-off state and the auxiliary display screen is in a screen-on state, the CPU may control the GPU to prohibit drawing of a layer corresponding to the main display screen and only draw a layer corresponding to the auxiliary display screen. Therefore, the waste of CPU resources and GPU resources is avoided, the performance of the electronic equipment is improved, the power consumption of the electronic equipment is reduced, and the endurance time of the electronic equipment is prolonged.
It should be further noted that, the order of steps of the layer drawing method of the electronic device provided in the embodiment of the present application may be appropriately adjusted, and the steps may also be increased or decreased according to the situation. For example, step 202 may also be performed before step 201. Any method that can be easily conceived by a person skilled in the art within the technical scope disclosed in the present application is covered by the protection scope of the present application, and thus the detailed description thereof is omitted.
To sum up, the embodiment of the present application provides a layer drawing method for an electronic device, where after obtaining layer source data, the electronic device may determine an on-off state of each display screen in at least two display screens. Then, the electronic device may only draw a layer corresponding to the display screen in the bright screen state, and prohibit drawing a layer corresponding to the display screen in the off screen state. Therefore, the flexibility of drawing the layers by the electronic equipment is effectively improved. In addition, because the display screen in the screen-off state does not display the image, drawing of the layer corresponding to the display screen in the screen-off state is prohibited, and waste of processor resources can be avoided.
Fig. 7 is a schematic structural diagram of an electronic device according to an embodiment of the present application. The electronic device 110 may include: a processor 1101 and at least two display screens 131. The processor 1101 may be configured to:
obtaining layer source data;
determining the on-off state of each display screen in the at least two display screens;
prohibiting drawing of a layer corresponding to the display screen in the screen-off state based on the layer source data;
drawing a layer corresponding to the display screen in a bright screen state based on the layer source data;
the display screen 131 in the bright screen state may be used to display a layer corresponding to the display screen in the bright screen state.
Optionally, the processor 1101 includes: a CPU and a GPU;
the CPU may be configured to send a first storage location of a layer corresponding to the display screen in the bright screen state to the GPU, and prohibit sending a second storage location of the layer corresponding to the display screen in the screen-off state to the GPU;
the GPU is used for drawing a layer corresponding to the display screen in the bright screen state according to layer source data based on a first storage position sent by the CPU, and storing the layer to the first storage position.
Optionally, the processor 1101 may include: a CPU and a GPU;
the CPU is used for sending a first drawing instruction for indicating drawing of a layer corresponding to the display screen in the bright screen state to the GPU and forbidding sending of a second layer drawing instruction for indicating drawing of a layer corresponding to the display screen in the screen-off state to the GPU;
the GPU is used for responding to the first drawing instruction and drawing the layer corresponding to the display screen in the bright screen state based on the layer source data.
Optionally, the source data of the layer includes: the display screen display method comprises the steps that first sub-layer source data corresponding to a display screen in a screen-off state and second sub-layer source data corresponding to the display screen in a screen-on state, wherein the first sub-layer source data are different from the second sub-layer source data, and the storage position of the first sub-layer source data is different from that of the second sub-layer source data; the processor 1101 may be configured to:
and forbidding to distribute a storage area for the first sub-layer source data.
Optionally, the processor 1101 may include: CPU, GPU and MDP;
the GPU may be configured to draw a layer corresponding to a display screen in a bright screen state based on layer source data;
the CPU may be configured to send a layer corresponding to the display screen in the bright screen state to the MDP;
the MDP may be used to drive the display layer of the display screen in a bright screen state.
Optionally, the processor 1101 may be configured to:
and drawing a layer corresponding to the display screen in the bright screen state based on the layer source data and the resolution of the display screen in the bright screen state.
Optionally, the at least two display screens include a main display screen located on a front side of the electronic device and a sub-display screen located on a back side of the electronic device.
To sum up, the embodiment of the present application provides an electronic device, and after receiving layer source data, the electronic device may determine an on-off state of each display screen in at least two display screens. Then, the electronic device may only draw a layer corresponding to the display screen in the bright screen state, and prohibit drawing a layer corresponding to the display screen in the off screen state. Therefore, the flexibility of drawing the layers by the electronic equipment is effectively improved. In addition, because the display screen in the screen-off state does not display the image, drawing of the layer corresponding to the display screen in the screen-off state is prohibited, and waste of processor resources can be avoided.
The embodiment of the application also provides electronic equipment, wherein the electronic equipment is connected with at least two pieces of display equipment, and each piece of display equipment can comprise at least one display screen. Referring to fig. 7, the electronic device includes: a processor 1101. The processor 1101 may be configured to:
obtaining layer source data;
determining the on-off state of each display screen;
prohibiting drawing of a layer corresponding to the display screen in the screen-off state based on the layer source data;
drawing a layer corresponding to the display screen in a bright screen state based on the layer source data;
and sending the layer to the display equipment to which the display screen in the bright screen state belongs.
To sum up, the embodiment of the present application provides an electronic device, and after the electronic device obtains layer source data, the electronic device may determine an on-off state of each display screen in at least two display screens. Then, the electronic device may only draw a layer corresponding to the display screen in the bright screen state, and prohibit drawing a layer corresponding to the display screen in the off screen state. Therefore, the flexibility of drawing the layers by the electronic equipment is effectively improved. In addition, because the display screen in the screen-off state does not display the image, drawing of the layer corresponding to the display screen in the screen-off state is prohibited, and waste of processor resources can be avoided.
As shown in fig. 7, the electronic device 110 may include: a display unit 130, a Radio Frequency (RF) circuit 150, an audio circuit 160, a wireless fidelity (Wi-Fi) module 170, a bluetooth module 180, a power supply 190, and a camera 121.
The camera 121 may be used to capture still pictures or video, among other things. The object generates an optical picture through the lens and projects the optical picture to the photosensitive element. The photosensitive element may be a Charge Coupled Device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The light sensitive elements convert the light signals into electrical signals which are then passed to the processor 1101 for conversion into digital picture signals.
The processor 1101 is a control center of the electronic device 110, connects various parts of the entire terminal with various interfaces and lines, and performs various functions of the electronic device 110 and processes data by running or executing software programs stored in the memory 140 and calling data stored in the memory 140. In some embodiments, processor 1101 may include one or more processing units; the processor 1101 may also integrate an application processor, which mainly handles operating systems, user interfaces, applications, etc., and a baseband processor, which mainly handles wireless communications. It will be appreciated that the baseband processor described above may not be integrated into the processor 1101. In this application, the processor 1101 may run an operating system and an application program, may control a user interface to display, and may implement the layer drawing method for the electronic device provided in this embodiment of the application. Additionally, processor 1101 is coupled to input unit and display unit 130.
The display unit 130 may be used to receive input numeric or character information and generate signal inputs related to user settings and function control of the electronic device 110, and optionally, the display unit 130 may also be used to display information input by the user or information provided to the user and a Graphical User Interface (GUI) of various menus of the electronic device 110. The display unit 130 may include a main display 131 disposed on the front side of the electronic device 110, and a sub-display 132 disposed on the back side of the electronic device. Both the main display 131 and the sub-display may be configured in the form of a liquid crystal display, a light emitting diode, or the like. The display unit 130 may be used to display various graphical user interfaces described herein.
Memory 140 may be used to store software programs and data. The processor 1101 executes various functions and data processing of the electronic device 110 by executing software programs or data stored in the memory 140. The memory 140 may include high speed random access memory and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device. The memory 140 stores an operating system that enables the electronic device 110 to operate. The memory 140 in the present application may store an operating system and various application programs, and may also store codes for executing the layer drawing method of the electronic device provided in the embodiment of the present application.
The RF circuit 150 may be used for receiving and transmitting signals during information transmission and reception or during a call, and may receive downlink data of a base station and then deliver the received downlink data to the processor 1101 for processing; the uplink data may be transmitted to the base station. Typically, the RF circuitry includes, but is not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a low noise amplifier, a duplexer, and the like.
The audio circuitry 160, speaker 161, microphone 162 may provide an audio interface between a user and the electronic device 110. The audio circuit 160 may transmit the electrical signal converted from the received audio data to the speaker 161, and convert the electrical signal into a sound signal for output by the speaker 161. The electronic device 110 may also be configured with a volume button for adjusting the volume of the sound signal. On the other hand, the microphone 162 converts the collected sound signal into an electrical signal, converts the electrical signal into audio data after being received by the audio circuit 160, and then outputs the audio data to the RF circuit 150 to be transmitted to, for example, another terminal or outputs the audio data to the memory 140 for further processing. In this application, the microphone 162 may capture the voice of the user.
Wi-Fi is a short-range wireless transmission technology, and the electronic device 110 can help a user send and receive e-mails, browse webpages, access streaming media and the like through the Wi-Fi module 170, and provides wireless broadband Internet access for the user.
And the Bluetooth module 180 is used for performing information interaction with other Bluetooth devices with Bluetooth modules through a Bluetooth protocol. For example, the electronic device 110 may establish a bluetooth connection with a wearable electronic device (e.g., a smart watch) that is also equipped with a bluetooth module via the bluetooth module 180, thereby performing data interaction.
The electronic device 110 also includes a power supply 190 (e.g., a battery) to power the various components. The power supply may be logically coupled to the processor 1101 through a power management system to manage charging, discharging, and power consumption functions through the power management system. The electronic device 110 may also be configured with a power button for powering on and off the terminal, and locking the screen.
The electronic device 110 may include at least one sensor 1110, such as a motion sensor 11101, a distance sensor 11102, a fingerprint sensor 11103, and a temperature sensor 11104. The electronic device 110 may also be configured with other sensors such as gyroscopes, barometers, hygrometers, thermometers, and infrared sensors.
It can be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working processes of the mobile terminal and each device described above may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
Fig. 8 is a block diagram of a software structure of an electronic device according to an embodiment of the present application. The layered architecture divides the software into several layers, each layer having a clear role and division of labor. The layers communicate with each other through a software interface. In some embodiments, the android system is divided into four layers, an application layer, an application framework layer, an Android Runtime (ART) and system library, and a kernel layer from top to bottom.
The application layer may include a series of application packages. As shown in fig. 8, the application package may include applications such as camera, gallery, calendar, phone call, map, navigation, WLAN, bluetooth, music, video, short message, etc. The application framework layer provides an Application Programming Interface (API) and a programming framework for the application programs of the application layer. The application framework layer includes a number of predefined functions.
As shown in FIG. 8, the application framework layers may include a window manager, content provider, view system, phone manager, resource manager, notification manager, and the like.
The window manager is used for managing window programs. The window manager can obtain the size of the display screen, judge whether a status bar exists, lock the screen, intercept the screen and the like.
The content provider is used to store and retrieve data and make it accessible to applications. The data may include video, pictures, audio, calls made and received, browsing history and bookmarks, phone books, etc.
The view system includes visual controls such as controls to display text, controls to display pictures, and the like. The view system may be used to build applications. The display interface may be composed of one or more views. For example, the display interface including the short message notification icon may include a view for displaying text and a view for displaying pictures.
The phone manager is used to provide communication functions for the electronic device 110. Such as management of call status (including on, off, etc.).
The resource manager provides various resources for the application, such as localized strings, icons, pictures, layout files, video files, and the like.
The notification manager enables the application to display notification information in the status bar, can be used to convey notification-type messages, can disappear automatically after a short dwell, and does not require user interaction. Such as a notification manager used to inform download completion, message alerts, etc. The notification manager may also be a notification that appears in the form of a chart or scroll bar text at the top status bar of the system, such as a notification of a background running application, or a notification that appears on the screen in the form of a dialog window. For example, text information is prompted in the status bar, a prompt tone is given, the communication terminal vibrates, and an indicator light flashes.
The android run is composed of a core library and a virtual machine. android runtime is responsible for the scheduling and management of the android system.
The core library comprises two parts: one part is a function which needs to be called by java language, and the other part is a core library of android.
The application layer and the application framework layer run in a virtual machine. And executing java files of the application program layer and the application program framework layer into a binary file by the virtual machine. The virtual machine is used for performing the functions of object life cycle management, stack management, thread management, safety and exception management, garbage collection and the like.
The system library may include a plurality of functional modules. For example: surface managers (surface managers), media libraries (media libraries), three-dimensional graphics processing libraries (e.g., openGL ES), 2D graphics engines (e.g., SGL), and the like.
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 a variety of commonly used audio, video format playback and recording, and still picture files, etc. The media library may support a variety of audio-video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc.
The three-dimensional graphic processing library is used for realizing three-dimensional graphic drawing, picture rendering, synthesis, layer processing and the like.
The 2D graphics engine is a drawing engine for 2D drawing.
The kernel layer is a layer between hardware and software. The inner core layer at least comprises a display driver, a camera driver, an audio driver and a sensor driver.
The embodiment of the present application provides a computer-readable storage medium, where instructions are stored in the computer-readable storage medium, and when the instructions are executed on a computer, the instructions cause the computer to execute the layer drawing method of the electronic device provided in the above embodiment, for example, the method shown in fig. 1 or fig. 2.
The embodiment of the present application further provides a computer program product including instructions, which, when the computer program product runs on a computer, causes the computer to execute the layer drawing method of the electronic device provided in the above method embodiment, for example, the method shown in fig. 1 or fig. 2.
It will be understood by those skilled in the art that all or part of the steps for implementing the above embodiments may be implemented by hardware, or may be implemented by a program instructing relevant hardware, where the program may be stored in a computer-readable storage medium, and the above-mentioned storage medium may be a read-only memory, a magnetic disk or an optical disk, etc. The term "at least one" in this application means one or more, and the term "plurality" in this application means two or more.
The above description is only exemplary of the present application and should not be taken as limiting the present application, and any modifications, equivalents, improvements and the like that are made within the spirit and principle of the present application should be included in the protection scope of the present application.

Claims (10)

1. An electronic device, characterized in that the electronic device comprises: a processor and at least two display screens; the processor is configured to:
obtaining layer source data;
determining the on-off state of each display screen in the at least two display screens;
prohibiting drawing of a layer corresponding to the display screen in a screen-off state based on the layer source data;
drawing a layer corresponding to the display screen in a bright screen state based on the layer source data;
the display screen in the bright screen state is used for displaying the layer corresponding to the display screen in the bright screen state.
2. The electronic device of claim 1, wherein the processor comprises: a central processing unit and a graphics processor;
the central processing unit is used for sending a first storage position of a layer corresponding to the display screen in the bright screen state to the graphic processor and forbidding sending a second storage position of the layer corresponding to the display screen in the screen-off state to the graphic processor;
and the graphic processor is used for drawing a layer corresponding to the display screen in the bright screen state according to the layer source data based on the first storage position sent by the central processing unit, and storing the layer to the first storage position.
3. The electronic device of claim 1, wherein the processor comprises: a central processing unit and a graphics processor;
the central processing unit is used for sending a first drawing instruction for indicating drawing of a layer corresponding to the display screen in the bright screen state to the graphic processor, and forbidding sending a second layer drawing instruction for indicating drawing of a layer corresponding to the display screen in the screen-off state to the graphic processor;
and the graphics processor is used for responding to the first drawing instruction and drawing the layer corresponding to the display screen in the bright screen state based on the layer source data.
4. The electronic device of claim 1, wherein the layer source data comprises: the display screen comprises first sub-layer source data corresponding to the display screen in the screen-off state and second sub-layer source data corresponding to the display screen in the screen-on state, wherein the first sub-layer source data are different from the second sub-layer source data, and the storage position of the first sub-layer source data is different from that of the second sub-layer source data; the processor is configured to:
and forbidding to distribute a storage area for the first sub-layer source data.
5. The electronic device of claim 1, wherein the processor comprises: the system comprises a central processing unit, a graphic processor and a display processor;
the graphic processor is used for drawing a layer corresponding to the display screen in the bright screen state based on the layer source data;
the central processing unit is used for sending the layer corresponding to the display screen in the bright screen state to the display processor;
and the display processor is used for driving the display screen in the bright screen state to display the layer.
6. The electronic device of any of claims 1-5, wherein the processor is configured to:
and drawing a layer corresponding to the display screen in the bright screen state based on the layer source data and the resolution of the display screen in the bright screen state.
7. The electronic device of any of claims 1 to 5,
the at least two display screens include a primary display screen located on a front side of the electronic device and a secondary display screen located on a back side of the electronic device.
8. An electronic device, wherein the electronic device is connected with at least two display devices, each of the display devices comprising at least one display screen; the electronic device includes: a processor to:
obtaining layer source data;
determining the on-off state of each display screen;
prohibiting drawing of a layer corresponding to the display screen in a screen-off state based on the layer source data;
drawing a layer corresponding to the display screen in a bright screen state based on the layer source data;
and sending the layer to the display equipment to which the display screen in the bright screen state belongs.
9. A method for drawing a layer of an electronic device, the method comprising:
obtaining layer source data;
determining the on-off state of each display screen in at least two display screens;
prohibiting drawing of a layer corresponding to the display screen in a screen-off state based on the layer source data;
drawing a layer corresponding to the display screen in the bright screen state based on the layer source data, and displaying the layer corresponding to the display screen in the bright screen state on the display screen in the bright screen state.
10. The method of claim 9, wherein the electronic device comprises a graphics processor; the prohibiting drawing of the layer corresponding to the display screen in the screen-off state based on the layer source data includes:
and forbidding sending the second storage position of the layer corresponding to the display screen in the screen-off state to the graphics processor.
CN202010974851.1A 2020-09-16 2020-09-16 Electronic equipment and layer drawing method thereof Pending CN112083905A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010974851.1A CN112083905A (en) 2020-09-16 2020-09-16 Electronic equipment and layer drawing method thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010974851.1A CN112083905A (en) 2020-09-16 2020-09-16 Electronic equipment and layer drawing method thereof

Publications (1)

Publication Number Publication Date
CN112083905A true CN112083905A (en) 2020-12-15

Family

ID=73737190

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010974851.1A Pending CN112083905A (en) 2020-09-16 2020-09-16 Electronic equipment and layer drawing method thereof

Country Status (1)

Country Link
CN (1) CN112083905A (en)

Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN202217260U (en) * 2011-09-08 2012-05-09 福州瑞芯微电子有限公司 Multiple screen display controller
CN103370924A (en) * 2010-12-10 2013-10-23 尤塔设备Ipr有限公司 Mobile device with user interface
US20150277545A1 (en) * 2014-03-31 2015-10-01 Motorola Mobility, Llc Apparatus and Method for Awakening a Primary Processor Out of Sleep Mode
CN105528113A (en) * 2015-12-30 2016-04-27 深圳市金立通信设备有限公司 Touch control method and terminal based on curved-surface touch screen
CN106791013A (en) * 2016-11-29 2017-05-31 惠州Tcl移动通信有限公司 A kind of display screen response processing method and system based on mobile terminal
CN106933525A (en) * 2017-03-09 2017-07-07 青岛海信移动通信技术股份有限公司 A kind of method and apparatus of display image
CN107333310A (en) * 2017-06-27 2017-11-07 奇酷互联网络科技(深圳)有限公司 Control method, device and the mobile terminal of reselecting network
CN107783749A (en) * 2017-11-09 2018-03-09 青岛海信移动通信技术股份有限公司 A kind of display methods of view data, device and mobile terminal
CN109407817A (en) * 2018-11-01 2019-03-01 Oppo(重庆)智能科技有限公司 Put out control method, device, electronic equipment and the storage medium of screen clock
CN110083324A (en) * 2019-04-30 2019-08-02 华为技术有限公司 Method, apparatus, electronic equipment and the computer storage medium of Image Rendering
CN110347463A (en) * 2019-06-25 2019-10-18 华为技术有限公司 Image processing method, relevant device and computer storage medium
CN110505680A (en) * 2019-08-15 2019-11-26 Oppo(重庆)智能科技有限公司 Control method, device, mobile terminal and the storage medium of mobile terminal
CN110868750A (en) * 2019-11-13 2020-03-06 联想(北京)有限公司 Information processing method and first electronic device

Patent Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103370924A (en) * 2010-12-10 2013-10-23 尤塔设备Ipr有限公司 Mobile device with user interface
CN202217260U (en) * 2011-09-08 2012-05-09 福州瑞芯微电子有限公司 Multiple screen display controller
US20150277545A1 (en) * 2014-03-31 2015-10-01 Motorola Mobility, Llc Apparatus and Method for Awakening a Primary Processor Out of Sleep Mode
CN105528113A (en) * 2015-12-30 2016-04-27 深圳市金立通信设备有限公司 Touch control method and terminal based on curved-surface touch screen
CN106791013A (en) * 2016-11-29 2017-05-31 惠州Tcl移动通信有限公司 A kind of display screen response processing method and system based on mobile terminal
CN106933525A (en) * 2017-03-09 2017-07-07 青岛海信移动通信技术股份有限公司 A kind of method and apparatus of display image
CN107333310A (en) * 2017-06-27 2017-11-07 奇酷互联网络科技(深圳)有限公司 Control method, device and the mobile terminal of reselecting network
CN107783749A (en) * 2017-11-09 2018-03-09 青岛海信移动通信技术股份有限公司 A kind of display methods of view data, device and mobile terminal
CN109407817A (en) * 2018-11-01 2019-03-01 Oppo(重庆)智能科技有限公司 Put out control method, device, electronic equipment and the storage medium of screen clock
CN110083324A (en) * 2019-04-30 2019-08-02 华为技术有限公司 Method, apparatus, electronic equipment and the computer storage medium of Image Rendering
CN110347463A (en) * 2019-06-25 2019-10-18 华为技术有限公司 Image processing method, relevant device and computer storage medium
CN110505680A (en) * 2019-08-15 2019-11-26 Oppo(重庆)智能科技有限公司 Control method, device, mobile terminal and the storage medium of mobile terminal
CN110868750A (en) * 2019-11-13 2020-03-06 联想(北京)有限公司 Information processing method and first electronic device

Similar Documents

Publication Publication Date Title
US20220342850A1 (en) Data transmission method and related device
CN111367456A (en) Communication terminal and display method in multi-window mode
CN112925596B (en) Mobile terminal and display method of display object thereof
CN113419452A (en) Vehicle, control method thereof and mobile terminal
CN113432619A (en) Navigation route display method, vehicle and mobile terminal
CN113709026B (en) Method, device, storage medium and program product for processing instant communication message
CN113038141A (en) Video frame processing method and electronic equipment
CN112769210A (en) Electronic device and charging method thereof
CN113079332B (en) Mobile terminal and screen recording method thereof
CN112992082B (en) Electronic equipment and refreshing method of electronic ink screen thereof
US20230362782A1 (en) Data Sharing Method, Electronic Device, and System
CN112799557B (en) Ink screen display control method, terminal and computer readable storage medium
CN113642010B (en) Method for acquiring data of extended storage device and mobile terminal
CN111399955B (en) Mobile terminal and interface display method of application program thereof
CN112083905A (en) Electronic equipment and layer drawing method thereof
CN114596633A (en) Sitting posture detection method and terminal
CN113760164A (en) Display device and response method of control operation thereof
CN112351144A (en) Mobile terminal and state prompting method thereof
CN114067758A (en) Mobile terminal and image display method thereof
CN112004006A (en) Mobile medical terminal and brightness adjusting method thereof
CN115033199A (en) Mobile terminal and image display method thereof
CN111324255A (en) Application processing method based on double-screen terminal and communication terminal
CN114063945A (en) Mobile terminal and image display method thereof
CN111159734A (en) Communication terminal and multi-application data inter-access processing method
CN111479075B (en) Photographing terminal and image processing method thereof

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination