CN117746762A - Display processing method, device and electronic equipment - Google Patents
Display processing method, device and electronic equipment Download PDFInfo
- Publication number
- CN117746762A CN117746762A CN202311777273.2A CN202311777273A CN117746762A CN 117746762 A CN117746762 A CN 117746762A CN 202311777273 A CN202311777273 A CN 202311777273A CN 117746762 A CN117746762 A CN 117746762A
- Authority
- CN
- China
- Prior art keywords
- frame
- display
- porch
- electronic device
- image
- 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.)
- Granted
Links
- 238000003672 processing method Methods 0.000 title claims abstract description 36
- 230000004044 response Effects 0.000 claims abstract description 27
- 230000004048 modification Effects 0.000 claims abstract description 23
- 238000012986 modification Methods 0.000 claims abstract description 23
- 238000000034 method Methods 0.000 claims description 32
- 238000012545 processing Methods 0.000 claims description 30
- 238000004590 computer program Methods 0.000 claims description 22
- 239000010410 layer Substances 0.000 description 32
- 230000006870 function Effects 0.000 description 10
- 238000007726 management method Methods 0.000 description 10
- 238000004364 calculation method Methods 0.000 description 9
- 238000010586 diagram Methods 0.000 description 9
- 230000001133 acceleration Effects 0.000 description 8
- 230000008859 change Effects 0.000 description 6
- 229920001621 AMOLED Polymers 0.000 description 4
- 230000001186 cumulative effect Effects 0.000 description 4
- 238000010079 rubber tapping Methods 0.000 description 4
- 238000004891 communication Methods 0.000 description 3
- 239000013256 coordination polymer Substances 0.000 description 3
- 230000008878 coupling Effects 0.000 description 3
- 238000010168 coupling process Methods 0.000 description 3
- 238000005859 coupling reaction Methods 0.000 description 3
- 230000005484 gravity Effects 0.000 description 3
- 230000003287 optical effect Effects 0.000 description 3
- 230000008569 process Effects 0.000 description 3
- 230000015572 biosynthetic process Effects 0.000 description 2
- 238000004422 calculation algorithm Methods 0.000 description 2
- 238000013500 data storage Methods 0.000 description 2
- 230000000694 effects Effects 0.000 description 2
- 239000002096 quantum dot Substances 0.000 description 2
- 238000009877 rendering Methods 0.000 description 2
- 238000003786 synthesis reaction Methods 0.000 description 2
- 241000533950 Leucojum Species 0.000 description 1
- 230000002159 abnormal effect Effects 0.000 description 1
- 230000009471 action Effects 0.000 description 1
- 238000013528 artificial neural network Methods 0.000 description 1
- 210000000988 bone and bone Anatomy 0.000 description 1
- 230000000295 complement effect Effects 0.000 description 1
- 230000006835 compression Effects 0.000 description 1
- 238000007906 compression Methods 0.000 description 1
- 239000012792 core layer Substances 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000013467 fragmentation Methods 0.000 description 1
- 238000006062 fragmentation reaction Methods 0.000 description 1
- 230000004927 fusion Effects 0.000 description 1
- 230000003993 interaction Effects 0.000 description 1
- 230000001788 irregular Effects 0.000 description 1
- 239000004973 liquid crystal related substance Substances 0.000 description 1
- 238000010295 mobile communication Methods 0.000 description 1
- 238000005457 optimization Methods 0.000 description 1
- 239000004065 semiconductor Substances 0.000 description 1
- 230000003238 somatosensory effect Effects 0.000 description 1
- 230000006641 stabilisation Effects 0.000 description 1
- 238000011105 stabilization Methods 0.000 description 1
- 230000003068 static effect Effects 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
Landscapes
- Control Of Indicators Other Than Cathode Ray Tubes (AREA)
Abstract
本申请公开了一种显示处理方法、装置及电子设备。电子设备退出待机idle状态时,确定第一时长T1,T1的起点t1是第一帧的垂直同步Vsync信号对应的时间戳,T1的终点t2是第二帧中显示驱动最早能够修改消隐区porch的时刻对应的时间戳;根据T1确定T2;T1=n*T+T2,T=1/f1;在T2<V1时,在t4时刻执行修改porch的操作;V1是在满足修改porch和硬件接口DSI响应cmd命令都在第二帧内完成时,修改porch的最迟时刻t3与第二帧的Vsync信号对应的时间戳对应的时长;t2≤t4≤t3。基于本申请的方案,电子设备能够在退出待机状态、并且待显示的图像的帧率变化时避免花屏。
This application discloses a display processing method, device and electronic equipment. When the electronic device exits the standby idle state, the first duration T1 is determined. The starting point t1 of T1 is the timestamp corresponding to the vertical synchronization Vsync signal of the first frame. The end point t2 of T1 is the earliest time the display driver can modify the blanking zone porch in the second frame. The timestamp corresponding to the time; determine T2 according to T1; T1=n*T+T2, T=1/f1; when T2<V1, perform the operation of modifying the porch at time t4; V1 is when the modification of the porch and hardware interface are satisfied When the DSI response to the cmd command is completed within the second frame, modify the duration corresponding to the latest time t3 of the porch and the timestamp corresponding to the Vsync signal of the second frame; t2 ≤ t4 ≤ t3. Based on the solution of this application, the electronic device can avoid screen blur when exiting the standby state and the frame rate of the image to be displayed changes.
Description
技术领域Technical field
本申请涉及视频播放技术领域,更具体地,涉及一种显示处理方法、装置及电子设备。The present application relates to the technical field of video playback, and more specifically, to a display processing method, device and electronic equipment.
背景技术Background technique
花屏是指显示器屏幕上出现不规则的条纹、雪花或其他异常画面的现象。在电子设备退出待机idle状态、并且待显示图像的频率与待机状态时的频率不同时,电子设备的显示屏有时会出现花屏现象,影响显示效果。Fragmentation refers to the phenomenon of irregular stripes, snowflakes or other abnormal images appearing on the monitor screen. When the electronic device exits the idle state and the frequency of the image to be displayed is different from the frequency in the standby state, the display screen of the electronic device may sometimes appear blurred, affecting the display effect.
因此如何避免花屏是亟待解决的问题。Therefore, how to avoid screen blur is an issue that needs to be solved urgently.
发明内容Contents of the invention
本申请提供了一种显示处理方法、装置及电子设备,能够在电子设备退出待机状态、并且率变化时避免花屏。This application provides a display processing method, device and electronic equipment, which can avoid screen blur when the electronic equipment exits the standby state and the display rate changes.
第一方面,提供了一种显示处理方法,应用于电子设备,所述电子设备的显示屏以第一帧率f1处于待机idle状态,所述方法包括:在有图像更新时,退出idle状态,所述更新的图像对应的帧率为第二帧率f2,所述f2≠f1;确定第一时长T1,所述T1的起点t1是第一帧的垂直同步Vsync信号对应的时间戳,所述第一帧是所述电子设备进入idle状态的那一帧;所述T1的终点t2是第二帧中显示驱动最早能够修改消隐区porch的时刻对应的时间戳,所述第二帧是所述电子设备退出idle状态的那一帧;根据所述T1确定T2;其中,所述T1=n*T+T2,所述T=1/f1,所述n为整数,n≥0,0<T2<T;在所述T2<V1时,在t4时刻执行所述修改porch的操作;所述V1是在满足修改porch和硬件接口DSI响应cmd命令都在所述第二帧内完成时,修改porch的最迟时刻t3与所述第二帧的Vsync信号对应的时间戳对应的时长;其中,t2≤t4≤t3。In a first aspect, a display processing method is provided, which is applied to an electronic device. The display screen of the electronic device is in an idle state at a first frame rate f1. The method includes: exiting the idle state when there is an image update, The frame rate corresponding to the updated image is the second frame rate f2, and f2≠f1; determine the first duration T1, and the starting point t1 of T1 is the timestamp corresponding to the vertical synchronization Vsync signal of the first frame, and the The first frame is the frame when the electronic device enters the idle state; the end point t2 of T1 is the timestamp corresponding to the earliest moment in the second frame when the display driver can modify the blanking area porch, and the second frame is the The frame in which the electronic device exits the idle state; determine T2 according to the T1; wherein, the T1=n*T+T2, the T=1/f1, the n is an integer, n≥0, 0< T2<T; when T2<V1, the operation of modifying the porch is performed at time t4; the V1 is modified when the modification of the porch and the hardware interface DSI response cmd command are both completed in the second frame. The duration corresponding to the latest time t3 of the porch and the timestamp corresponding to the Vsync signal of the second frame; where, t2≤t4≤t3.
采用该技术方案进行显示处理时,修改porch的操作和DSI响应cmd命令在同一帧内完成,这样能够在电子设备退出待机状态、并且待显示的图像的帧率变化时避免花屏。When using this technical solution for display processing, the operation of modifying the porch and the DSI response to the cmd command are completed in the same frame. This can avoid screen blur when the electronic device exits the standby state and the frame rate of the image to be displayed changes.
在另一种可能的实现方式中,所述方法还包括:在所述T2<V1时,在所述第二帧的下一帧,使所述显示屏以所述f2显示图像。In another possible implementation, the method further includes: when T2 < V1, causing the display screen to display an image with f2 in the next frame of the second frame.
在另一种可能的实现方式中,在所述T2≥V1时,在t6时刻执行所述修改porch的操作,所述t6在第三帧内,所述第三帧是所述第二帧相邻的下一帧,所述第三帧的Vsync信号对应的时间戳是t5,t5=t3+(T-V1);t6=t5+T3,所述TVSYNC+TVBP<T3<V1,所述TVSYNC是所述第三帧的Vsync信号对于的时长,所述TVBP是所述第三帧的垂直消隐区的后肩对应的时长。In another possible implementation, when T2 ≥ V1, the operation of modifying the porch is performed at time t6, where t6 is within the third frame, and the third frame is the phase of the second frame. In the next adjacent frame, the timestamp corresponding to the Vsync signal of the third frame is t5, t5=t3+(T-V1); t6=t5+T3, the T VSYNC + T VBP <T3 <V1, the T VSYNC is the duration of the Vsync signal of the third frame, and T VBP is the duration corresponding to the trailing shoulder of the vertical blanking zone of the third frame.
在另一种可能的实现方式中,所述方法还包括:在所述T2≥V1时,在所述第三帧的下一帧,使所述显示屏以所述f2显示图像。In another possible implementation, the method further includes: when T2≥V1, causing the display screen to display an image with f2 in the next frame of the third frame.
在另一种可能的实现方式中,所述根据所述T1确定T2,包括:确定所述f1与1000的最大公约数为x,y=1000/x;确定T2=(b%(y*1000)%T,其中,T1=a(秒)+b(微秒);在所述根据所述T1确定T2之后的步骤中所述T2的值使用该步骤确定的所述T2的值。In another possible implementation, determining T2 based on T1 includes: determining that the greatest common divisor between f1 and 1000 is x, y=1000/x; determining T2=(b%(y*1000 )%T, where T1 = a (second) + b (microsecond); in the step after determining T2 based on T1, the value of T2 uses the value of T2 determined in this step.
第二方面,提供了一种显示处理装置,应用于电子设备,所述电子设备的显示屏以第一帧率f1处于待机idle状态,所述装置包括:第一处理单元,用于在有图像更新时,退出idle状态,所述更新的图像对应的帧率为第二帧率f2,所述f2≠f1;第一确定单元,用于确定第一时长T1,所述T1的起点t1是第一帧的垂直同步Vsync信号对应的时间戳,所述第一帧是所述电子设备进入idle状态的那一帧;所述T1的终点t2是第二帧中显示驱动最早能够修改消隐区porch的时刻对应的时间戳,所述第二帧是所述电子设备退出idle状态的那一帧;第二确定单元,用于根据所述T1确定T2;其中,理论上所述T1=n*T+T2,所述T=1/f1,所述n为整数,n≥0,0<T2<T;修改单元,用于在所述T2<V1时,在t4时刻执行所述修改porch的操作;所述V1是在满足修改porch和硬件接口DSI响应cmd命令都在所述第二帧内完成时,修改porch的最迟时刻t3与所述第二帧的Vsync信号对应的时间戳对应的时长;其中,t2≤t4≤t3。In a second aspect, a display processing device is provided, which is applied to an electronic device. The display screen of the electronic device is in a standby idle state at a first frame rate f1. The device includes: a first processing unit, configured to perform processing when there is an image. When updating, exit the idle state, the frame rate corresponding to the updated image is the second frame rate f2, and f2≠f1; the first determination unit is used to determine the first duration T1, and the starting point t1 of T1 is the second frame rate f2. The timestamp corresponding to the vertical synchronization Vsync signal of one frame. The first frame is the frame when the electronic device enters the idle state; the end point t2 of T1 is the earliest time the display driver can modify the blanking area porch in the second frame. The timestamp corresponding to the moment, the second frame is the frame when the electronic device exits the idle state; the second determination unit is used to determine T2 according to the T1; wherein, theoretically, the T1=n*T +T2, the T=1/f1, the n is an integer, n≥0, 0<T2<T; the modification unit is used to perform the operation of modifying the porch at the t4 moment when the T2<V1 ; The V1 is the duration corresponding to the latest time t3 of modifying the porch and the timestamp corresponding to the Vsync signal of the second frame when both the modification of the porch and the hardware interface DSI response cmd command are completed in the second frame. ; Among them, t2≤t4≤t3.
在另一种可能的实现方式中,所述装置还包括:第一显示单元,用于在所述T2<V1时,在所述第二帧的下一帧,以所述f2显示图像。In another possible implementation, the device further includes: a first display unit configured to display an image with f2 in the next frame of the second frame when T2 <V1.
在另一种可能的实现方式中,所述修改单元还用于,在所述T2≥V1时,在t6时刻执行所述修改porch的操作,所述t6在第三帧内,所述第三帧是所述第二帧相邻的下一帧,所述第三帧的Vsync信号对应的时间戳是t5,t5=t3+(T-V1);t6=t5+T3,所述TVSYNC+TVBP<T3<V1,所述TVSYNC是所述第三帧的Vsync信号对于的时长,所述TVBP是所述第三帧的垂直消隐区的后肩对应的时长。In another possible implementation, the modification unit is further configured to, when T2≥V1, perform the operation of modifying the porch at time t6, where t6 is within the third frame, and the third The frame is the next frame adjacent to the second frame, and the timestamp corresponding to the Vsync signal of the third frame is t5, t5=t3+(T-V1); t6=t5+T3, and T VSYNC +T VBP < T3 < V1, the T VSYNC is the duration of the Vsync signal of the third frame, and the T VBP is the duration corresponding to the trailing shoulder of the vertical blanking zone of the third frame.
在另一种可能的实现方式中,所述装置还包括:第二显示单元,用于在所述T2≥V1时,在所述第三帧的下一帧,以所述f2显示图像。In another possible implementation, the device further includes: a second display unit configured to display the image in f2 in the next frame of the third frame when T2≥V1.
在另一种可能的实现方式中,在根据所述T1确定T2方面,所述第二确定单元具体用于,确定所述f1与1000的最大公约数为x,y=1000/x;确定T2=(b%(y*1000)%T,其中,T1=a(秒)+b(微秒);所述修改单元中所述T2的值使用该步骤确定的所述T2的值。In another possible implementation, in determining T2 based on T1, the second determination unit is specifically configured to determine that the greatest common divisor of f1 and 1000 is x, y=1000/x; determine T2 =(b%(y*1000)%T, where T1=a(second)+b(microsecond); the value of T2 in the modification unit uses the value of T2 determined in this step.
第三方面,提供了一种电子设备,所述电子设备包括处理器、显示器和存储器,所述存储器用于存储计算机程序,所述显示器用于显示图像,所述处理器用于从所述存储器中调用并运行所述计算机程序,使得所述处理器执行上述第一方面或者第一方面的任一种可能实现方式所述的显示处理方法。In a third aspect, an electronic device is provided. The electronic device includes a processor, a display and a memory. The memory is used to store a computer program. The display is used to display images. The processor is used to retrieve images from the memory. The computer program is called and run, so that the processor executes the display processing method described in the first aspect or any possible implementation of the first aspect.
第四方面,提供了一种芯片,包括处理器,当所述处理器执行指令时,所述处理器执行如上述第一方面或者第一方面的任一种可能实现方式所述的显示处理方法。In a fourth aspect, a chip is provided, including a processor. When the processor executes instructions, the processor executes the display processing method as described in the above first aspect or any possible implementation of the first aspect. .
第五方面,提供了一种计算机可读存储介质,所述计算机可读存储介质存储了计算机程序,当所述计算机程序被处理器执行时,使得处理器执行上述第一方面或者第一方面的任一种可能实现方式所述的显示处理方法。In a fifth aspect, a computer-readable storage medium is provided. The computer-readable storage medium stores a computer program. When the computer program is executed by a processor, it causes the processor to execute the above-mentioned first aspect or the method of the first aspect. Any possible implementation of the display processing method.
在本申请的实施例中,电子设备在进行显示处理时,电子设备的显示屏以第一帧率f1处于待机idle状态,在有图像更新时,退出idle状态,更新的图像对应的帧率变为f2,f2≠f1;然后,确定第一时长T1,T1的起点t1是第一帧的垂直同步Vsync信号对应的时间戳,第一帧是电子设备进入idle状态的那一帧;T1的终点t2是第二帧中显示驱动最早能够修改消隐区porch的时刻对应的时间戳,第二帧是电子设备退出idle状态的那一帧;根据T1确定T2;T1=n*T+T2,T=1/f1,n为整数,n≥0,0<T2<T;在T2<V1时,在t4时刻执行修改porch的操作;V1是在满足修改porch和硬件接口DSI响应cmd命令都在第二帧内完成时,修改porch的最迟时刻t3与第二帧的Vsync信号对应的时间戳对应的时长;t2≤t4≤t3,V3≤V2。采用该方案时,由于修改porch的操作和DSI响应cmd命令在同一帧内完成,这样能够使电子设备在退出待机状态、并且待显示的图像的帧率变化时避免花屏。In the embodiment of the present application, when the electronic device is performing display processing, the display screen of the electronic device is in the standby idle state at the first frame rate f1. When there is an image update, the idle state is exited, and the frame rate corresponding to the updated image becomes is f2, f2≠f1; then, determine the first duration T1. The starting point of T1 is the timestamp corresponding to the vertical synchronization Vsync signal of the first frame. The first frame is the frame when the electronic device enters the idle state; the end point of T1 t2 is the timestamp corresponding to the earliest moment in the second frame when the display driver can modify the blanking zone porch. The second frame is the frame when the electronic device exits the idle state; T2 is determined based on T1; T1=n*T+T2, T =1/f1, n is an integer, n≥0, 0<T2<T; when T2<V1, the operation of modifying the porch is performed at time t4; V1 is when the modification of the porch and the hardware interface DSI response cmd command are both in the first When completed within two frames, modify the duration corresponding to the latest time t3 of the porch and the timestamp corresponding to the Vsync signal of the second frame; t2 ≤ t4 ≤ t3, V3 ≤ V2. When using this solution, since the operation of modifying the porch and the DSI response to the cmd command are completed in the same frame, this can prevent the electronic device from being blurred when it exits the standby state and the frame rate of the image to be displayed changes.
附图说明Description of drawings
图1是现有技术中电子设备出现花屏的示意图;Figure 1 is a schematic diagram of a blurred screen in an electronic device in the prior art;
图2A是每帧图像垂直方向消隐区的后肩、有效区域、消隐区的前肩分别对应的时长示意图;Figure 2A is a schematic diagram of the corresponding durations of the rear shoulder of the blanking area, the effective area, and the front shoulder of the blanking area in the vertical direction of each frame of image;
图2B是Video屏处理流程示意图;Figure 2B is a schematic diagram of the Video screen processing flow;
图3A是本申请一实施例提供的显示处理方法的流程示意图;Figure 3A is a schematic flowchart of a display processing method provided by an embodiment of the present application;
图3B是本申请另一实施例提供的显示处理方法的流程示意图;Figure 3B is a schematic flowchart of a display processing method provided by another embodiment of the present application;
图4A是本申请另一实施例提供的显示处理方法的流程示意图;Figure 4A is a schematic flowchart of a display processing method provided by another embodiment of the present application;
图4B是本申请另一实施例提供的显示处理方法的流程示意图;Figure 4B is a schematic flowchart of a display processing method provided by another embodiment of the present application;
图5A是本申请一实施例提供的显示处理方法对应的包括相关时间节点的时序示意图;Figure 5A is a timing diagram including relevant time nodes corresponding to the display processing method provided by an embodiment of the present application;
图5B是本申请一实施例提供的显示处理方法对应的包括相关时间节点的时序示意图;Figure 5B is a timing diagram including relevant time nodes corresponding to the display processing method provided by an embodiment of the present application;
图5C是本申请一实施例提供的显示处理方法对应的包括相关时间节点的时序示意图;Figure 5C is a timing diagram including relevant time nodes corresponding to the display processing method provided by an embodiment of the present application;
图5D是本申请一实施例提供的显示处理方法对应的包括相关时间节点的时序示意图;Figure 5D is a timing diagram including relevant time nodes corresponding to the display processing method provided by an embodiment of the present application;
图6是执行本申请实施例提供的显示处理方法的电子设备的结构示意图;Figure 6 is a schematic structural diagram of an electronic device that executes a display processing method provided by an embodiment of the present application;
图7执行本申请实施例提供的显示处理方法的电子设备的软件系统的示意图。FIG. 7 is a schematic diagram of a software system of an electronic device that executes the display processing method provided by an embodiment of the present application.
具体实施方式Detailed ways
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by those of ordinary skill in the art without creative efforts fall within the scope of protection of this application.
首先,结合附图对本申请实施例提供的显示处理方法的应用场景进行介绍。First, the application scenarios of the display processing method provided by the embodiments of the present application are introduced with reference to the accompanying drawings.
本申请实施例提供的显示处理方法可以应用在手机等具有Video屏的电子设备,本申请实施例中电子设备以手机为例进行描述,可以理解的,执行本申请提供的显示处理方法的电子设备不限于手机,也可以是其他具有Video屏的终端,电子设备的具体类型这里不做限定。The display processing method provided by the embodiment of the present application can be applied to electronic devices with video screens such as mobile phones. In the embodiment of the present application, the electronic device is described using a mobile phone as an example. It can be understood that the electronic device that performs the display processing method provided by the present application It is not limited to mobile phones, but can also be other terminals with video screens. The specific type of electronic equipment is not limited here.
手机超过预设时长未被操作时,为了省电,手机进入待机状态。在待机状态时,若检测到预设的退idle事件,比如用户滑动手机显示屏,则电子设备退出待机状态,在退idle状态时,手机偶尔会出现短暂的花屏现象,花屏时手机显示区显示的图像如图1所示。When the phone has not been operated for a preset period of time, the phone enters standby mode to save power. In the standby state, if a preset idle exit event is detected, such as the user sliding the mobile phone display, the electronic device will exit the standby state. When exiting the idle state, the phone will occasionally have a brief screen blur phenomenon. When the screen blur occurs, the display area of the phone will display The image is shown in Figure 1.
如图2A所示,每帧图像垂直方向的同步信号是Vsync,周期为T、消隐区的后肩、有效区域、消隐区的前肩分别对应的时长分别为TVBP、TDE、TVFP。As shown in Figure 2A, the synchronization signal in the vertical direction of each frame of image is Vsync, with a period of T. The corresponding durations of the back shoulder of the blanking area, the effective area, and the front shoulder of the blanking area are T VBP , T DE , and T respectively. VFP .
如图2B所示,手机显示图像的流程通常包括如下步骤:应用程序(Application,APP)获取待显示的内容,Surfaceflinger服务将待显示内容合成为待显示页面,硬件混合渲染器(Hardware Composer,HWC)对带显示页面进行格式转换,输出送给显示驱动,显示驱动做一些底层的编解码、压缩等操作把图加载完存到它的buffer中,然后通过显示串行接口(Display serial interface,dsi)的移动行业处理器接口(Mobile IndustryProcessor Interface,mipi)送到显示驱动芯片(Display Driver IC,DDIC)。Vsync是每一帧的帧同步信号,显示编号为1的图像后显示编号为2的图像,在显示编号为2的图像后,若手机处于待机状态时,则上层不再传输新的图像,dsi硬件继续向DDIC传输缓存中存储的标识为2的图像,在待机状态结束后,上层继续接收新的图像并传输和显示。As shown in Figure 2B, the process of displaying images on a mobile phone usually includes the following steps: the application (Application, APP) obtains the content to be displayed, the Surfaceflinger service synthesizes the content to be displayed into the page to be displayed, and the hardware hybrid renderer (Hardware Composer, HWC) ) Converts the format of the page with display, and sends the output to the display driver. The display driver does some underlying encoding, decoding, compression and other operations to load the image and save it into its buffer, and then through the display serial interface (dsi) )'s Mobile Industry Processor Interface (mipi) is sent to the display driver chip (Display Driver IC, DDIC). Vsync is the frame synchronization signal of each frame. After displaying the image numbered 1, the image numbered 2 is displayed. After displaying the image numbered 2, if the mobile phone is in standby state, the upper layer will no longer transmit new images, dsi The hardware continues to transmit the image identified as 2 stored in the cache to the DDIC. After the standby state ends, the upper layer continues to receive new images, transmit and display them.
需要说明的是,video屏在显示图像的帧率变化时,video屏的显示相应地发生变化。具体实现时,包括两种方法,一种是high切换,一种是real切换,为就减少功耗,本申请采用的是real切换,在帧率切换时,需要完成修改porch和发送cmd的命令。It should be noted that when the frame rate of the image displayed on the video screen changes, the display of the video screen changes accordingly. The specific implementation includes two methods, one is high switching and the other is real switching. In order to reduce power consumption, this application uses real switching. When switching the frame rate, it is necessary to complete the modification of the porch and send cmd commands. .
图3A是本申请实施例提供的显示处理方法的流程示意图。如图3A所示,本申请实施例提供的显示处理方法包括步骤:301至304。下面,对步骤301至304进行详细介绍,该实施例应用于电子设备,电子设备的显示屏以第一帧率f1处于待机idle状态,所述方法包括:FIG. 3A is a schematic flowchart of a display processing method provided by an embodiment of the present application. As shown in Figure 3A, the display processing method provided by the embodiment of the present application includes steps: 301 to 304. Next, steps 301 to 304 are introduced in detail. This embodiment is applied to electronic equipment. The display screen of the electronic equipment is in the standby idle state at the first frame rate f1. The method includes:
301.在有图像更新时,退出idle状态,所述更新的图像对应的帧率为第二帧率f2,所述f2≠f1。301. When there is an image update, exit the idle state. The frame rate corresponding to the updated image is the second frame rate f2, and f2≠f1.
302.确定第一时长T1,T1的起点t1是第一帧的垂直同步Vsync信号对应的时间戳,第一帧是电子设备进入idle状态的那一帧;T1的终点t2是第二帧中显示驱动最早能够修改消隐区porch的时刻对应的时间戳,第二帧是电子设备退出idle状态的那一帧。302. Determine the first duration T1. The starting point t1 of T1 is the timestamp corresponding to the vertical synchronization Vsync signal of the first frame. The first frame is the frame when the electronic device enters the idle state; the end point t2 of T1 is the time displayed in the second frame. The earliest timestamp corresponding to the time when the driver can modify the blanking zone porch, and the second frame is the frame when the electronic device exits the idle state.
303.根据T1确定T2;其中,T1=n*T+T2,T=1/f1,n为整数,n≥0,0<T2<T。303. Determine T2 based on T1; where, T1=n*T+T2, T=1/f1, n is an integer, n≥0, 0<T2<T.
由于计算机是浮点计算,不可能精确到无限多位数,所以在实际计算中T1=n*T+T2是一个理论值,在T为无限循环数、或者无限不循环数时,n值越大累计误差越大,为了减少误差,可以采用如下方式确定T2。确定f1与1000的最大公约数为x,y=1000/x;确定T2=(b%(y*1000)%T,其中,T1=a(秒)+b(微秒);在根据T1确定T2之后的步骤中T2的值使用该步骤确定的T2的值。Since the computer uses floating point calculations, it is impossible to be accurate to an infinite number of digits. Therefore, in actual calculations, T1=n*T+T2 is a theoretical value. When T is an infinite loop number or an infinite non-loop number, the value of n exceeds The larger the cumulative error, the greater the error. In order to reduce the error, the following method can be used to determine T2. Determine the greatest common divisor between f1 and 1000 as x, y=1000/x; determine T2=(b%(y*1000)%T, where T1=a (second)+b (microsecond); determine based on T1 The value of T2 in the step after T2 uses the value of T2 determined in that step.
304.在T2<V1时,在t4时刻执行修改porch的操作;V1是在满足修改porch和硬件接口DSI响应cmd命令都在第二帧内完成时,修改porch的最迟时刻t3与第二帧的Vsync信号对应的时间戳对应的时长;其中,t2≤t4≤t3。304. When T2 < V1, perform the operation of modifying the porch at time t4; V1 is when the modification of the porch and the hardware interface DSI response cmd command are completed in the second frame, the latest time of modifying the porch is t3 and the second frame The duration corresponding to the timestamp corresponding to the Vsync signal; among them, t2≤t4≤t3.
举例来说,在一种可能的实现方式中,如图5A所示,在该实施例中T2<V1,t4=t2,在该实施例中修改porch和硬件接口DSI响应cmd命令都在同一帧内完成。For example, in a possible implementation, as shown in Figure 5A, in this embodiment T2 < V1, t4 = t2. In this embodiment, the modified porch and the hardware interface DSI response to the cmd command are both in the same frame. Completed within.
举例来说,在另一种可能的实现方式中,如图5B所示,在该实施例中T2<V1,t4=t3,在该实施例中修改porch和硬件接口DSI响应cmd命令都在同一帧内完成。For example, in another possible implementation, as shown in Figure 5B, in this embodiment T2 < V1, t4 = t3. In this embodiment, the modification of the porch and the hardware interface DSI response to the cmd command are both in the same Completed within the frame.
举例来说,在另一种可能的实现方式中,如图5C所示,在该实施例中T2<V1,t2<t4<t3,在该实施例中修改porch和硬件接口DSI响应cmd命令都在同一帧内完成。For example, in another possible implementation, as shown in Figure 5C, in this embodiment, T2<V1, t2<t4<t3, in this embodiment, both the modified porch and the hardware interface DSI respond to the cmd command. Done within the same frame.
采用该技术方案进行显示处理时,修改porch的操作和DSI响应cmd命令在同一帧内完成,这样能够在电子设备退出待机状态、并且待显示的图像的帧率变化时避免花屏。When using this technical solution for display processing, the operation of modifying the porch and the DSI response to the cmd command are completed in the same frame. This can avoid screen blur when the electronic device exits the standby state and the frame rate of the image to be displayed changes.
请参见图3B,图3B是本申请另一实施例提供的显示处理方法的流程示意图。如图3B所示,本申请实施例提供的显示处理方法包括步骤:301至305。下面,对步骤301至305进行详细介绍。Please refer to FIG. 3B. FIG. 3B is a schematic flowchart of a display processing method provided by another embodiment of the present application. As shown in Figure 3B, the display processing method provided by the embodiment of the present application includes steps: 301 to 305. Next, steps 301 to 305 are introduced in detail.
301.在有图像更新时,退出idle状态,所述更新的图像对应的帧率为第二帧率f2,所述f2≠f1。301. When there is an image update, exit the idle state. The frame rate corresponding to the updated image is the second frame rate f2, and f2≠f1.
302.确定第一时长T1,T1的起点t1是第一帧的垂直同步Vsync信号对应的时间戳,第一帧是电子设备进入idle状态的那一帧;T1的终点t2是第二帧中显示驱动最早能够修改消隐区porch的时刻对应的时间戳,第二帧是电子设备退出idle状态的那一帧。302. Determine the first duration T1. The starting point t1 of T1 is the timestamp corresponding to the vertical synchronization Vsync signal of the first frame. The first frame is the frame when the electronic device enters the idle state; the end point t2 of T1 is the time displayed in the second frame. The earliest timestamp corresponding to the time when the driver can modify the blanking zone porch, and the second frame is the frame when the electronic device exits the idle state.
303.根据T1确定T2;其中,T1=n*T+T2,T=1/f1,n为整数,n≥0,0<T2<T。303. Determine T2 based on T1; where, T1=n*T+T2, T=1/f1, n is an integer, n≥0, 0<T2<T.
由于计算机是浮点计算,不可能精确到无限多位数,所以在实际计算中T1=n*T+T2是一个理论值,在T为无限循环数、或者无限不循环数时,n值越大累计误差越大,为了减少误差,可以采用如下方式确定T2。确定f1与1000的最大公约数为x,y=1000/x;确定T2=(b%(y*1000)%T,其中,T1=a(秒)+b(微秒);在根据T1确定T2之后的步骤中T2的值使用该步骤确定的T2的值。Since the computer uses floating point calculations, it is impossible to be accurate to an infinite number of digits. Therefore, in actual calculations, T1=n*T+T2 is a theoretical value. When T is an infinite loop number or an infinite non-loop number, the value of n exceeds The larger the cumulative error, the greater the error. In order to reduce the error, the following method can be used to determine T2. Determine the greatest common divisor between f1 and 1000 as x, y=1000/x; determine T2=(b%(y*1000)%T, where T1=a (second)+b (microsecond); determine based on T1 The value of T2 in the step after T2 uses the value of T2 determined in that step.
304.在T2<V1时,在t4时刻执行修改porch的操作;V1是在满足修改porch和硬件接口DSI响应cmd命令都在第二帧内完成时,修改porch的最迟时刻t3与第二帧的Vsync信号对应的时间戳对应的时长;其中,t2≤t4≤t3。304. When T2 < V1, perform the operation of modifying the porch at time t4; V1 is when the modification of the porch and the hardware interface DSI response cmd command are completed in the second frame, the latest time of modifying the porch is t3 and the second frame The duration corresponding to the timestamp corresponding to the Vsync signal; among them, t2≤t4≤t3.
举例来说,在一种可能的实现方式中,如图5A所示,在该实施例中T2<V1,t4=t2,在该实施例中修改porch和硬件接口DSI响应cmd命令都在同一帧内完成。For example, in a possible implementation, as shown in Figure 5A, in this embodiment T2 < V1, t4 = t2. In this embodiment, the modified porch and the hardware interface DSI response to the cmd command are both in the same frame. Completed within.
举例来说,在另一种可能的实现方式中,如图5B所示,在该实施例中T2<V1,t4=t3,在该实施例中修改porch和硬件接口DSI响应cmd命令都在同一帧内完成。For example, in another possible implementation, as shown in Figure 5B, in this embodiment T2 < V1, t4 = t3. In this embodiment, the modification of the porch and the hardware interface DSI response to the cmd command are both in the same Completed within the frame.
举例来说,在另一种可能的实现方式中,如图5C所示,在该实施例中T2<V1,t2<t4<t3,在该实施例中修改porch和硬件接口DSI响应cmd命令都在同一帧内完成。For example, in another possible implementation, as shown in Figure 5C, in this embodiment, T2<V1, t2<t4<t3, in this embodiment, both the modified porch and the hardware interface DSI respond to the cmd command. Done within the same frame.
305.在T2<V1时,在第二帧的下一帧,使显示屏以帧率f2显示图像。305. When T2 < V1, in the next frame of the second frame, make the display screen display the image at the frame rate f2.
采用该技术方案进行显示处理时,修改porch的操作和DSI响应cmd命令在同一帧内完成,这样能够在电子设备退出待机状态、并且待显示的图像的帧率变化时避免花屏;另外,在第二帧的下一帧,使显示屏以帧率f2显示图像,可以尽早将显示屏以新的帧率显示图像。When using this technical solution for display processing, the operation of modifying the porch and the DSI response to the cmd command are completed in the same frame, which can avoid screen blur when the electronic device exits the standby state and the frame rate of the image to be displayed changes; in addition, in the second In the next frame of the second frame, the display screen displays the image at the frame rate f2, and the display screen can display the image at the new frame rate as soon as possible.
请参见图4A,图4A是本申请另一实施例提供的显示处理方法的流程示意图。如图4A所示,本申请实施例提供的显示处理方法包括步骤:401至406。下面,对步骤401至406进行详细介绍。Please refer to FIG. 4A , which is a schematic flowchart of a display processing method provided by another embodiment of the present application. As shown in Figure 4A, the display processing method provided by the embodiment of the present application includes steps: 401 to 406. Next, steps 401 to 406 are introduced in detail.
401.在有图像更新时,退出idle状态,所述更新的图像对应的帧率为第二帧率f2,所述f2≠f1。401. When there is an image update, exit the idle state. The frame rate corresponding to the updated image is the second frame rate f2, and f2≠f1.
402.确定第一时长T1,T1的起点t1是第一帧的垂直同步Vsync信号对应的时间戳,第一帧是电子设备进入idle状态的那一帧;T1的终点t2是第二帧中显示驱动最早能够修改消隐区porch的时刻对应的时间戳,第二帧是电子设备退出idle状态的那一帧。402. Determine the first duration T1. The starting point t1 of T1 is the timestamp corresponding to the vertical synchronization Vsync signal of the first frame. The first frame is the frame when the electronic device enters the idle state; the end point t2 of T1 is the time displayed in the second frame. The earliest timestamp corresponding to the time when the driver can modify the blanking zone porch, and the second frame is the frame when the electronic device exits the idle state.
403.根据T1确定T2;其中,T1=n*T+T2,T=1/f1,n为整数,n≥0,0<T2<T。403. Determine T2 based on T1; where, T1=n*T+T2, T=1/f1, n is an integer, n≥0, 0<T2<T.
由于计算机是浮点计算,不可能精确到无限多位数,所以在实际计算中T1=n*T+T2是一个理论值,在T为无限循环数、或者无限不循环数时,n值越大累计误差越大,为了减少误差,可以采用如下方式确定T2。确定f1与1000的最大公约数为x,y=1000/x;确定T2=(b%(y*1000)%T,其中,T1=a(秒)+b(微秒);在根据T1确定T2之后的步骤中T2的值使用该步骤确定的T2的值。Since the computer uses floating point calculations, it is impossible to be accurate to an infinite number of digits. Therefore, in actual calculations, T1=n*T+T2 is a theoretical value. When T is an infinite loop number or an infinite non-loop number, the value of n exceeds The larger the cumulative error, the greater the error. In order to reduce the error, the following method can be used to determine T2. Determine the greatest common divisor between f1 and 1000 as x, y=1000/x; determine T2=(b%(y*1000)%T, where T1=a (second)+b (microsecond); determine based on T1 The value of T2 in the step after T2 uses the value of T2 determined in that step.
404.判断T2是否小于V1。404. Determine whether T2 is less than V1.
若判断结果为是,则执行步骤405。若判断结果为否,则执行步骤406。If the judgment result is yes, step 405 is executed. If the judgment result is no, step 406 is executed.
405.在t4时刻执行修改porch的操作;V1是在满足修改porch和硬件接口DSI响应cmd命令都在第二帧内完成时,修改porch的最迟时刻t3与第二帧的Vsync信号对应的时间戳对应的时长;t2≤t4≤t3。405. Execute the operation of modifying the porch at time t4; V1 is the time corresponding to the Vsync signal of the second frame at the latest time t3 when modifying the porch and the hardware interface DSI response cmd command are completed in the second frame. The corresponding duration of the stamp; t2≤t4≤t3.
举例来说,在一种可能的实现方式中,如图5A所示,在该实施例中T2<V1,t4=t2,在该实施例中修改porch和硬件接口DSI响应cmd命令都在同一帧内完成。For example, in a possible implementation, as shown in Figure 5A, in this embodiment T2 < V1, t4 = t2. In this embodiment, the modified porch and the hardware interface DSI response to the cmd command are both in the same frame. Completed within.
举例来说,在另一种可能的实现方式中,如图5B所示,在该实施例中T2<V1,t4=t3,在该实施例中修改porch和硬件接口DSI响应cmd命令都在同一帧内完成。For example, in another possible implementation, as shown in Figure 5B, in this embodiment T2 < V1, t4 = t3. In this embodiment, the modification of the porch and the hardware interface DSI response to the cmd command are both in the same Completed within the frame.
举例来说,在另一种可能的实现方式中,如图5C所示,在该实施例中T2<V1,t2<t4<t3,在该实施例中修改porch和硬件接口DSI响应cmd命令都在同一帧内完成。For example, in another possible implementation, as shown in Figure 5C, in this embodiment, T2<V1, t2<t4<t3, in this embodiment, both the modified porch and the hardware interface DSI respond to the cmd command. Done within the same frame.
406.在t6时刻执行修改porch的操作,t6在第三帧内,第三帧是第二帧相邻的下一帧,第三帧的Vsync信号对应的时间戳是t5,t5=t3+(T-V1);t6=t5+T3,TVSYNC+TVBP<T3<V1,TVSYNC是第三帧的Vsync信号对于的时长,TVBP是第三帧的垂直消隐区的后肩对应的时长。406. Execute the operation of modifying the porch at time t6. t6 is in the third frame. The third frame is the next frame adjacent to the second frame. The timestamp corresponding to the Vsync signal of the third frame is t5, t5=t3+(T -V1); t6=t5+T3, T VSYNC +T VBP <T3 <V1, T VSYNC is the duration of the Vsync signal of the third frame, T VBP is the duration corresponding to the back shoulder of the vertical blanking zone of the third frame .
举例来说,在一种可能的实现方式中,如图5D所示,在该实施例中T2>V1,在第三帧内,第三帧是第二帧相邻的下一帧,第三帧的Vsync信号对应的时间戳是t5,t5=t3+(T-V1);t6=t5+T3,TVSYNC+TVBP<T3<V1,TVSYNC是第三帧的Vsync信号对于的时长,TVBP是第三帧的垂直消隐区的后肩对应的时长。在该实施例中修改porch和硬件接口DSI响应cmd命令都在第三帧内完成。For example, in a possible implementation, as shown in Figure 5D, in this embodiment T2>V1, in the third frame, the third frame is the next frame adjacent to the second frame, and the third frame The timestamp corresponding to the Vsync signal of the frame is t5, t5 = t3 + (T-V1); t6 = t5 + T3, T VSYNC + T VBP < T3 < V1, T VSYNC is the duration of the Vsync signal of the third frame, T VBP is the duration corresponding to the trailing shoulder of the vertical blanking zone of the third frame. In this embodiment, modifying the porch and the hardware interface DSI response to the cmd command are both completed in the third frame.
采用该技术方案进行显示处理时,修改porch的操作和DSI响应cmd命令在同一帧内完成,这样能够在电子设备退出待机状态、并且待显示的图像的帧率变化时避免花屏。When using this technical solution for display processing, the operation of modifying the porch and the DSI response to the cmd command are completed in the same frame. This can avoid screen blur when the electronic device exits the standby state and the frame rate of the image to be displayed changes.
请参见图4B,图4B是本申请另一实施例提供的显示处理方法的流程示意图。如图4B所示,本申请实施例提供的显示处理方法包括步骤:401至406。下面,对步骤401至408进行详细介绍。Please refer to FIG. 4B , which is a schematic flowchart of a display processing method provided by another embodiment of the present application. As shown in Figure 4B, the display processing method provided by the embodiment of the present application includes steps: 401 to 406. Next, steps 401 to 408 are introduced in detail.
401.在有图像更新时,退出idle状态,更新的图像对应的帧率为第二帧率f2,f2≠f1。401. When there is an image update, exit the idle state. The frame rate corresponding to the updated image is the second frame rate f2, f2≠f1.
402.确定第一时长T1,T1的起点t1是第一帧的垂直同步Vsync信号对应的时间戳,第一帧是电子设备进入idle状态的那一帧;T1的终点t2是第二帧中显示驱动最早能够修改消隐区porch的时刻对应的时间戳,第二帧是电子设备退出idle状态的那一帧。402. Determine the first duration T1. The starting point t1 of T1 is the timestamp corresponding to the vertical synchronization Vsync signal of the first frame. The first frame is the frame when the electronic device enters the idle state; the end point t2 of T1 is the time displayed in the second frame. The earliest timestamp corresponding to the time when the driver can modify the blanking zone porch, and the second frame is the frame when the electronic device exits the idle state.
403.根据T1确定T2;其中,T1=n*T+T2,T=1/f1,n为整数,n≥0,0<T2<T。403. Determine T2 based on T1; where, T1=n*T+T2, T=1/f1, n is an integer, n≥0, 0<T2<T.
由于计算机是浮点计算,不可能精确到无限多位数,所以在实际计算中T1=n*T+T2是一个理论值,在T为无限循环数、或者无限不循环数时,n值越大累计误差越大,为了减少误差,可以采用如下方式确定T2。确定f1与1000的最大公约数为x,y=1000/x;确定T2=(b%(y*1000)%T,其中,T1=a(秒)+b(微秒);在根据T1确定T2之后的步骤中T2的值使用该步骤确定的T2的值。Since the computer uses floating point calculations, it is impossible to be accurate to an infinite number of digits. Therefore, in actual calculations, T1=n*T+T2 is a theoretical value. When T is an infinite loop number or an infinite non-loop number, the value of n exceeds The larger the cumulative error, the greater the error. In order to reduce the error, the following method can be used to determine T2. Determine the greatest common divisor between f1 and 1000 as x, y=1000/x; determine T2=(b%(y*1000)%T, where T1=a (second)+b (microsecond); determine based on T1 The value of T2 in the step after T2 uses the value of T2 determined in that step.
404.判断T2是否小于V1。404. Determine whether T2 is less than V1.
若判断结果为是,则执行步骤405。若判断结果为否,则执行步骤406。If the judgment result is yes, step 405 is executed. If the judgment result is no, step 406 is executed.
405.在t4时刻执行修改porch的操作;V1是在满足修改porch和硬件接口DSI响应cmd命令都在第二帧内完成时,修改porch的最迟时刻t3与第二帧的Vsync信号对应的时间戳对应的时长;t2≤t4≤t3。405. Execute the operation of modifying the porch at time t4; V1 is the time corresponding to the Vsync signal of the second frame at the latest time t3 when modifying the porch and the hardware interface DSI response cmd command are completed in the second frame. The corresponding duration of the stamp; t2≤t4≤t3.
举例来说,在一种可能的实现方式中,如图5A所示,在该实施例中T2<V1,t4=t2,在该实施例中修改porch和硬件接口DSI响应cmd命令都在同一帧内完成。For example, in a possible implementation, as shown in Figure 5A, in this embodiment T2 < V1, t4 = t2. In this embodiment, the modified porch and the hardware interface DSI response to the cmd command are both in the same frame. Completed within.
举例来说,在另一种可能的实现方式中,如图5B所示,在该实施例中T2<V1,t4=t3,在该实施例中修改porch和硬件接口DSI响应cmd命令都在同一帧内完成。For example, in another possible implementation, as shown in Figure 5B, in this embodiment T2 < V1, t4 = t3. In this embodiment, the modification of the porch and the hardware interface DSI response to the cmd command are both in the same Completed within the frame.
举例来说,在另一种可能的实现方式中,如图5C所示,在该实施例中T2<V1,t2<t4<t3,在该实施例中修改porch和硬件接口DSI响应cmd命令都在同一帧内完成。然后,执行步骤407。For example, in another possible implementation, as shown in Figure 5C, in this embodiment, T2<V1, t2<t4<t3, in this embodiment, both the modified porch and the hardware interface DSI respond to the cmd command. Done within the same frame. Then, step 407 is executed.
406.在t6时刻执行修改porch的操作,t6在第三帧内,第三帧是第二帧相邻的下一帧,第三帧的Vsync信号对应的时间戳是t5,t5=t3+(T-V1);t6=t5+T3,TVSYNC+TVBP<T3<V1,TVSYNC是第三帧的Vsync信号对于的时长,TVBP是第三帧的垂直消隐区的后肩对应的时长。406. Execute the operation of modifying the porch at time t6. t6 is in the third frame. The third frame is the next frame adjacent to the second frame. The timestamp corresponding to the Vsync signal of the third frame is t5, t5=t3+(T -V1); t6=t5+T3, T VSYNC +T VBP <T3 <V1, T VSYNC is the duration of the Vsync signal of the third frame, T VBP is the duration corresponding to the back shoulder of the vertical blanking zone of the third frame .
举例来说,在一种可能的实现方式中,如图5D所示,在该实施例中T2>V1,在第三帧内,第三帧是第二帧相邻的下一帧,第三帧的Vsync信号对应的时间戳是t5,t5=t3+(T-V1);t6=t5+T3,TVSYNC+TVBP<T3<V1,TVSYNC是第三帧的Vsync信号对于的时长,TVBP是第三帧的垂直消隐区的后肩对应的时长。在该实施例中修改porch和硬件接口DSI响应cmd命令都在第三帧内完成,然后执行步骤408。For example, in a possible implementation, as shown in Figure 5D, in this embodiment T2>V1, in the third frame, the third frame is the next frame adjacent to the second frame, and the third frame The timestamp corresponding to the Vsync signal of the frame is t5, t5 = t3 + (T-V1); t6 = t5 + T3, T VSYNC + T VBP < T3 < V1, T VSYNC is the duration of the Vsync signal of the third frame, T VBP is the duration corresponding to the trailing shoulder of the vertical blanking zone of the third frame. In this embodiment, modifying the porch and responding to the cmd command of the hardware interface DSI are both completed in the third frame, and then step 408 is executed.
407.在第二帧的下一帧,使显示屏以帧率f2显示图像。407. In the next frame of the second frame, cause the display screen to display the image at the frame rate f2.
408.在第三帧的下一帧,使显示屏以帧率f2显示图像。408. In the next frame of the third frame, cause the display screen to display the image at the frame rate f2.
采用该技术方案进行显示处理时,修改porch的操作和DSI响应cmd命令在同一帧内完成,这样能够在电子设备退出待机状态、并且待显示的图像的帧率变化时避免花屏;另外,在第二帧的下一帧,使显示屏以帧率f2显示图像,可以尽早将显示屏以新的帧率显示图像。When using this technical solution for display processing, the operation of modifying the porch and the DSI response to the cmd command are completed in the same frame, which can avoid screen blur when the electronic device exits the standby state and the frame rate of the image to be displayed changes; in addition, in the second In the next frame of the second frame, the display screen displays the image at the frame rate f2, and the display screen can display the image at the new frame rate as soon as possible.
与前面方法实施例对应,本申请实施例还提供了一种显示处理装置,应用于电子设备,电子设备的显示屏以第一帧率f1处于待机idle状态,装置包括:第一处理单元、第一确定单元、第二确定单元和修改单元。其中,第一处理单元,用于在有图像更新时,退出idle状态,更新的图像对应的帧率为第二帧率f2,f2≠f1;第一确定单元,用于确定第一时长T1,T1的起点t1是第一帧的垂直同步Vsync信号对应的时间戳,第一帧是电子设备进入idle状态的那一帧;T1的终点t2是第二帧中显示驱动最早能够修改消隐区porch的时刻对应的时间戳,第二帧是电子设备退出idle状态的那一帧;第二确定单元,用于根据T1确定T2;其中,T1=n*T+T2,T=1/f1,n为整数,n≥0,0<T2<T;修改单元,用于在T2<V1时,在t4时刻执行修改porch的操作;V1是在满足修改porch和硬件接口DSI响应cmd命令都在第二帧内完成时,修改porch的最迟时刻t3与第二帧的Vsync信号对应的时间戳对应的时长;其中,t2≤t4≤t3。Corresponding to the previous method embodiments, embodiments of the present application also provide a display processing device, which is applied to electronic equipment. The display screen of the electronic equipment is in the standby idle state at the first frame rate f1. The device includes: a first processing unit, a first a determining unit, a second determining unit and a modifying unit. Among them, the first processing unit is used to exit the idle state when there is an image update, and the frame rate corresponding to the updated image is the second frame rate f2, f2≠f1; the first determination unit is used to determine the first duration T1, The starting point t1 of T1 is the timestamp corresponding to the vertical synchronization Vsync signal of the first frame. The first frame is the frame when the electronic device enters the idle state; the end point t2 of T1 is the earliest time in the second frame that the display driver can modify the blanking zone porch. The timestamp corresponding to the moment, the second frame is the frame when the electronic device exits the idle state; the second determination unit is used to determine T2 based on T1; where, T1=n*T+T2, T=1/f1, n It is an integer, n≥0, 0<T2<T; the modification unit is used to perform the operation of modifying the porch at time t4 when T2<V1; V1 satisfies the modification of the porch and the hardware interface DSI response cmd command in the second When completed within the frame, modify the duration corresponding to the latest time t3 of the porch and the timestamp corresponding to the Vsync signal of the second frame; where t2 ≤ t4 ≤ t3.
在一种可能的实现方式中,显示处理装置还包括:第一显示单元,用于在T2<V1时,在第二帧的下一帧,以所2显示图像。In a possible implementation, the display processing device further includes: a first display unit, configured to display the image in the next frame of the second frame when T2 < V1.
在一种可能的实现方式中,修改单元还用于,在T2≥V1时,在t6时刻执行修改porch的操作,t6在第三帧内,第三帧是第二帧相邻的下一帧,第三帧的Vsync信号对应的时间戳是t5,t5=t3+(T-V1);t6=t5+T3,所述TVSYNC+TVBP<T3<V1,所述TVSYNC是所述第三帧的Vsync信号对于的时长,所述TVBP是所述第三帧的垂直消隐区的后肩对应的时长。In a possible implementation, the modification unit is also used to perform the operation of modifying the porch at time t6 when T2 ≥ V1. t6 is within the third frame, and the third frame is the next frame adjacent to the second frame. , the timestamp corresponding to the Vsync signal of the third frame is t5, t5=t3+(T-V1); t6=t5+T3, the T VSYNC + T VBP < T3 < V1, the T VSYNC is the third The Vsync signal of the frame corresponds to the duration, and the T VBP is the duration corresponding to the trailing shoulder of the vertical blanking zone of the third frame.
在一种可能的实现方式中,显示处理装置还包括:第二显示单元,用于在T2≥V1时,在第三帧的下一帧,以所述f2显示图像。In a possible implementation, the display processing device further includes: a second display unit, configured to display the image with f2 in the next frame of the third frame when T2≥V1.
在一种可能的实现方式中,在根据T1确定T2方面,第二确定单元具体用于,确定f1与1000的最大公约数为x,y=1000/x;确定T2=(b%(y*1000)%T,其中,T1=a(秒)+b(微秒);修改单元中T2的值使用第二确定单元确定的T2的值。In a possible implementation, in determining T2 based on T1, the second determination unit is specifically used to determine that the greatest common divisor between f1 and 1000 is x, y=1000/x; determine T2=(b%(y* 1000)%T, where T1 = a (second) + b (microsecond); the value of T2 in the modification unit uses the value of T2 determined by the second determination unit.
采用该技术方案进行显示处理时,修改porch的操作和DSI响应cmd命令在同一帧内完成,这样能够在电子设备退出待机状态、并且待显示的图像的帧率变化时避免花屏;另外,在第二帧的下一帧,使显示屏以帧率f2显示图像,可以尽早将显示屏以新的帧率显示图像。When using this technical solution for display processing, the operation of modifying the porch and the DSI response to the cmd command are completed in the same frame, which can avoid screen blur when the electronic device exits the standby state and the frame rate of the image to be displayed changes; in addition, in the second In the next frame of the second frame, the display screen displays the image at the frame rate f2, and the display screen can display the image at the new frame rate as soon as possible.
参见图6,本申请实施例还提供了一种实现上述显示处理方法的电子设备600,如图6所示,电子设备600可以包括处理器610,外部存储器接口620,内部存储器621,通用串行总线(universal serial bus,USB)接口630,充电管理模块640,电源管理模块641,电池642,天线1,天线2,移动通信模块650,无线通信模块660,音频模块670,扬声器670A,受话器670B,麦克风670C,耳机接口670D,传感器模块680,按键690,马达691,指示器692,摄像头693,屏幕694,以及用户标识模块(subscriber identification module,SIM)卡接口695等。其中,传感器模块680可以包括压力传感器680A,陀螺仪传感器680B,气压传感器680C,磁传感器680D,加速度传感器680E,距离传感器680F,接近光传感器680G,指纹传感器680H,温度传感器680J,触摸传感器680K,环境光传感器680L,骨传导传感器680M等。Referring to Figure 6, the embodiment of the present application also provides an electronic device 600 that implements the above display processing method. As shown in Figure 6, the electronic device 600 may include a processor 610, an external memory interface 620, an internal memory 621, a universal serial Bus (universal serial bus, USB) interface 630, charging management module 640, power management module 641, battery 642, antenna 1, antenna 2, mobile communication module 650, wireless communication module 660, audio module 670, speaker 670A, receiver 670B, Microphone 670C, headphone interface 670D, sensor module 680, button 690, motor 691, indicator 692, camera 693, screen 694, and subscriber identification module (subscriber identification module, SIM) card interface 695, etc. Among them, the sensor module 680 may include a pressure sensor 680A, a gyro sensor 680B, an air pressure sensor 680C, a magnetic sensor 680D, an acceleration sensor 680E, a distance sensor 680F, a proximity light sensor 680G, a fingerprint sensor 680H, a temperature sensor 680J, a touch sensor 680K, and an environment. Light sensor 680L, bone conduction sensor 680M, etc.
处理器610可以包括一个或多个处理单元,比如:处理器610可以包括AP、CP、调制解调处理器、图形处理器(graphics processing unit,GPU)、图像信号处理器(imagesignal processor,ISP)、控制器、存储器、视频编解码器、数字信号处理器(digitalsignal processor,DSP)、基带处理器、和/或神经网络处理器(neural-networkprocessing unit,NPU)等。其中,不同的处理单元可以是独立的器件,也可以集成在一个或多个处理器中。The processor 610 may include one or more processing units. For example, the processor 610 may include an AP, a CP, a modem processor, a graphics processing unit (GPU), and an image signal processor (ISP). , controller, memory, video codec, digital signal processor (DSP), baseband processor, and/or neural network processing unit (NPU), etc. Among them, different processing units can be independent devices or integrated in one or more processors.
其中,控制器可以是电子设备600的神经中枢和指挥中心。控制器可以根据指令操作码和时序信号,产生操作控制信号,完成取指令和执行指令的控制。The controller may be the nerve center and command center of the electronic device 600 . The controller can generate operation control signals based on the instruction operation code and timing signals to complete the control of fetching and executing instructions.
处理器610中还可以设置存储器,用于存储指令和数据。在一些实施例中,处理器610中的存储器为高速缓冲存储器。该存储器可以保存处理器610刚用过或循环使用的指令或数据。如果处理器610需要再次使用该指令或数据,可从该存储器中直接调用。避免了重复存取,减少了处理器610的等待时间,因而提高了系统的效率。处理器还可以设置低功耗存储器(比如,Island低功耗等)以降低功耗。The processor 610 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in processor 610 is cache memory. This memory may hold instructions or data that have been recently used or recycled by processor 610 . If the processor 610 needs to use the instructions or data again, it can be called directly from the memory. Repeated access is avoided and the waiting time of the processor 610 is reduced, thus improving the efficiency of the system. The processor can also set low-power memory (for example, Island low-power, etc.) to reduce power consumption.
电子设备600通过GPU,屏幕694,以及应用处理器等实现显示功能。GPU为图像处理的微处理器,连接屏幕694和应用处理器。GPU用于执行数学和几何计算,用于图形渲染。处理器610可包括一个或多个GPU,其执行程序指令以生成或改变显示信息。The electronic device 600 implements display functions through a GPU, a screen 694, an application processor, and the like. The GPU is an image processing microprocessor and is connected to the screen 694 and the application processor. GPUs are used to perform mathematical and geometric calculations for graphics rendering. Processor 610 may include one or more GPUs that execute program instructions to generate or alter display information.
屏幕694用于显示图像,视频等。屏幕694包括显示面板。显示面板可以采用液晶屏幕(liquid crystal display,LCD)、有机发光二极管(organic light-emitting diode,OLED)、有源矩阵有机发光二极体或主动矩阵有机发光二极体(active-matrix organiclight emitting diode,AMOLED)、柔性发光二极管(flex light-emitting diode,FLED)、Miniled、MicroLed、Micro-OLED、量子点发光二极管(quantum dot light emittingdiodes,QLED)等。在一些实施例中,电子设备600可以包括1个或N个屏幕694,N为大于1的整数。Screen 694 is used to display images, videos, etc. Screen 694 includes a display panel. The display panel can use 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 (active-matrix organic light emitting diode). , AMOLED), flexible light-emitting diode (flex light-emitting diode, FLED), Miniled, MicroLed, Micro-OLED, quantum dot light emitting diode (quantum dot light emittingdiodes, QLED), etc. In some embodiments, electronic device 600 may include 1 or N screens 694, N being an integer greater than 1.
电子设备600可以通过ISP,摄像头693,视频编解码器,GPU,屏幕694以及应用处理器等实现拍摄功能。The electronic device 600 can implement the shooting function through an ISP, a camera 693, a video codec, a GPU, a screen 694 and an application processor.
ISP用于处理摄像头693反馈的数据。比如,拍照时,打开快门,光线通过镜头被传递到摄像头感光元件上,光信号转换为电信号,摄像头感光元件将电信号传递给ISP处理,转化为肉眼可见的图像。ISP还可以对图像的噪点,亮度,肤色进行算法优化。ISP还可以对拍摄场景的曝光,色温等参数优化。在一些实施例中,ISP可以设置在摄像头693中。The ISP is used to process the data fed back by the camera 693. For example, when taking a photo, the shutter is opened, the light is transmitted through the lens to the camera sensor, the optical signal is converted into an electrical signal, and the camera sensor passes the electrical signal to the ISP for processing, and converts it into an image visible to the naked eye. ISP can also perform algorithm optimization on image noise, brightness, and skin color. ISP can also optimize the exposure, color temperature and other parameters of the shooting scene. In some embodiments, the ISP may be provided in camera 693.
摄像头693用于捕获静态图像或视频。物体通过镜头生成光学图像投射到感光元件。感光元件可以是电荷耦合器件(charge coupled device,CCD)或互补金属氧化物半导体(complementary metal-oxide-semiconductor,CMOS)光电晶体管。感光元件把光信号转换成电信号,之后将电信号传递给ISP转换成数字图像信号。ISP将数字图像信号输出到DSP加工处理。DSP将数字图像信号转换成标准的RGB,YUV等格式的图像信号。在一些实施例中,电子设备600可以包括1个或N个摄像头693,N为大于1的整数。Camera 693 is used to capture still images or video. The object passes through the lens to produce an optical image that is projected onto the photosensitive element. The photosensitive element may 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 convert it into a digital image signal. ISP outputs digital image signals to DSP for processing. DSP converts digital image signals into standard RGB, YUV and other format image signals. In some embodiments, the electronic device 600 may include 1 or N cameras 693, where N is an integer greater than 1.
外部存储器接口620可以用于连接外部存储卡,比如Micro SD卡,实现扩展电子设备600的存储能力。外部存储卡通过外部存储器接口620与处理器610通信,实现数据存储功能。比如将音乐,视频等文件保存在外部存储卡中。The external memory interface 620 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 600 . The external memory card communicates with the processor 610 through the external memory interface 620 to implement the data storage function. For example, save music, video and other files on an external memory card.
内部存储器621可以用于存储计算机可执行程序代码,计算机可执行程序代码包括指令。处理器610通过运行存储在内部存储器621的指令,来执行电子设备600的各种功能应用以及数据处理。内部存储器621可以包括存储程序区和存储数据区。其中,存储程序区可存储操作系统,至少一个功能所需的应用程序(比如声音播放功能,图像播放功能等)等。存储数据区可存储电子设备600在使用过程中所创建的数据(比如音频数据,电话本等)等。此外,内部存储器621可以包括高速随机存取存储器,还可以包括非易失性存储器,比如至少一个磁盘存储器件,闪存器件,通用闪存存储器(universal flash storage,UFS)等。Internal memory 621 may be used to store computer-executable program code, which includes instructions. The processor 610 executes various functional applications and data processing of the electronic device 600 by executing instructions stored in the internal memory 621 . The internal memory 621 may include a program storage area and a data storage area. Among them, the stored program area can store an operating system, at least one application program required for a function (such as a sound playback function, an image playback function, etc.). The storage data area may store data created during use of the electronic device 600 (such as audio data, phone book, etc.). In addition, the internal memory 621 may include high-speed random access memory, and may also include non-volatile memory, such as at least one disk storage device, flash memory device, universal flash storage (UFS), etc.
加速度传感器680E可检测电子设备600在各个方向上(一般为三轴)加速度的大小。当电子设备600静止时可检测出重力的大小及方向。加速度传感器680E还可以用于识别电子设备600的姿态,应用于横竖屏切换,计步器等应用。当然,加速度传感器680E也可以结合陀螺仪传感器680B,来识别电子设备600的姿态,应用于横竖屏切换。The acceleration sensor 680E can detect the acceleration of the electronic device 600 in various directions (generally three axes). When the electronic device 600 is stationary, the magnitude and direction of gravity can be detected. The acceleration sensor 680E can also be used to identify the posture of the electronic device 600 and be used for horizontal and vertical screen switching, pedometer and other applications. Of course, the acceleration sensor 680E can also be combined with the gyro sensor 680B to identify the posture of the electronic device 600 and be used for switching between horizontal and vertical screens.
陀螺仪传感器680B可以用于确定电子设备400的运动姿态。在一些实施例中,可以通过陀螺仪传感器680B确定电子设备600围绕三个轴(即,x,y和z轴)的角速度。陀螺仪传感器680B可以用于拍摄防抖。示例性的,当按下快门,陀螺仪传感器680B检测电子设备600抖动的角度,根据角度计算出镜头模组需要补偿的距离,让镜头通过反向运动抵消电子设备600的抖动,实现防抖。陀螺仪传感器680B还可以用于横竖屏切换,导航,体感游戏场景。The gyro sensor 680B may be used to determine the motion posture of the electronic device 400 . In some embodiments, the angular velocity of electronic device 600 about three axes (ie, x, y, and z axes) may be determined by gyro sensor 680B. The gyro sensor 680B can be used for image stabilization. For example, when the shutter is pressed, the gyro sensor 680B detects the angle at which the electronic device 600 shakes, calculates the distance that the lens module needs to compensate based on the angle, and allows the lens to offset the shake of the electronic device 600 through reverse movement to achieve anti-shake. The gyro sensor 680B can also be used for horizontal and vertical screen switching, navigation, and somatosensory gaming scenarios.
可以理解的是,本申请实施例示意的结构并不构成对电子设备600的具体限定。在本申请另一些实施例中,电子设备600可以包括比图示更多或更少的部件,或者组合某些部件,或者拆分某些部件,或者不同的部件布置。图示的部件可以以硬件,软件或软件和硬件的组合实现。It can be understood that the structure illustrated in the embodiment of the present application does not constitute a specific limitation on the electronic device 600 . In other embodiments of the present application, the electronic device 600 may include more or fewer components than shown in the figures, or some components may be combined, some components may be separated, or some components may be arranged differently. The components illustrated may be implemented in hardware, software, or a combination of software and hardware.
本申请实施例提供的电子设备可以是用户设备(user equipment,UE),例如移动终端(如手机)等设备。The electronic device provided by the embodiment of the present application may be a user equipment (UE), such as a mobile terminal (such as a mobile phone).
另外,在上述部件之上,运行有操作系统。例如可以是谷歌公司所开发的Android开源操作系统等。In addition, an operating system runs on top of the above components. For example, it can be the Android open source operating system developed by Google.
电子设备的软件系统可以采用分层架构,事件驱动架构,微核架构,微服务架构,或云架构等。为了更清楚的说明本申请实施例提供的触控操作的识别方法,本申请实施例以分层架构的安卓(Android)系统为例,对电子设备的软件系统进行示例性说明。The software system of electronic equipment can adopt layered architecture, event-driven architecture, microkernel architecture, microservice architecture, or cloud architecture, etc. In order to more clearly illustrate the touch operation recognition method provided by the embodiment of the present application, the embodiment of the present application takes the Android system with a layered architecture as an example to illustrate the software system of the electronic device.
上述图6仅为一种电子设备的组成示例。参考图7,为本申请实施例提供的又一种电子设备的组成示例。The above-mentioned FIG. 6 is only a composition example of an electronic device. Referring to FIG. 7 , another example of the composition of an electronic device is provided according to an embodiment of the present application.
在该示例中,电子设备的软件系统可以采用分层架构,事件驱动架构,微核架构,微服务架构,或云架构。本申请实施例以分层架构的系统为例,示例性说明电子设备的软件结构。In this example, the software system of the electronic device may adopt a layered architecture, an event-driven architecture, a microkernel architecture, a microservice architecture, or a cloud architecture. The embodiment of this application uses a layered architecture The system is taken as an example to illustrate the software structure of the electronic device.
分层架构将软件分成若干个层,每一层都有清晰的角色和分工。层与层之间通过软件接口通信。在一些实施例中,将系统分为五层,从上至下分别为应用程序层,应用程序框架层,安卓运行时(Android runtime,ART)和原生C/C++库,硬件抽象层(Hardware Abstract Layer,HAL)以及内核层。The layered architecture divides the software into several layers, and each layer has clear roles and division of labor. The layers communicate through software interfaces. In some embodiments, the The system is divided into five layers, from top to bottom: application layer, application framework layer, Android runtime (ART) and native C/C++ library, hardware abstraction layer (Hardware Abstract Layer, HAL) and kernel layer .
应用程序层可以包括一系列应用程序包。The application layer can include a series of application packages.
如图7所示,电子设备可以包括硬件层和软件层,其中,分层架构的Android系统可以包括应用层,应用框架层,系统库层和内核层。在一些可选的实施例中,电子设备的系统还可以包括上述技术架构未提及的层级,如安卓运行时(Android Runtime)。应用程序层可以包括一系列应用程序包,如导航应用、音乐应用、视频应用、和指关节敲击屏幕应用等。应用程序包可以包括视频、聊天等应用,以及系统用户界面(system user interface,SystemUI),指关节敲击屏幕应用可以用于截屏、录屏、长截屏、区域截屏等。在本示例中,该应用程序包还包括联系人查找等应用程序。As shown in Figure 7, the electronic device may include a hardware layer and a software layer, wherein the Android system with a layered architecture may include an application layer, an application framework layer, a system library layer and a kernel layer. In some optional embodiments, the system of the electronic device may also include layers not mentioned in the above technical architecture, such as Android Runtime. The application layer can include a series of application packages, such as navigation applications, music applications, video applications, and knuckle-tapping screen applications. The application package can include applications such as video and chat, as well as system user interface (SystemUI). Knuckle tapping screen applications can be used for screenshots, screen recordings, long screenshots, regional screenshots, etc. In this example, the application package also includes applications such as contact lookup.
视频、聊天等应用用于为用户提供对应的服务。例如,用户使用视频应用观看视频,使用聊天应用和其他用户聊天,使用音乐应用收听音乐,使用视频合成利用已有的图像和视频生成回忆视频等。Video, chat and other applications are used to provide users with corresponding services. For example, users use video applications to watch videos, use chat applications to chat with other users, use music applications to listen to music, and use video synthesis to generate recall videos using existing images and videos, etc.
SystemUI用于管理电子设备的人机交互界面(user interface,UI),在本申请实施例中,SystemUI用于监测触控屏上的触控操作。SystemUI is used to manage a human-computer interaction interface (UI) of an electronic device. In this embodiment of the present application, SystemUI is used to monitor touch operations on the touch screen.
应用程序框架层为应用程序层的应用程序提供应用编程接口(applicationprogramminginterface,API)和编程框架。应用程序框架层包括一些预先定义的函数。应用程序框架层可以包括窗口管理服务模块(window manage service,WMS),显示旋转模块(又称DisplayRotation),应用管理服务模块(activity manage service,AMS)、输入管理模块(又称Input)和图像处理模块等。The application framework layer provides an application programming interface (API) and programming framework for applications in the application layer. The application framework layer includes some predefined functions. The application framework layer can include window management service module (window management service, WMS), display rotation module (also known as DisplayRotation), application management service module (activity management service, AMS), input management module (also known as Input) and image processing Modules etc.
WMS用于管理窗口程序。窗口管理器可以获取屏幕大小,判断是否有状态栏,对屏幕中的图像进行抠图截取屏幕等。本申请实施例中,WMS可以创建并管理应用对应的窗口。WMS is used to manage window programs. The window manager can obtain the screen size, determine whether there is a status bar, cut out the image on the screen to capture the screen, etc. In this embodiment of the present application, WMS can create and manage windows corresponding to applications.
显示旋转模块用于控制屏幕进行旋转,通过旋转使得屏幕呈现出竖屏或者横屏的布局。比如在确定需要进行屏幕旋转时,通知Surfaceflinger进行应用界面的横竖屏切换。The display rotation module is used to control the rotation of the screen so that the screen presents a vertical or horizontal screen layout. For example, when it is determined that screen rotation is required, Surfaceflinger is notified to switch the application interface between horizontal and vertical screens.
AMS用于根据用户的操作启动特定的应用。例如,当图像完成合成操作后,触发图像在屏幕中主键显示出来,在图像显示出来后,触发对确定需要被执行抠图操作的图像执行抠图操作,并创建视频应用对应的应用堆栈,使视频应用能够正常运行。AMS is used to launch specific applications based on user operations. For example, after the image synthesis operation is completed, the trigger image is displayed on the screen. After the image is displayed, the trigger performs a cutout operation on the image that is determined to need to be cutout, and creates an application stack corresponding to the video application, so that The video application works normally.
系统库层可以包括多个功能模块,比如:传感器模块(又称sensor)和SurfaceFlinger。The system library layer can include multiple functional modules, such as sensor module (also known as sensor) and SurfaceFlinger.
传感器模块用于获取传感器采集的数据,比如采集屏幕下的环境光。采集电子设备的重力方向信息。或者,传感器模块也可以根据环境光调节屏幕的亮度,以及根据电子设备的重力方向信息,确定电子设备的横竖屏状态信息,横竖屏状态信息用于指示电子设备处于横屏状态还是竖屏状态。The sensor module is used to obtain data collected by the sensor, such as collecting the ambient light under the screen. Collect gravity direction information of electronic devices. Alternatively, the sensor module can also adjust the brightness of the screen according to the ambient light, and determine the horizontal and vertical screen status information of the electronic device based on the gravity direction information of the electronic device. The horizontal and vertical screen status information is used to indicate whether the electronic device is in the horizontal or vertical screen state.
Surfaceflinger是一种系统服务,用于图层的创建、控制和管理等功能。Surfaceflinger is a system service used for layer creation, control and management functions.
另外,系统库层还可以包括:表面管理器(surface manager),媒体库(MediaLibraries),三维图形处理库(比如:OpenGL ES),2D图形引擎(比如:SGL)等。表面管理器用于对显示子系统进行管理,并且为多个应用程序提供了2D和3D图层的融合。媒体库支持多种常用的音频,视频格式回放和录制,以及静态图像文件等。媒体库可以支持多种音视频编码格式,比如:MPEG4,H.264,MP3,AAC,AMR,JPG,PNG等。三维图形处理库用于实现三维图形绘图,图像渲染,合成,和图层处理等。2D图形引擎是2D绘图的绘图引擎。In addition, the system library layer can also include: surface manager (surface manager), media libraries (MediaLibraries), 3D graphics processing libraries (such as: OpenGL ES), 2D graphics engines (such as: SGL), etc. The surface manager is used to manage the display subsystem and provides the fusion of 2D and 3D layers for multiple applications. The media library supports playback and recording of a variety of commonly used audio and video formats, as well as static image files, etc. The media library can support a variety of 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, composition, and layer processing. 2D Graphics Engine is a drawing engine for 2D drawing.
内核层是硬件和软件之间的层。在本申请实施例中,内核层至少包含触控驱动模块和显示驱动模块。The kernel layer is the layer between hardware and software. In this embodiment of the present application, the core layer at least includes a touch driver module and a display driver module.
显示驱动模块用于根据应用框架层的模块和应用层的应用程序所提供的图像数据,在屏幕中显示合成的图像。例如,视频应用将视频的一帧图像数据传递给显示驱动模块,显示驱动模块根据该图像数据在触摸屏上显示视频中的一帧图像。SystemUI将图像数据传递给显示驱动模块,显示驱动模块将合成后的图像在屏幕中显示出来。The display driver module is used to display the synthesized image on the screen according to the image data provided by the module of the application framework layer and the application program of the application layer. For example, the video application transfers one frame of image data of the video to the display driver module, and the display driver module displays one frame of image in the video on the touch screen based on the image data. SystemUI passes the image data to the display driver module, and the display driver module displays the synthesized image on the screen.
触控驱动模块用于监测触摸屏各区域的容值数据。当用户在触摸屏上点击或滑动时,被点击或滑动的区域的电容值会发生变化,触控驱动模块能够监测到触摸屏上各区域电容值的变化,并向输入管理模块发送电容值变化的消息,电容值数据变化消息中携带有触摸屏各个区域的电容值的变化幅度以及发生变化的时间等信息。The touch driver module is used to monitor the capacitance data of each area of the touch screen. When the user clicks or slides on the touch screen, the capacitance value of the clicked or slid area will change. The touch driver module can detect the changes in the capacitance value of each area on the touch screen and send a message of the capacitance value change to the input management module. , the capacitance value data change message carries information such as the change amplitude of the capacitance value in each area of the touch screen and the time of change.
输入管理模块根据上报的电容值变化消息可以确定触控操作,然后将识别到的触控操作发送给其他模块。这里的触控操作可以包括指关节敲击操作、点击操作、拖拽操作、以及特定的手势操作(如上滑手势操作,横滑手势操作等)。The input management module can determine the touch operation based on the reported capacitance value change message, and then send the recognized touch operation to other modules. The touch operations here may include knuckle tapping operations, clicking operations, dragging operations, and specific gesture operations (such as upward sliding gesture operations, horizontal sliding gesture operations, etc.).
硬件层包括屏幕和环境光传感器等,环境光传感器用于检测屏幕下面的环境光信息等。应用处理器监测对触控屏的触控操作,基带处理器监听加速度数据并将监听到的加速度数据存储到存储模块,在AP监测到触控操作时,CP根据存储模块存储的加速度数据识别触控操作是否为指关节敲击动作;CP将识别结果发送给AP。The hardware layer includes the screen and ambient light sensor. The ambient light sensor is used to detect ambient light information under the screen. The application processor monitors the touch operation on the touch screen. The baseband processor monitors the acceleration data and stores the monitored acceleration data to the storage module. When the AP detects the touch operation, the CP identifies the touch based on the acceleration data stored in the storage module. Control whether the operation is a knuckle tapping action; the CP sends the recognition result to the AP.
上述技术架构列举了电子设备中本申请可能涉及的模块和器件。在实际应用中,电子设备可以包括上述技术架构的全部或部分模块和器件,以及其他上述技术架构未提及的模块和器件,当然,也可以只包括上述技术架构的模块和器件,本实施例对此不做限定。The above technical architecture lists the modules and devices in electronic equipment that may be involved in this application. In practical applications, the electronic device may include all or part of the modules and devices of the above technical architecture, as well as other modules and devices not mentioned in the above technical architecture. Of course, it may also include only the modules and devices of the above technical architecture. This embodiment There is no restriction on this.
本申请实施例还提供了一种电子设备,所述电子设备包括处理器、显示器和存储器,所述存储器用于存储计算机程序,所述显示器用于显示图像,所述处理器用于从所述存储器中调用并运行所述计算机程序,使得处理器执行如前面任一项方法实施例所述的显示处理方法。An embodiment of the present application also provides an electronic device. The electronic device includes a processor, a display, and a memory. The memory is used to store computer programs. The display is used to display images. The processor is used to read images from the memory. The computer program is called and run in the processor, so that the processor executes the display processing method as described in any of the previous method embodiments.
本申请实施例还提供了一种芯片,包括处理器,当处理器执行指令时,处理器执行如前面任一项方法实施例所述的显示处理方法。An embodiment of the present application also provides a chip, including a processor. When the processor executes instructions, the processor executes the display processing method described in any of the previous method embodiments.
本申请实施例还提供了一种计算机可读存储介质,该计算机可读存储介质存储有计算机程序,当计算机程序被处理器执行时能够实现上述各个方法实施例中的步骤。Embodiments of the present application also provide a computer-readable storage medium that stores a computer program. When the computer program is executed by a processor, the steps in each of the above method embodiments can be implemented.
本申请实施例提供了一种计算机程序产品,该计算机程序产品包括计算机程序,当计算机程序被处理器执行时能够实现上述各个方法实施例中的步骤。Embodiments of the present application provide a computer program product. The computer program product includes a computer program. When the computer program is executed by a processor, the steps in each of the above method embodiments can be implemented.
本申请实现上述实施例方法中的全部或部分流程,可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一计算机可读存储介质中,该计算机程序在被处理器执行时,可实现上述各个方法实施例的步骤。其中,所述计算机程序包括计算机程序代码,所述计算机程序代码可以为源代码形式、对象代码形式、可执行文件或某些中间形式等。所述计算机可读介质至少可以包括:能够将计算机程序代码携带到拍照装置/电子设备的任何实体或装置、记录介质、计算机存储器、只读存储器(read-only memory,ROM)、随机存取存储器(random access memory,RAM)、电载波信号、电信信号以及软件分发介质。例如U盘、移动硬盘、磁碟或者光盘等。在某些司法管辖区,根据立法和专利实践,计算机可读介质不可以是电载波信号和电信信号。This application implements all or part of the processes in the methods of the above embodiments, which can be completed by instructing relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer program is executed by the processor. When , the steps of each of the above method embodiments can be implemented. Wherein, the computer program includes computer program code, which may be in the form of source code, object code, executable file or some intermediate form. The computer-readable medium may at least include: any entity or device capable of carrying computer program code to a camera/electronic device, a recording medium, a computer memory, a read-only memory (ROM), or a random access memory. (random access memory, RAM), electrical carrier signals, telecommunications signals, and software distribution media. For example, U disk, mobile hard disk, magnetic disk or CD, etc. In some jurisdictions, subject to legislation and patent practice, computer-readable media may not be electrical carrier signals and telecommunications signals.
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述或记载的部分,可以参见其它实施例的相关描述。In the above embodiments, each embodiment is described with its own emphasis. For parts that are not detailed or documented in a certain embodiment, please refer to the relevant descriptions of other embodiments.
本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、或者计算机软件和电子硬件的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented with electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Skilled artisans may implement the described functionality using different methods for each specific application, but such implementations should not be considered beyond the scope of this application.
在本申请所提供的实施例中,应该理解到,所揭露的方法和电子设备,可以通过其它的方式实现。例如,以上所描述的装置/网络设备实施例仅仅是示意性的,例如,所述模块或单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通讯连接可以是通过一些接口,装置或单元的间接耦合或通讯连接,可以是电性,机械或其它的形式。In the embodiments provided in this application, it should be understood that the disclosed methods and electronic devices can be implemented in other ways. For example, the apparatus/network equipment embodiments described above are only illustrative. For example, the division of modules or units is only a logical function division. In actual implementation, there may be other division methods, such as multiple units. Or components can be combined or can be integrated into another system, or some features can be omitted, or not implemented. On the other hand, the coupling or direct coupling or communication connection between each other shown or discussed may be through some interfaces, indirect coupling or communication connection of devices or units, which may be in electrical, mechanical or other forms.
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place, or they may be distributed to multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
应当理解,当在本申请说明书和所附权利要求书中使用时,术语“包括”指示所描述特征、整体、步骤、操作、元素和/或组件的存在,但并不排除一个或多个其它特征、整体、步骤、操作、元素、组件和/或其集合的存在或添加。It will be understood that, when used in this specification and the appended claims, the term "comprising" indicates the presence of the described features, integers, steps, operations, elements and/or components but does not exclude one or more other The presence or addition of features, integers, steps, operations, elements, components and/or collections thereof.
还应当理解,在本申请说明书和所附权利要求书中使用的术语“和/或”是指相关联列出的项中的一个或多个的任何组合以及所有可能组合,并且包括这些组合。It will also be understood that the term "and/or" as used in this specification and the appended claims refers to and includes any and all possible combinations of one or more of the associated listed items.
在本申请说明书中描述的参考“一个实施例”或“一些实施例”等意味着在本申请的一个或多个实施例中包括结合该实施例描述的特定特征、结构或特点。由此,在本说明书中的不同之处出现的语句“在一个实施例中”、“在一些实施例中”、“在其他一些实施例中”、“在另外一些实施例中”等不是必然都参考相同的实施例,而是意味着“一个或多个但不是所有的实施例”,除非是以其他方式另外特别强调。术语“包括”、“包含”、“具有”及它们的变形都意味着“包括但不限于”,除非是以其他方式另外特别强调。Reference in this specification to "one embodiment" or "some embodiments" or the like means that a particular feature, structure or characteristic described in connection with the embodiment is included in one or more embodiments of the application. Therefore, the phrases "in one embodiment", "in some embodiments", "in other embodiments", "in other embodiments", etc. appearing in different places in this specification are not necessarily References are made to the same embodiment, but rather to "one or more but not all embodiments" unless specifically stated otherwise. The terms “including,” “includes,” “having,” and variations thereof all mean “including but not limited to,” unless otherwise specifically emphasized.
以上所述实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围,均应包含在本申请的保护范围之内。The above-described embodiments are only used to illustrate the technical solutions of the present application, but not to limit them. Although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still implement the above-mentioned implementations. The technical solutions described in the examples are modified, or some of the technical features are equivalently replaced; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions in the embodiments of this application, and should be included in within the protection scope of this application.
Claims (13)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202311777273.2A CN117746762B (en) | 2023-12-21 | 2023-12-21 | Display processing method and device and electronic equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202311777273.2A CN117746762B (en) | 2023-12-21 | 2023-12-21 | Display processing method and device and electronic equipment |
Publications (2)
Publication Number | Publication Date |
---|---|
CN117746762A true CN117746762A (en) | 2024-03-22 |
CN117746762B CN117746762B (en) | 2024-10-11 |
Family
ID=90252463
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202311777273.2A Active CN117746762B (en) | 2023-12-21 | 2023-12-21 | Display processing method and device and electronic equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN117746762B (en) |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2014168836A1 (en) * | 2013-04-11 | 2014-10-16 | Qualcomm Incorporated | Apparatus and method for displaying video data |
CN106205460A (en) * | 2016-09-29 | 2016-12-07 | 京东方科技集团股份有限公司 | The driving method of display device, time schedule controller and display device |
JP2018155846A (en) * | 2017-03-16 | 2018-10-04 | パイオニア株式会社 | Projection device, control method, program, and storage media |
CN116092452A (en) * | 2023-01-05 | 2023-05-09 | 荣耀终端有限公司 | Refresh rate switching method and electronic device |
CN116414337A (en) * | 2021-12-29 | 2023-07-11 | 荣耀终端有限公司 | Frame rate switching method and device |
CN117174014A (en) * | 2023-10-31 | 2023-12-05 | 荣耀终端有限公司 | Display control circuit, display control method and electronic equipment |
-
2023
- 2023-12-21 CN CN202311777273.2A patent/CN117746762B/en active Active
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2014168836A1 (en) * | 2013-04-11 | 2014-10-16 | Qualcomm Incorporated | Apparatus and method for displaying video data |
CN106205460A (en) * | 2016-09-29 | 2016-12-07 | 京东方科技集团股份有限公司 | The driving method of display device, time schedule controller and display device |
JP2018155846A (en) * | 2017-03-16 | 2018-10-04 | パイオニア株式会社 | Projection device, control method, program, and storage media |
CN116414337A (en) * | 2021-12-29 | 2023-07-11 | 荣耀终端有限公司 | Frame rate switching method and device |
CN116092452A (en) * | 2023-01-05 | 2023-05-09 | 荣耀终端有限公司 | Refresh rate switching method and electronic device |
CN117174014A (en) * | 2023-10-31 | 2023-12-05 | 荣耀终端有限公司 | Display control circuit, display control method and electronic equipment |
Also Published As
Publication number | Publication date |
---|---|
CN117746762B (en) | 2024-10-11 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN115097994B (en) | Data processing method and related device | |
WO2023005751A1 (en) | Rendering method and electronic device | |
CN116826892A (en) | Charging method, charging device, electronic apparatus, and readable storage medium | |
CN117724781A (en) | Playing method for starting animation by application program and electronic equipment | |
CN115033333B (en) | Suspended window display method, electronic equipment and storage medium | |
WO2023001163A1 (en) | Screen refreshing method and device capable of improving dynamic effect performance | |
CN116546274B (en) | Video segmentation method, selection method, synthesis method and related devices | |
CN115495003A (en) | Keyboard display method, folding screen device and computer readable storage medium | |
CN115361468B (en) | Display optimization method, device and storage medium when screen rotates | |
CN116225274A (en) | Identification method and device for touch operation, electronic equipment and storage medium | |
CN117746762B (en) | Display processing method and device and electronic equipment | |
CN116055627B (en) | Screen-off control method, electronic equipment and storage medium | |
CN116095221B (en) | Frame rate adjusting method in game and related device | |
CN117894256B (en) | Display processing method, device and electronic equipment | |
CN116719587A (en) | Screen display method, electronic device and computer-readable storage medium | |
CN117135253B (en) | Contact search method, terminal device and storage medium | |
CN116795306A (en) | Image display method and electronic device | |
CN117114964B (en) | Method for caching image frames, electronic equipment and storage medium | |
CN117726507B (en) | Image processing method and device | |
WO2024125301A1 (en) | Display method and electronic device | |
CN116680133B (en) | Black screen detection method and electronic device | |
CN115484393B (en) | Abnormality prompting method and electronic equipment | |
WO2022262547A1 (en) | Video photographing method and electronic device | |
WO2024046317A1 (en) | Content display method and electronic device | |
CN118860176A (en) | Touch display method and related device |
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 | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
CP03 | Change of name, title or address |
Address after: Unit 3401, unit a, building 6, Shenye Zhongcheng, No. 8089, Hongli West Road, Donghai community, Xiangmihu street, Futian District, Shenzhen, Guangdong 518040 Patentee after: Honor Terminal Co.,Ltd. Country or region after: China Address before: 3401, unit a, building 6, Shenye Zhongcheng, No. 8089, Hongli West Road, Donghai community, Xiangmihu street, Futian District, Shenzhen, Guangdong Patentee before: Honor Device Co.,Ltd. Country or region before: China |