Search

CN-121996132-A - Video page switching method, device and equipment

CN121996132ACN 121996132 ACN121996132 ACN 121996132ACN-121996132-A

Abstract

The invention provides a video page switching method, a device and equipment, the method comprises the steps of responding to a page switching event, obtaining a current frame image of a graphic layer and a current frame image of a video layer, extracting corresponding image attributes, obtaining an animation type and a software and hardware resource state of a page switching transition animation, determining an execution layer of the transition animation according to the image attributes, the animation type and the software and hardware resource state, and executing a target image presented in the layer, wherein the target image is generated based on the current frame image of the graphic layer and/or the current frame image of the video layer, and executing the transition animation based on the target image on the execution layer.

Inventors

  • Xiao Shixiu
  • XU JIARONG
  • LEI JUN

Assignees

  • 烽火通信科技股份有限公司

Dates

Publication Date
20260508
Application Date
20260126

Claims (10)

  1. 1. The video page switching method is characterized by comprising the following steps of: Responding to a page switching event, acquiring a current frame image of a graphic layer and a current frame image of a video layer, and extracting corresponding image attributes; Acquiring the animation type and the software and hardware resource state of the page switching transition animation; Determining an execution layer of the transition animation and a target image presented in the execution layer according to the image attribute, the animation type and the software and hardware resource state, wherein the target image is generated based on the image of the current frame of the graphics layer and/or the image of the current frame of the video layer; And executing the transition animation based on the target image on the execution layer.
  2. 2. The video page switching method of claim 1, wherein: The image attribute comprises the size and the display area of the current frame image of the video layer and the current frame image of the image layer; The software and hardware resource state comprises available memory capacity of equipment, CPU idle resources, GPU idle resources, the current use layer numbers of a video layer and a graphics layer and the upper limit of equipment supporting layer numbers; the animation types of the transition animation comprise fade-in fade-out animation, page traversing animation and turning animation.
  3. 3. The video page switching method according to claim 2, wherein the determining an execution layer of the transitional animation, and a target image presented in the execution layer according to the image attribute, the animation type, and the state of the software and hardware resources, comprises: judging whether the video layer is displayed in a full screen mode according to the display area of the current frame image of the video layer, and judging whether the video layer supports the animation type; if yes, determining the video layer as the execution layer, and taking the current frame image of the video layer as the target image; Otherwise, determining the memory requirement, the CPU requirement and the GPU requirement according to the size of the current frame image of the video layer, judging whether the available memory capacity, the CPU idle resources and the GPU idle resources of the equipment meet the corresponding requirements, judging whether the current use layer number of the graphics layer does not reach the upper limit of the equipment support layer number, and allowing the newly added graphics sub-layer with the same size as the display area of the original video layer; If yes, determining a graphic layer as the execution layer, and taking the current frame image of the video layer as the target image; If the current frame image of the video layer does not meet the requirements, determining the memory requirements, the CPU requirements and the GPU requirements according to the size of the current frame image of the video layer, judging whether the available memory capacity, the CPU idle resources and the GPU idle resources of the equipment meet the corresponding requirements, judging whether the current use layer number of the video layer does not reach the upper limit of the equipment support layer number, and whether a video sub-layer with the same size as the display area of the original video layer is allowed to be newly added or not, and judging whether the video layer supports the animation type or not; If yes, determining the video layer as the execution layer, and taking a mixed image synthesized by the current frame image of the graphic layer and the current frame image of the video layer as the target image; otherwise, determining the graphic layer as the execution graphic layer, and taking the current frame image of the graphic layer as the target image.
  4. 4. The video page switching method of claim 3, wherein when the video layer is determined to be the execution layer and a current frame image of the video layer is taken as the target image, executing the transition animation based on the target image on the execution layer comprises: controlling the video layer to maintain and display the current frame image of the video layer; And applying the transition animation to the video layer, and executing the transition animation on the video layer based on the current frame image of the video layer.
  5. 5. The video page switching method of claim 3, wherein when the graphics layer is determined to be the execution layer and a current frame image of the video layer is taken as the target image, executing the transition animation based on the target image on the execution layer, comprises: creating a graphic sub-layer in the display area of the original video layer in the graphic layer, and displaying the current frame image of the video layer in the graphic sub-layer; controlling the video layer to pause output and hide; And executing the transition animation on the graphics layer based on the current frame image of the video layer.
  6. 6. The video page switching method according to claim 3, wherein when the video layer is determined to be the execution layer and the mixed image is taken as the target image, executing the transition animation based on the target image on the execution layer, comprises: creating a video sub-layer in the display area of the original image layer in the video layer, and displaying the mixed image in the video sub-layer; Controlling the original video layer to suspend output and hide; Controlling the graphic layer in the display area of the original graphic layer to be hidden; and applying the transition animation to the video sub-layer, and executing the transition animation based on the mixed image in the video sub-layer.
  7. 7. The video page switching method of claim 3, wherein when the graphics layer is determined to be the execution layer and a current frame image of the graphics layer is taken as the target image, executing the transition animation based on the target image on the execution layer, comprises: Controlling the video layer to stop outputting and enter a black screen state; And executing the transition animation on the graphics layer based on the current frame image of the graphics layer.
  8. 8. The video page switching method according to any one of claims 4 to 7, wherein, on the execution layer, the transitional animation is executed based on the target image, further comprising: And when the transition animation is executed, moving the hidden graphic layer and/or the video layer to the animation ending position, and destroying the newly added graphic layer.
  9. 9. A video page switching apparatus, characterized in that the video page switching apparatus comprises: the first acquisition module is used for responding to the page switching event, acquiring a current frame image of the graphic layer and a current frame image of the video layer, and extracting corresponding image attributes; The second acquisition module is used for acquiring the animation type and the software and hardware resource state of the page switching transition animation; the determining module is used for determining an execution layer of the transition animation and a target image presented in the execution layer according to the image attribute, the animation type and the software and hardware resource state, wherein the target image is generated based on the current frame image of the graphics layer and/or the current frame image of the video layer; And the execution module is used for executing the transition animation based on the target image on the execution layer.
  10. 10. A video page switching device comprising a processor, a memory, and a video page switching program stored on the memory and executable by the processor, wherein the video page switching program, when executed by the processor, implements the steps of the video page switching method of any one of claims 1 to 8.

Description

Video page switching method, device and equipment Technical Field The present application relates to the field of video playing, and in particular, to a method, an apparatus, and a device for switching video pages. Background In the terminal device, application page switching is generally accompanied by transition animation to promote smooth feeling and visual experience of operation. Common transitional animations include fades, page panning, flipping, 3D rotation, etc. However, in dedicated video playing devices such as set top boxes and IPTV, in order to optimize video decoding efficiency and HDR display effect, the display output is typically divided into two independent layers, namely a graphics layer and a video layer. Under the two-layer architecture, the traditional page switching transition animation only acts on the graphics layer, so that the display effect of the graphics layer and the display effect of the video layer are inconsistent. When the application executes page switching, the graphic layer normally operates transition animation, but the video layer keeps static frames or black screens and cannot change along with the pictures of the graphic layer, so that obvious cracks appear on the visual sense of the graphic layer and the video layer, and the user experience is affected. Therefore, how to realize smooth transition and visual consistency of page switching in a video playing scene is a technical problem to be solved. Disclosure of Invention The application provides a video page switching method, a device and equipment, which can solve the display abnormality problems of black screen, static frame, black edge and the like in the prior art when video playing pages are switched. In a first aspect, an embodiment of the present application provides a video page switching method, where the video page switching method includes: Responding to a page switching event, acquiring a current frame image of a graphic layer and a current frame image of a video layer, and extracting corresponding image attributes; Acquiring the animation type and the software and hardware resource state of the page switching transition animation; Determining an execution layer of the transition animation and a target image presented in the execution layer according to the image attribute, the animation type and the software and hardware resource state, wherein the target image is generated based on the image of the current frame of the graphics layer and/or the image of the current frame of the video layer; And executing the transition animation based on the target image on the execution layer. In a second aspect, an embodiment of the present application provides a video page switching apparatus, including: the first acquisition module is used for responding to the page switching event, acquiring a current frame image of the graphic layer and a current frame image of the video layer, and extracting corresponding image attributes; The second acquisition module is used for acquiring the animation type and the software and hardware resource state of the page switching transition animation; the determining module is used for determining an execution layer of the transition animation and a target image presented in the execution layer according to the image attribute, the animation type and the software and hardware resource state, wherein the target image is generated based on the current frame image of the graphics layer and/or the current frame image of the video layer; And the execution module is used for executing the transition animation based on the target image on the execution layer. In a third aspect, an embodiment of the present application provides a video page switching apparatus, where the video page switching apparatus includes a processor, a memory, and a video page switching program stored on the memory and executable by the processor, where the video page switching program, when executed by the processor, implements the steps of the video page switching method according to any one of the above. The technical scheme provided by the embodiment of the application has the beneficial effects that: The method comprises the steps of responding to a page switching event, obtaining a current frame image of a graphic layer and a current frame image of a video layer, extracting corresponding image attributes, obtaining animation types and software and hardware resource states of a page switching transition animation, determining an execution layer of the transition animation and a target image presented in the execution layer according to the image attributes, the animation types and the software and hardware resource states, wherein the target image is generated based on the current frame image of the graphic layer and/or the current frame image of the video layer, executing the transition animation on the execution layer based on the target image, effectively avoiding abnormal display problems such as black screen