Video playing method, device, system and storage medium
By caching video frames at forwarding nodes and retrieving the target video frame from the cache in case of communication failure, the problem of video stream interruption at the broadcast control station was solved, improving the stability of video playback and user experience.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- ALIBABA GROUP HOLDING LTD
- Filing Date
- 2020-07-31
- Publication Date
- 2026-07-10
Smart Images

Figure CN114071215B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of Internet technology, and in particular to a video playback method, device, system and storage medium. Background Technology
[0002] A video switcher is a device or system for editing and combining multiple video signals. During live production, all multiple video signals are sent to the switcher for real-time editing. The switcher functions like an electronic switch panel, allowing users to control the on / off state of each video signal circuit via buttons. The switcher can switch multiple received video streams into a single output stream as needed, or combine multiple video streams into a single output stream.
[0003] In practical applications, the broadcast control station often fails to obtain video from video sources such as cameras in a timely manner, resulting in interruptions in the video stream pushed to the audience and a poor viewing experience for users. Summary of the Invention
[0004] This application provides a video playback method, device, system, and storage medium to reduce the probability of video interruption, thereby helping to improve the user viewing experience.
[0005] This application provides a video playback system, including: a first video source node, a forwarding node, and a terminal device;
[0006] The first video source node is used to provide the first video stream to the forwarding node;
[0007] The forwarding node is configured to cache video frames of the second video stream already provided to the terminal device during the process of providing the second video stream to the terminal device; the second video stream is generated based on the first video stream; and, in the case that the video frames provided by the first video source node cannot be obtained, to obtain a first target video frame from the cached video frames; and to provide the first target video frame to the terminal device for playback.
[0008] This application also provides a video playback method, including:
[0009] Obtain the first video stream provided by the first video source node;
[0010] During the process of providing a second video stream generated based on the first video stream to a terminal device, video frames of the second video stream that have been provided to the terminal device are cached.
[0011] If the video frame provided by the first video source node cannot be obtained, the first target video frame is obtained from the cached video frames;
[0012] The first target video frame is provided to the terminal device for playback.
[0013] This application also provides an electronic device, including: a memory, a processor, and a communication component; wherein the memory is used to store a computer program;
[0014] The processor is coupled to the memory and is used to execute the computer program to perform the steps in the video playback method described above.
[0015] This application also provides a computer-readable storage medium storing computer instructions, which, when executed by one or more processors, cause the one or more processors to perform the steps in the video playback method described above.
[0016] In this embodiment, the forwarding node caches video frames already provided to the terminal device while pushing the video stream to the terminal device. If it cannot obtain video frames from the video source node, it retrieves the target video frame from the cached frames and provides it to the terminal device for playback. This ensures that even if communication between the video source node and the forwarding node fails, the terminal device can continue playing the video, reducing the probability of video interruption during playback and improving the user viewing experience. Attached Figure Description
[0017] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments of this application and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings:
[0018] Figure 1a This is a schematic diagram of the structure of a video playback system provided in an embodiment of this application;
[0019] Figure 1b This is a schematic diagram of another video playback system provided in an embodiment of this application;
[0020] Figure 1c This is a schematic diagram of the layer processing process provided in an embodiment of this application;
[0021] Figure 1d This is a schematic diagram of the structure of another video playback system provided in an embodiment of this application;
[0022] Figure 1e This is a schematic diagram of the video frame selection strategy priority setting interface provided in an embodiment of this application;
[0023] Figure 1f This is a schematic diagram of the target video frame selection strategy selection interface provided in the embodiments of this application;
[0024] Figure 1g A signaling diagram illustrating the transition process provided in the embodiments of this application;
[0025] Figure 1h A logical structure diagram of the broadcast control service provided in the embodiments of this application;
[0026] Figure 2 and Figure 3 A flowchart illustrating the video playback method provided in this application embodiment;
[0027] Figure 4 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation
[0028] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions of this application will be clearly and completely described below in conjunction with specific embodiments and corresponding drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of them. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0029] In existing technologies, forwarding nodes often experience video stream interruptions when pushing videos to viewers due to their inability to obtain video from video sources such as cameras in a timely manner, resulting in a poor viewing experience. To address this technical problem, in some embodiments of this application, the forwarding node caches video frames already provided to the terminal device during the process of pushing the video stream to the terminal device; and if it cannot obtain video frames from the video source node, it retrieves the target video frame from the cached video frames and provides the target video frame to the terminal device for playback. In this way, even if the communication between the video source node and the forwarding node fails, the terminal device can continue to play the video to the viewer, thereby reducing the probability of video stream interruptions during playback and helping to improve the user viewing experience.
[0030] The technical solutions provided by the various embodiments of this application are described in detail below with reference to the accompanying drawings.
[0031] It should be noted that the same reference numerals denote the same object in the following figures and embodiments. Therefore, once an object is defined in one figure or embodiment, it does not need to be discussed further in subsequent figures and embodiments.
[0032] Figure 1a This is a schematic diagram of the structure of a video playback system provided in an embodiment of this application. Figure 1a As shown, the video playback system includes: video source node 11, forwarding node 12, and terminal device 13. Figure 1aThe video source node 11, forwarding node 12 and terminal device 13 shown in the text are merely illustrative examples and do not limit their implementation.
[0033] In this embodiment, video source node 11 refers to an electronic device that can provide video data to forwarding node 12. In some embodiments, video source node 11 can be an image acquisition device with video acquisition capabilities, such as a camera, camcorder, webcam, or terminal device with video acquisition capabilities. The terminal device can be a smartphone, tablet, or wearable device, etc. For the image acquisition device, it can capture video and provide the captured video to forwarding node 12. That is, for the image acquisition device, the video stream provided to forwarding node 12 can be a video stream captured in real time by the image acquisition device.
[0034] If the video source node 11 is an image acquisition device, the connection between the video source node 11 and the forwarding node 12 can be wireless or wired. Optionally, the video source node 11 can communicate with the forwarding node 12 via a mobile network. Accordingly, the mobile network standard can be any one of 2G (GSM), 2.5G (GPRS), 3G (WCDMA, TD-SCDMA, CDMA2000, UTMS), 4G (LTE), 4G+ (LTE+), 5G, WiMax, etc. Optionally, the video source node 11 can also communicate with the forwarding node 12 via Bluetooth, WiFi, infrared, etc.
[0035] In other embodiments, the video source node 11 is a storage node storing video data. The storage node can be any storage medium or electronic device with data storage capabilities. For example, it can be a hard drive, USB flash drive, or other storage medium; or a terminal device such as a computer, mobile phone, or wearable device. Alternatively, the storage node can be a single server device, a cloud-based server array, or a virtual machine (VM), container, or container group with storage capabilities within a cloud-based server array. The storage node can provide pre-stored video data to the forwarding node 12. That is, the video stream provided by the storage node to the forwarding node 12 can be a video stream pre-stored on the storage node. The storage node can be a storage medium deployed on the physical machine where the forwarding node 12 resides, or it can be a storage medium deployed on other physical machines.
[0036] For the video source node 11 being a storage medium deployed on other physical machines, the video source node 11 and the forwarding node 12 can be connected wirelessly or wiredly. For specific communication methods, please refer to the above-mentioned communication method between the video source node 11 and the forwarding node 12 when the video source node 11 is an image acquisition device.
[0037] In this embodiment, the number of video source nodes 11 can be one or more. "More than" means two or more. The video stream provided by multiple video source nodes 11 can be a video stream shot from different perspectives of the same scene, i.e., a multi-view video stream.
[0038] In this embodiment, forwarding node 12 refers to a computer device capable of managing video data and providing users with services related to video forwarding, generally possessing the ability to undertake and guarantee the service. The user of forwarding node 12 refers to the provider of the live streaming service. For example, if a company wants to broadcast a sporting event live, the user of forwarding node 12 is that company; or, for example, if a user wants to live stream e-commerce, the user of forwarding node 12 could be the live streamer or the platform providing the live stream e-commerce service; and so on.
[0039] In this embodiment, the number of forwarding nodes 12 can be one or more. Multiple forwarding nodes 12 can be deployed on the same physical machine or on different physical machines. The physical machine where the forwarding node 12 resides can be a single server device, a cloud-based server array, or a virtual machine (VM), container, or container group running within a cloud-based server array. Alternatively, a physical machine can also refer to other computing devices with corresponding service capabilities, such as computers or other terminal devices (running service programs).
[0040] In this embodiment, the implementation form of the forwarding node 12 is not limited. In some embodiments, the forwarding node 12 can be a video source node other than the first video source node. In other embodiments, the forwarding node 12 can be implemented as a broadcast control station. Optionally, the forwarding node 12 can be a private broadcast control station of the video playback service provider, which can be deployed in any physical space specified by the video playback service provider, or in the private cloud of the video playback service provider. The video playback service provider can provide live streaming services, video-on-demand services, or recorded streaming services, etc. Accordingly, the video playback system provided in this application embodiment can be applied to live streaming scenarios, video-on-demand scenarios, or video recorded streaming scenarios, but is not limited thereto.
[0041] Alternatively, forwarding node 12 can also be a broadcast control console provided by a cloud developer, deployed in the cloud developer's public cloud as a cloud broadcast control console. In this case, the video playback service provider can apply to the cloud broadcast control console to provide broadcast control services for its live broadcast. Optionally, the video playback service provider can pre-register on the cloud broadcast control console and log in using the pre-registered account and password to use the cloud broadcast control services provided by the cloud broadcast control console.
[0042] Accordingly, the cloud-based broadcast control platform can provide broadcast control services to video playback service providers. In some embodiments, the video playback service provider can access the cloud broadcast control platform through the browser of its broadcast control device. The cloud broadcast control platform returns a login page to the broadcast control device; the video playback service provider can log in to the cloud broadcast control platform using pre-registered account and password information. Furthermore, the cloud broadcast control platform can return a broadcast control interface to the broadcast control device, through which the video playback service provider can perform broadcast control.
[0043] Alternatively, the video playback service provider can independently develop the director interface and call the director service through the application programming interface (API) provided by the cloud director platform to achieve the connection between the director platform and the API interface provided by the cloud director platform 12.
[0044] In this embodiment, terminal device 13 refers to a computer device used by a user that has communication and video playback functions, such as a smartphone, tablet computer, personal computer, wearable device, etc. Alternatively, terminal device 13 can also be a video playback device formed by a digital video converter box (STB) and a television set. The digital video converter box is commonly referred to as a set-top box or set-top box.
[0045] In this embodiment, the connection between the forwarding node 12 and the terminal device 13 can be wireless or wired. The specific communication method can be referred to the communication method between the video source node 11 and the forwarding node 12 described above, and will not be repeated here.
[0046] In this embodiment, the forwarding node 12 can provide the video stream obtained from the video source node 11 to the terminal device 13, which then plays it to the audience. The forwarding node 12 can either directly provide the video stream obtained from the video source node 11 to the terminal device 13, or it can process the video stream obtained from the video source node 11 before providing it to the terminal device 13. For ease of description and distinction, in the following embodiments of this application, the video stream provided by the video source node 11 to the forwarding node 12 is defined as the first video stream; and the video stream provided by the forwarding node 12 to the terminal device 13 is defined as the second video stream.
[0047] The second video stream can be the first video stream or other video streams generated based on the first video stream. For example, the second video stream can be the video stream obtained after the forwarding node 12 processes the first video stream. In some embodiments, such as Figure 1bAs shown, video source nodes 11 consist of multiple image acquisition devices that capture the same scene from different perspectives, resulting in a multi-view video stream. For forwarding node 12, the first video stream is a multi-view video stream. Multiple video source nodes 11 can provide the first video stream to forwarding node 12 in the form of video frames according to a set video transmission rate. Each video source node 11 has a different perspective, and therefore provides video frames to forwarding node 12 with different perspectives. For forwarding node 12, each time it receives video frames from multiple video source nodes 11, these video frames form a multi-view video frame. Accordingly, forwarding node 12 can treat each received multi-view video frame as multiple layers. The number of layers can be determined by the number of video source nodes 11, with each video frame in the multi-view video frame constituting one layer. Further, forwarding node 12 can render multiple layers onto a background layer according to a set rendering template, thereby obtaining a video frame in the second video stream. Optionally, as... Figure 1c As shown, forwarding node 12 can merge multiple layers according to the set rendering template, and map the merged layers onto the background layer to obtain a video frame in the second video stream (i.e., Figure 1c (The video frames in the video stream). By processing each received multi-view video frame in the same way, the second video stream can be obtained.
[0048] Furthermore, the forwarding node 12 provides the second video stream to the terminal device 13 for playback. Optionally, the forwarding node 12 can provide the second video stream to the terminal device 13 in batches in the form of video frames according to a set video transmission rate.
[0049] In practical applications, communication between video source node 11 and forwarding node 12 may fail, leading to video interruptions, stuttering, or other issues. Forwarding node 12 will be unable to acquire video frames from the first video stream, and therefore cannot provide new video frames to terminal device 13, resulting in a break in the video stream at terminal device 13. This undoubtedly affects the viewer's experience. Possible communication failures between video source node 11 and forwarding node 12 include one or more of the following: video source node 11 experiencing acquisition or video transmission failure, forwarding node 12 experiencing video reception failure, and the transmission link between video source node 11 and forwarding node 12 experiencing failure. "Multiple" refers to two or more types of failures.
[0050] To address the aforementioned issues, in this embodiment, the forwarding node 12 can cache video frames of the second video stream already provided to the terminal device 13 during the process of providing the second video stream to the terminal device 13. Furthermore, if the forwarding node 12 cannot obtain video frames provided by the first video source node, it can obtain the target video frame from the cached video frames and provide it to the terminal device 13 for playback. Thus, even if a video stream interruption occurs between the video source node 11 and the forwarding node 12, the terminal device 13 can still obtain and play video frames normally, thereby reducing the probability of video stream interruptions during video forwarding, improving video playback stability, and enhancing the user viewing experience.
[0051] In this embodiment, the forwarding node 12 can time the interval between receiving two adjacent video frames each time it receives a video frame provided by the video source node 11. If the forwarding node 12 has not received the next video frame provided by the video source node 11 within an interval greater than or equal to a set duration (defined as the first duration), it can be determined that the forwarding node 12 cannot obtain the video frame provided by the video source node 11. The first duration can be determined by the video transmission rate between the video source node 11 and the forwarding node 12, and the video transmission rate between the forwarding node 12 and the terminal device 13. Preferably, the first duration is less than or equal to the user's visual persistence time.
[0052] Furthermore, if the video frame provided by the video source node 11 cannot be obtained, the forwarding node 12 can obtain the target video frame from the cached video frames and provide the target video frame to the terminal device 13 for playback. The target video frame can be one or more video frames, where "multiple frames" refers to two or more frames. The video frames cached by the forwarding node 12 include: video frames from the second video stream that have already been forwarded to the terminal device 13, and may also include: video frames from other video streams that have been forwarded to the terminal device 13 before the second video stream.
[0053] In some embodiments, the forwarding node 12 is configured with a video frame selection strategy, which allows the target video frame to be obtained from the video frames cached by the forwarding node 12 according to the video frame selection strategy. In this embodiment, the number and specific implementation of the video frame selection strategy are not limited. Several optional implementation methods are described below as examples.
[0054] Selection Strategy 1: The target video frame is the N video frames in the second video stream cached by forwarding node 12 that are closest to the current time. N is a positive integer. Accordingly, forwarding node 12 can obtain the N video frames closest to the current time from the cached second video stream as the target video frame and provide the target video frame to terminal device 13. Preferably, N=1, which can prevent rewinding and help to further improve the viewing experience.
[0055] Strategy 2: The video frames cached by forwarding node 12 carry tag information. This tag information can be set by the user (director) of the broadcasting equipment 14. Optionally, forwarding node 12 can provide a tag setting interface to the broadcasting equipment 14. The broadcasting equipment 14 can display this tag setting interface, allowing the director to set tag information for the cached video frames. The tag information can represent the characteristics of the cached video frames. For example, the tag information can be highlights or important plot points. Correspondingly, forwarding node 12 can obtain the tag information of the video frames in the cached second video stream, and can extract the video frames with the set tag information from the cached second video stream as target video frames. The set tag information can be highlights or important plot points.
[0056] Selection Strategy 3: Forwarding node 12 can obtain the access count of video frames in the cached second video stream; based on the access count, it can obtain the first target video frame from the cached second video stream's video frames. Optionally, forwarding node 12 can obtain video frames from the cached second video stream whose access count is greater than or equal to a set access count threshold as target video frames. Alternatively, forwarding node 12 can sort the cached second video stream's video frames according to their access count; and select M video frames in descending order of access count as target video frames. Here, M is a positive integer.
[0057] Strategy 4: Forwarding node 12 can obtain the video frame containing the target object from the cached second video stream video frames, and use it as the target video frame. The target object can be a specified person or role, etc.
[0058] The target object can be specified by the user of terminal device 13. Terminal device 13 can display a target object selection interface, allowing the user of terminal device 13 to select the target object. In response to a selection completion event, terminal device 13 can provide the identifier of the target object to forwarding node 12. Forwarding node 12 can obtain the characteristics of the target object based on the identifier; and based on the characteristics of the target object, identify the video frame containing the target object from the video frames of the cached second video stream; and according to the timestamp information of the video frame containing the target object, obtain the N video frames closest to the current time as the target video frame.
[0059] Optionally, the target object selection interface may include a selection completion control. Accordingly, the aforementioned selection completion event may be implemented as an event generated by the terminal device 13 in response to a touch operation on the selection completion control.
[0060] Strategy 5: The video frames cached by forwarding node 12 also include other video streams that have been played before the second video stream. These other video frames can be played advertisements, highlights from the second video stream, short videos, etc. Accordingly, forwarding node 12 can also use video frames from other video streams as target video frames.
[0061] It is worth noting that, in this embodiment, the video frame selection strategy set in the forwarding node 12 can be one or more. "Multiple" refers to two or more strategies. The selection strategies 1-5 mentioned above can be partially or entirely set in the forwarding node 12. If the video frame selection strategy set in the forwarding node 12 is multiple, a priority for each strategy can be preset. Accordingly, the forwarding node 12 can obtain the priority of the set video frame selection strategy; determine the target video frame selection strategy from the multiple video frame selection strategies based on the priority; and obtain the first target video frame from the cached video frames according to the target video frame selection strategy. Optionally, the forwarding node 12 can select the strategy with the highest priority from the multiple video frame selection strategies as the target video frame selection strategy.
[0062] The priority of various video frame selection strategies can be set by the director of the broadcast control equipment 14 or the user of the terminal device. If set by the user of the terminal device 13, for example... Figure 1e As shown, terminal device 13 can display selection information items. These selection information items include: multiple video frame selection strategies. Users can set the priority of these multiple video frame selection strategies. Among them, Figure 1e The numbers 1-5 can represent priority order. Furthermore, in response to a setup completion event, terminal device 13 can also provide the priority of various video frame selection strategies to forwarding node 12. Optionally, such as Figure 1eAs shown, terminal device 13 can also display a "OK" control indicating that the settings are complete. Accordingly, the aforementioned "setting complete" event can be implemented as an event generated by terminal device 13 in response to a touch operation on the setting complete control. Of course, the priority of various video frame selection strategies can be set by the director user of broadcasting equipment 14. The setting method can be found in the aforementioned content regarding the user setting the priority of various video frame selection strategies on terminal device 13, and will not be repeated here.
[0063] Alternatively, the target video frame selection strategy can also be set by the director of the broadcast equipment 14 or the user of the terminal equipment. For example, if set by the user of the terminal equipment 13... Figure 1f As shown, terminal device 13 can display selection information items. These selection information items include: multiple video frame selection strategies. Users can select the desired video frame selection strategy from these options. Figure 1f In the diagram, the checkmark after the selected strategy indicates the selected target video frame selection strategy. Accordingly, in response to a completion event for selecting multiple video frame selection strategies, terminal device 13 provides the selected video frame selection strategy as the identifier of the target video frame selection strategy to forwarding node 12. Of course, the priority of the target video frame selection strategy can be selected by the director user of broadcast equipment 14. The selection method can be found in the aforementioned content regarding the user selection of the target video frame selection strategy by terminal device 13, and will not be repeated here.
[0064] Accordingly, forwarding node 12 can obtain the target video frame selection strategy selected by the user of terminal device 13 (or the director of broadcasting device 14) according to the identifier of the target video frame selection strategy; and obtain the target video frame from the cached video frames according to the target video frame selection strategy.
[0065] In addition to providing the aforementioned directing service for the same video stream, the forwarding node 12 provided in this embodiment also provides a transition service. Transitions mainly include scene switching, layout switching, and advertising insertion. Layout refers to the layout of the video stream in the Preview (PVM) area and the Program (PGM) area of the broadcast interface. PVW is mainly used in conjunction with PGM, because the effect needs to be checked before actually broadcasting the PGM signal. If the display effect is satisfactory, it can be switched to PGM.
[0066] In this embodiment, forwarding node 11 can provide transition services. For the director, when a transition is needed, they can operate the directing equipment 14 to switch video sources. In this embodiment, for ease of description and distinction, the video source node 11 that provides the first video stream before switching video sources is defined as the first video source node; the video source that provides the video stream after switching video sources is defined as the second video source node, such as... Figure 1d The second video source node 15 is shown. The implementation of the second video source node 15 can be found in the relevant content of the video source node 11 mentioned above, and will not be repeated here. Figure 1d The illustration uses only the second video source node 15 as a desktop computer, but this does not constitute a limitation.
[0067] The second video source node 15 and the first video source node 11 can be on the same physical machine or on different physical machines. If the first video source node 11 and the second video source node 15 are on the same physical machine, the video source switching operation can be understood as switching the video stream acquisition path.
[0068] Accordingly, forwarding node 12 can switch the video source from the first video source node 11 to the second video source node 15 in response to a video source switching operation. Optionally, forwarding node 12 can provide a director interface to broadcasting device 14, which displays a video source switching control. The director can trigger the video source switching control to switch the video source. Further, broadcasting device 14 can display a selection control for the video source node to be switched in response to the video source switching control, and in response to the selection operation of the video source node selection control, select the selected video source node as the second video source node 15. Further, broadcasting device 14 can send a video source switching request to forwarding node 12, which includes the identifier of the second video source node 15 to be switched. Forwarding node 12 can receive the video source switching request and switch the video source from the first video source node 11 to the second video source node 15 according to the identifier of the second video source node 15.
[0069] In practical applications, during transitions, network jitter or interruptions may prevent the forwarding node 12 from timely acquiring the video stream provided by the second video source node 15, resulting in a disconnection or black screen on the terminal device 13. In this embodiment, to prevent this, the forwarding node 12 can monitor whether it receives the video frame provided by the second video source node 15 in a timely manner after the video source switching operation occurs. Optionally, the forwarding node 12 can start timing from the time the video source switching operation occurs. If no video frame is received from the second video source node within a set time period (denoted as the second time period), the target video frame is obtained from the cached second video stream; and the target video frame is provided to the terminal device 13 for playback. In this embodiment, for ease of description and distinction, the target video frame obtained by the forwarding node 12 from the cached video frames of the second video stream when it cannot obtain the video frame provided by the first video source node 11 is defined as the first target video frame; and the target video frame obtained by the forwarding node 12 from the cached video frames of the second video stream when it does not receive the video frame provided by the second video source node within a set time period (denoted as the second time period) after the video source switching operation occurs is defined as the second target video frame. The second target video frame and the first target video frame may be the same or different, depending on the timing of the video source switching operation. For a detailed implementation of how the forwarding node 12 obtains the second target video frame from the cached video frames of the second video stream, please refer to the relevant content on how the forwarding node 12 obtains the first target video frame from the cached video frames of the second video stream, which will not be repeated here. In this way, even if the communication between the second video source node 15 and the forwarding node 12 fails during the transition process, causing the forwarding node 12 to be unable to obtain the video frames of the second video source node 15 in a timely manner, the terminal device 13 can still display the second target video frame, which can prevent the terminal device 13 from experiencing video interruption or black screen, and helps to improve the viewing experience of the audience.
[0070] Accordingly, if forwarding node 12 receives a video frame provided by second video source node 15 within the second time period set during the video source switching operation, it provides the currently received first video frame and second target video frame to terminal device 13 for playback. The video stream provided by second video source node 15 is defined as the third video stream. The first video frame is the video frame that terminal device 13 will play, and the second target video frame is the video frame that will disappear from the display screen of terminal device 13.
[0071] Optionally, to improve transition effects, transition effects can be added. Forwarding node 12 can maintain special effects device information corresponding to multiple effects. "Multiple" refers to two or more effects. The special effects settings information corresponding to these multiple effects, as well as the logic for processing video frames with effects, can be embedded into forwarding node 12 as a plugin. Extending effects using a plugin approach allows for the expansion of effects without modifying the existing directing logic provided by forwarding node 12. This not only reuses existing directing logic, reducing development costs and workload, but also facilitates the horizontal expansion of effects, improving the versatility and flexibility of effect settings.
[0072] Optionally, the various effects maintained by forwarding node 12 can be categorized in a two-level manner. The effect's appearance (e.g., entry / exit, IN / OUT) serves as the first-level category, and the effect type (e.g., implicit / fly, Fade / Fly) serves as the second-level category. These two categories can be registered to the effect management module (effect_manager) of forwarding node 12 via macro definitions, allowing for the rapid addition of new effects without altering the existing main flow of the broadcast logic. Optionally, this embodiment can provide layer-level effect settings. When scene switching is involved, each layer can contain complete effects, which can be arbitrarily combined. Assuming there are currently n first-level categories and m second-level categories, each layer can have n*m effects.
[0073] For forwarding node 12, in response to an effect selection operation for a first video frame, it can perform effect processing on the first video frame according to the effect setting information corresponding to the selected first effect, to obtain an effect-processed first video frame; and in response to an effect selection operation for a second target video frame, it can perform effect processing on the second target video frame according to the effect setting information corresponding to the selected second effect, to obtain an effect-processed second target video frame. The first effect is an effect associated with screen entry, that is, the first effect determines how the first video frame appears on the display screen of terminal device 13. For example, the first effect can be fade-in, fly-in, float-in, flash, rotation, or bounce, etc. Accordingly, the effect setting information corresponding to the first effect includes: the start time, end time, and identifier of the first effect, as well as the duration and repetition count of each action in the first effect, etc.
[0074] Accordingly, the second effect is an effect associated with the screen disappearance, meaning the first effect determines how the first video frame disappears from the display screen of the terminal device 13. For example, the first effect could be fade-out, fly-out, float-out, flash-out, rotation, or bounce, etc. The effect setting information corresponding to the second effect includes: the start time and end time of the second effect, the identifier of the second effect, and the duration and repetition number of each action in the second effect, etc.
[0075] Optionally, the forwarding node 12 can display special effects setting controls on the directing interface provided to the broadcasting device 14. The director can trigger these controls to set special effects. Further, the broadcasting device 14 can display multiple special effects information items in response to the special effects setting controls. "Multiple" refers to two or more types. Further, the broadcasting device 14 can select a special effect as the first special effect in response to a selection operation for a specific special effects information item. Further, the broadcasting device 14 can send a special effects setting request to the forwarding node 12, which includes the identifier of the first video frame and the identifier of the first special effect. Correspondingly, the forwarding node 12 parses the identifier of the first video frame and the identifier of the first special effect from the special effects setting request, and obtains the special effects setting information of the first special effect based on the identifier of the first special effect. Further, the forwarding node 12 can perform special effects processing on the first video frame according to the special effects setting information corresponding to the selected first special effect, obtaining a first video frame with special effects processing. Following the same method, forwarding node 12 can receive another effect setting request, which includes the identifier of the second target video frame and the identifier of the second effect. Accordingly, forwarding node 12 parses the identifier of the second target video frame and the identifier of the first effect from the effect setting request, and obtains the effect setting information of the second effect based on the identifier of the second effect. Further, forwarding node 12 can perform effect processing on the second target video frame according to the effect setting information corresponding to the selected second effect, obtaining the effect-processed second target video frame.
[0076] In this embodiment, the specific implementation of special effects processing for the first video frame and the second target video frame is not limited. Optionally, the forwarding node 14 can perform special effects processing on multiple layers contained in the first video frame according to the special effects setting information corresponding to the first special effect, so as to obtain the first video frame after special effects processing. Correspondingly, the forwarding node 14 can also perform special effects processing on multiple layers contained in the second target video frame according to the special effects setting information corresponding to the second special effect, so as to obtain the second target video frame after special effects processing. In this way, special effects processing at the layer level can be realized, and special effects interaction between layers can be realized. Optionally, the same special effects can be set for different layers of the same video frame, or different special effects can be set. The specific special effects setting method can be selected by the director.
[0077] Alternatively, forwarding node 12 can configure corresponding special effects algorithms for multiple layers contained in the first video frame, and use these algorithms to process the multiple layers in the first video frame to obtain a first video frame with special effects processed. Here, the special effects algorithm configured by forwarding node 12 for the multiple layers in the first video frame is an effect algorithm associated with the in-screen effect. Similarly, forwarding node 12 can also configure corresponding special effects algorithms for multiple layers contained in the second target video frame, and use these algorithms to process the multiple layers in the second target video frame to obtain a second target video frame with special effects processed. Here, the special effects algorithm configured by forwarding node 12 for the multiple layers in the second target video frame is an effect algorithm associated with the out-of-screen effect.
[0078] Furthermore, forwarding node 12 can provide the first video frame with special effects processing and the second target video frame with special effects processing to the terminal device 13 for playback. Correspondingly, for the terminal device 13, the second target video frame disappears from its display screen using the second special effect, and the first video frame appears on its display screen using the first special effect. Thus, adding transition effects during the transition process helps to further enhance the viewer's viewing experience.
[0079] To illustrate the transition process more clearly, the following will combine... Figure 1g The signaling diagram illustrating the transition process shown is provided as an example. Figure 1g As shown, the transition process mainly includes:
[0080] Step 1: Bind the first video stream (video stream 1) to layer 1. Layer 1 is used to process video stream 1 to obtain the second video stream. The processing of video stream 1 by layer 1 includes layer merging, layer mapping, etc.
[0081] Step 2: Input the second video stream into the current playlist.
[0082] Step 3: Retrieve video frames from the current playlist and push the retrieved video frames to terminal device 13. Terminal device 13 then plays the video frames.
[0083] Step 4: In response to the video source switching operation, switch the video source from the first video stream (video stream 1) to the third video stream (video stream 2); and bind video stream 2 to layer 2. Layer 2 is used to process video stream 2 to obtain the fourth video stream. The processing of video stream 2 by layer 2 includes: layer merging, layer mapping, etc.
[0084] Optionally, Layer 2 can also apply special effects to the video frames of Video Stream 2. Optionally, Layer 2 can obtain the first video frame with special effects processed based on the effect settings information of the first effect mentioned above. The first effect is an effect associated with the in-screen input. The first video frame can be the first frame of video to be played in Video Stream 2.
[0085] Step 5: Input the fourth video stream into the current playlist.
[0086] Step 6: Update the cached playlist, that is, cache the video frames of the second video stream pushed by the forwarding node 12 to the terminal device 13 during the video source switching operation to the cached playlist.
[0087] Step 7: Unregister the video frames of the second video stream pushed by layer 1 in the current playlist.
[0088] Step 8: Cache the video frames of the second video stream pushed from Layer 1 to the cache playlist.
[0089] Optionally, Layer 1 can also apply special effects to the video frames of the second video stream. This can be done by applying special effects based on the aforementioned settings for the second special effect, resulting in video frames with the effects applied. The second special effect is an effect associated with out-of-screen display.
[0090] Step 9: Retrieve the video frame of the fourth video stream from the current playlist, and retrieve the target video frame (the aforementioned second target video frame) from the cached playback queue; then push the retrieved video frame of the fourth video stream and the second target video frame to the terminal device 13. The terminal device 13 will then play them.
[0091] Step 10: Unregister the video frames of the second video stream pushed by layer 1 from the cache playlist.
[0092] Step 11: Unregister the processing of video frames of the first video stream (video stream 1) by layer 1.
[0093] It should be noted that, in the embodiments of this application, steps 1-11 are not limited to being executed sequentially; they can also be executed in parallel. Alternatively, some steps can be executed sequentially, and some can be executed in parallel. For steps executed sequentially, the order in which these steps are executed is not limited.
[0094] It should also be noted that the transition effects provided in this embodiment can be embedded into the forwarding node 12 as a plug-in. The directing service provided by the forwarding node 12 to the video playback service provider may include: a first mode providing transition effects services and a second mode not providing transition effects services. Optionally, the directing interface provided by the forwarding node 12 to the broadcasting device 14 may display a directing service mode selection control. The video playback service provider can choose which directing service mode to use through the directing service mode selection control. For the forwarding node 12, in response to the selection operation of the directing service mode, it can provide the video playback service provider with the selected directing service mode.
[0095] like Figure 1h As shown in the embodiments of this application, the broadcast service architecture mainly includes: a broadcast application layer, a layer conversion layer, a functional module layer, a material layer, a management layer, an algorithm logic layer, and an atomic capability layer. These layers can be called sequentially from top to bottom. The broadcast application layer is mainly used for command parsing of broadcast device instructions, managing broadcast tasks, and scheduling tasks. The layer conversion layer is used for layer processing of the video stream provided by the video source node, converting the video stream into layers of a unified architecture type. The functional module layer provides processing functions. The functional modules in the functional module layer mainly include: a layout function mainly used for layout processing between layers; a preprocessing function mainly used to convert layers into a unified architecture type; a rendering function mainly used for rendering layers to obtain video frames; and a special effects function mainly used for applying special effects to layers. The material layer refers to the material types supported by the broadcast service, mainly including: video, audio, images, text, and animation. The management layer is mainly used for managing the video stream and special effects. The video stream management module manages the video stream, including playback, pause, and shutdown. The effects management module manages effects, such as determining their duration, start and end times, and which effect to use. The algorithm logic layer provides relevant algorithms, including reuse algorithms, encoding and decoding algorithms, observation algorithms, registration modes, synchronization modes, notification modes, and effects algorithms. Effects algorithms may include in-screen and out-of-screen effects. The atomic capability layer is the smallest unit of the broadcast service and includes configuration modification, communication protocols, and underlying filtering algorithms. Configuration modification modifies the configuration parameters of each algorithm in the algorithm logic layer; communication protocols provide the protocols supported by the broadcast service, such as RTMP and HTTP; and filtering algorithms process video frames.
[0096] In this embodiment of the application, the functional modules involved in transition effects can be embedded into the forwarding node 12 as plug-ins. For example, Figure 1hThe special effects processing functions, animation materials, special effects management, and special effects algorithms shown can all be embedded into the forwarding node 12 as plugins.
[0097] It is worth noting that, in order to improve transition efficiency and reduce transition latency, forwarding node 12 can also utilize hardware acceleration and / or optimize special effects algorithms to improve transition efficiency. Hardware acceleration can be achieved using high-speed processors. For example, a Field-Programmable Gate Array (FPGA) supporting parallel processing can be used instead of a CPU for transition effects processing, etc.
[0098] In addition to the video playback system embodiments described above, this application also provides a video playback method. The live streaming method provided by this application embodiment will be described by way of example from the perspective of the forwarding node.
[0099] Figure 2 This is a flowchart illustrating the video playback method provided in an embodiment of this application. Figure 2 As shown, the method includes:
[0100] 201. Obtain the first video stream provided by the first video source node.
[0101] 202. In the process of providing the second video stream generated based on the first video stream to the terminal device, the video frames of the second video stream already provided to the terminal device are cached.
[0102] 203. If the video frame provided by the first video source node cannot be obtained, obtain the first target video frame from the cached video frames.
[0103] 204. Provide the first target video frame to the terminal device for playback.
[0104] In this embodiment, the implementation of the first video source node and the forwarding node, the communication method between the first video source node and the forwarding node, and the implementation of the video stream can be found in the relevant content of the above system embodiment, and will not be repeated here.
[0105] In this embodiment, the number of first video source nodes can be one or more. "More than" means two or more. The video streams provided by multiple video source nodes can be video streams shot from different perspectives of the same scene, i.e., multi-view video streams.
[0106] In this embodiment, the forwarding node can provide the video stream obtained from the video source node to the terminal device, which then plays it to the audience. The forwarding node can either directly provide the video stream obtained from the video source node to the terminal device, or it can process the video stream obtained from the video source node before providing it to the terminal device. For ease of description and distinction, in the following embodiments of this application, the video stream provided by the video source node to the forwarding node is defined as the first video stream; and the video stream provided by the forwarding node to the terminal device is defined as the second video stream.
[0107] The second video stream can be the first video stream or other video streams generated based on the first video stream. For example, the second video stream can be a video stream obtained after the forwarding node processes the first video stream. In some embodiments, the first video source node is multiple image acquisition devices that capture the same scene from different perspectives to obtain a multi-view video stream. For the forwarding node, the first video stream is a multi-view video stream. Multiple video source nodes can provide the first video stream to the forwarding node in the form of video frames according to a set video transmission rate. Each video source node has a different perspective, and the perspective of the video frames provided to the forwarding node is also different. For the forwarding node, each time it receives video frames provided by multiple video source nodes, these video frames form a multi-view video frame. Accordingly, the forwarding node can treat each received multi-view video frame as multiple layers. The number of layers can be determined by the number of first video source nodes, with each video frame in the multi-view video frame being treated as a layer. Further, the forwarding node can render multiple layers onto a background layer according to a set rendering template, thereby obtaining a video frame in the second video stream. Optionally, as above... Figure 1c As shown, the forwarding node can merge multiple layers according to the set rendering template, and map the merged layers onto the background layer to obtain a video frame in the second video stream. By processing each received multi-view video frame in the same way, the second video stream can be obtained.
[0108] Furthermore, the forwarding node provides the second video stream to the terminal device for playback. Optionally, the forwarding node can provide the second video stream to the terminal device in batches as video frames, according to a set video transmission rate.
[0109] In practical applications, communication failures may occur between the video source node and the forwarding node, leading to video stream interruptions, stuttering, and other issues. The forwarding node cannot continue acquiring video frames from the first video stream, and therefore cannot provide new video frames to the terminal device, resulting in stream interruptions and negatively impacting the viewer's experience. These communication failures between the video source node and the forwarding node can be caused by one or more of the following: a video source node experiencing acquisition or transmission failure, a forwarding node experiencing video reception failure, or a failure in the transmission link between the video source node and the forwarding node. "Multiple failures" refers to two or more of these failures.
[0110] To address the aforementioned issues, in this embodiment, in step 202, the forwarding node can cache video frames of the second video stream already provided to the terminal device while providing the second video stream. Further, in step 203, if the forwarding node cannot obtain video frames from the first video source node, it can obtain the target video frame from the cached video frames of the second video stream; and in step 204, the target video frame is provided to the terminal device for playback. Thus, even if a video stream interruption occurs between the first video source node and the forwarding node, the terminal device can still normally obtain and play video frames, thereby reducing the probability of video stream interruptions during playback, improving video playback stability, and enhancing the user viewing experience.
[0111] In this embodiment, the forwarding node can time the interval between receiving two adjacent video frames each time it receives a video frame from the video source node. If the forwarding node has not received the next video frame from the video source node within an interval greater than or equal to a set duration (defined as a first duration), it can be determined that the forwarding node cannot obtain the video frame provided by the video source node. The first duration can be determined by the video transmission rate between the video source node and the forwarding node, and the video transmission rate between the forwarding node and the terminal device. Preferably, the first duration is less than or equal to the user's visual persistence time.
[0112] Furthermore, if the forwarding node cannot obtain the video frames provided by the video source node, it can obtain the target video frame from the cached second video stream and provide the target video frame to the terminal device for playback. The target video frame can be one or more video frames, with "multiple frames" referring to two or more frames.
[0113] In some embodiments, a video frame selection strategy is configured in the forwarding node, which can be used to obtain the target video frame from the video frames cached by the forwarding node. In this embodiment, the number and specific implementation of the video frame selection strategy are not limited. Several optional implementation methods are described below as examples.
[0114] Strategy 1: The target video frame is the N video frames in the second video stream cached by the forwarding node that are closest to the current time. N is a positive integer. Accordingly, the forwarding node can obtain the N video frames closest to the current time from the cached second video stream as the target video frame and provide the target video frame to the terminal device. Preferably, N=1, which can prevent rewinding and help to further improve the viewing experience.
[0115] Strategy 2: The video frames cached by the forwarding node carry tag information. This tag information can be set by the user (director) of the broadcasting equipment. Optionally, the forwarding node can provide a tag setting interface to the broadcasting equipment. The broadcasting equipment can display this tag setting interface, allowing the director to set tag information for the cached video frames. The tag information can represent the characteristics of the cached video frames. For example, the tag information can be highlights or important plot points. Correspondingly, the forwarding node can obtain the tag information of the video frames in the cached second video stream, and can extract the video frames with the set tag information from the cached second video stream as the target video frames. The set tag information can be highlights or important plot points, etc.
[0116] Strategy 3: The forwarding node can obtain the access count of the video frames in the cached second video stream; based on the access count, it can obtain the first target video frame from the cached second video stream's video frames. Optionally, the forwarding node can obtain video frames from the cached second video stream whose access count is greater than or equal to a set access count threshold as the target video frames. Alternatively, the forwarding node can sort the cached second video stream's video frames according to their access count; and select M video frames in descending order of access count as the target video frames. Here, M is a positive integer.
[0117] Strategy 4: The forwarding node can obtain the video frame containing the target object from the cached second video stream video frames, and use it as the target video frame. The target object can be a specified person or role, etc.
[0118] The target object can be specified by the user of the terminal device. The terminal device can display a target object selection interface, allowing the user to select the target object. In response to a selection completion event, the terminal device can provide the target object's identifier to the forwarding node. The forwarding node can obtain the target object's characteristics based on its identifier; and based on these characteristics, identify the video frame containing the target object from the cached second video stream's video frames; and according to the timestamp information of the video frame containing the target object, obtain the N video frames closest to the current time as the target video frame.
[0119] Optionally, the target object selection interface may include a selection completion control. Accordingly, the aforementioned selection completion event can be implemented as an event generated by the terminal device in response to a touch operation on the selection completion control.
[0120] Strategy 5: The video frames cached by the forwarding node also include those from other video streams that have been played before the second video stream. These other video frames can be previously played advertisements, highlights from the second video stream, short videos, etc. Accordingly, the forwarding node can also use video frames from other video streams as target video frames.
[0121] It is worth noting that, in this embodiment, the video frame selection strategy set in the forwarding node can be one or more. "Multiple" refers to two or more strategies. The selection strategies 1-5 mentioned above can be partially or fully set in the forwarding node. If multiple video frame selection strategies are set in the forwarding node, a priority for each strategy can be preset. Accordingly, the forwarding node can obtain the priority of the set video frame selection strategy; determine the target video frame selection strategy from the multiple video frame selection strategies based on the priority; and obtain the first target video frame from the cached video frames according to the target video frame selection strategy. Optionally, the forwarding node can select the strategy with the highest priority from the multiple video frame selection strategies as the target video frame selection strategy.
[0122] The priority of various video frame selection strategies can be set by the director of the broadcast equipment or the user of the terminal equipment. If set by the user of the terminal equipment, the terminal equipment can display selection information items. These selection information items include: various video frame selection strategies. The user can set the priority of various video frame selection strategies. Furthermore, the terminal equipment can also provide the priority of various video frame selection strategies to the forwarding node in response to a setting completion event. Optionally, the terminal equipment can also display a setting completion control. Accordingly, the aforementioned setting completion event can be implemented as an event generated by the terminal equipment in response to a touch operation on the setting completion control. Of course, the priority of various video frame selection strategies can also be set by the director of the broadcast equipment, and the setting method can be found in the relevant content on setting the priority of various video frame selection strategies by the user of the terminal equipment, which will not be repeated here.
[0123] Alternatively, the target video frame selection strategy can be set by the director of the broadcast equipment or the user of the terminal equipment. If set by the user of the terminal equipment, the terminal equipment can display selection information items. These selection information items include: multiple video frame selection strategies. The user can select the video frame selection strategy to be used from the multiple video frame selection strategies. Accordingly, in response to the completion event of the selection of multiple video frame selection strategies, the terminal equipment can provide the selected video frame selection strategy as the identifier of the target video frame selection strategy to the forwarding node. Of course, the priority of the target video frame selection strategy can be selected by the director of the broadcast equipment, and the selection method can be found in the relevant content on the selection of the target video frame selection strategy by the user of the terminal equipment mentioned above, which will not be repeated here.
[0124] Accordingly, the forwarding node can obtain the target video frame selection strategy selected by the user of the terminal device (or the director of the broadcasting device 14) according to the identifier of the target video frame selection strategy; and obtain the target video frame from the cached video frames according to the target video frame selection strategy.
[0125] In addition to providing the aforementioned directing service for the same video stream, the forwarding node provided in this application embodiment also provides a transition service. Transitions mainly include scene switching, layout switching, and advertisement insertion. Layout refers to the layout of the video stream in the Preview (PVM) area and the Program (PGM) area of the broadcast interface. PVW is mainly used in conjunction with PGM, because the effect needs to be checked before actually broadcasting the PGM signal. If the display effect is satisfactory, it can be switched to PGM.
[0126] In this embodiment, the forwarding node can provide transition services. For the director, when a transition is needed, they can operate the directing equipment to switch video sources. In this embodiment, for ease of description and distinction, the video source node providing the first video stream before switching video sources is defined as the first video source node; the video source providing the video stream after switching video sources is defined as the second video source node. The implementation of the second video source node can be found in the relevant content of the above system embodiment, and will not be repeated here.
[0127] The second video source node and the first video source node can be on the same physical machine or different physical machines. If the first video source node and the second video source node are on the same physical machine, the video source switching operation can be understood as switching the video stream acquisition path.
[0128] The following is combined with Figure 3 The transition process shown is an illustrative example of the transition method provided in this embodiment. Figure 3 As shown, the transition methods include:
[0129] 301. In response to the video source switching operation, switch the video source from the first video source node to the second video source node.
[0130] 302. If no video frame is received from the second video source node within the set second time period after the video source switching operation occurs, the second target video frame is obtained from the video frames of the cached second video stream.
[0131] 303. Provide the second target video frame to the terminal device for playback.
[0132] In this embodiment, the forwarding node can switch the video source from the first video source node to the second video source node in response to the video source switching operation. For specific implementation details regarding the forwarding node switching the video source from the first video source node to the second video source node in response to the video source switching operation, please refer to the relevant content in the above system embodiment, which will not be repeated here.
[0133] In practical applications, during transitions, network jitter or interruptions may prevent the forwarding node from timely acquiring the video stream provided by the second video source node, leading to disconnection or a black screen on the terminal device. In this embodiment, to prevent this, the forwarding node can monitor whether it receives the video frame provided by the second video source node in a timely manner after the video source switching operation occurs. Optionally, the forwarding node can start timing from the time the video source switching operation occurs. If it does not receive the video frame provided by the second video source node within a set time period (denoted as the second time period), it acquires the target video frame from the cached video frames of the second video stream and provides the target video frame to the terminal device for playback. In this embodiment, for ease of description and distinction, the target video frame acquired from the cached video frames of the second video stream when the forwarding node cannot acquire the video frame provided by the first video source node is defined as the first target video frame; and the target video frame acquired from the cached video frames of the second video stream when the forwarding node does not receive the video frame provided by the second video source node within a set time period (denoted as the second time period) is defined as the second target video frame. The second target video frame and the first target video frame may be the same or different, depending on the timing of the video source switching operation. The specific implementation method for the forwarding node to obtain the second target video frame from the cached second video stream's video frames can be found in the section on obtaining the first target video frame from the cached second video stream's video frames, and will not be repeated here. Thus, even if communication between the second video source node and the forwarding node fails during the transition, preventing the forwarding node from obtaining the second video source node's video frames in a timely manner, the terminal device can still display the second target video frame, preventing video interruptions or black screens and improving the viewer's experience.
[0134] Accordingly, if the forwarding node receives a video frame from the second video source node within the second set time period after the video source switching operation occurs, it will forward the currently received first video frame and the second target video frame.
[0135] It is provided to the terminal device for playback. The first video frame is the video frame that the terminal device will play, and the second target video frame is the video frame that will disappear from the terminal device's display screen.
[0136] Optionally, transition effects can be added to improve the transition effect. The forwarding node can maintain information on the special effects devices corresponding to multiple effects. "Multiple" refers to two or more effects. The special effects settings information corresponding to these multiple effects, as well as the logic for processing video frames with effects, can be embedded into the forwarding node as a plugin. Extending effects using plugins allows for the expansion of effects without modifying the existing directing logic provided by the forwarding node. This not only reuses existing directing logic, reducing development costs and workload, but also facilitates the horizontal expansion of effects, improving the versatility and flexibility of effect settings.
[0137] Optionally, the various effects maintained by the forwarding node can be categorized in a two-level manner. The effect's appearance (e.g., IN / OUT) serves as the first-level category, and the effect type (e.g., implicit / fly) serves as the second-level category. These two categories can be registered to the effect management module (effect_manager) of the forwarding node via macro definitions, allowing for the rapid addition of new effects without altering the existing main flow of the broadcast logic. Optionally, this embodiment can provide layer-level effect settings. When scene switching is involved, each layer can contain complete effects, which can be arbitrarily combined. Assuming there are currently n first-level categories and m second-level categories, each layer can have n*m effects.
[0138] For a forwarding node, in response to an effect selection operation for a first video frame, the node applies effects processing to the first video frame according to the effect settings information corresponding to the selected first effect, resulting in an effect-processed first video frame. Similarly, in response to an effect selection operation for a second target video frame, the node applies effects processing to the second target video frame according to the effect settings information corresponding to the selected second effect, resulting in an effect-processed second target video frame. The first effect is an effect associated with the in-screen display, meaning it determines how the first video frame appears on the terminal device's screen. For example, the first effect could be fade-in, fly-in, float-in, flash, rotation, or bounce, etc. Correspondingly, the effect settings information for the first effect includes: the start time, end time, and identifier of the first effect, as well as the duration and repetition count of each action within the first effect.
[0139] Correspondingly, the second effect is the effect associated with the screen disappearance, meaning the first effect determines how the first video frame disappears from the terminal device's display. For example, the first effect could be fade-out, fly-out, float-out, flash-out, rotation, or bounce, etc. The effect settings information corresponding to the second effect includes: the start time and end time of the second effect, the identifier of the second effect, and the duration and repetition number of each action in the second effect, etc.
[0140] Optionally, the forwarding node can display special effects setting controls on the director's interface provided to the broadcasting device. The director can trigger these controls to set special effects. Further, the broadcasting device can respond to the special effects setting controls by displaying multiple special effects information items. "Multiple" refers to two or more types. Further, the broadcasting device can respond to a selection operation for multiple special effects information items by designating the selected effect as the first effect. Further, the broadcasting device can send a special effects setting request to the forwarding node, which includes the identifier of the first video frame and the identifier of the first special effect. Accordingly, the forwarding node parses the identifier of the first video frame and the identifier of the first special effect from the special effects setting request, and obtains the special effects setting information for the first special effect based on the identifier of the first special effect. Further, the forwarding node can perform special effects processing on the first video frame according to the special effects setting information corresponding to the selected first special effect, obtaining a first video frame with special effects processing. Following the same method, the forwarding node can receive another special effects setting request, which includes the identifier of a second target video frame and the identifier of a second special effect. Accordingly, the forwarding node parses the identifier of the second target video frame and the identifier of the first effect from the effect setting request, and obtains the effect setting information of the second effect based on the identifier of the second effect. Further, the forwarding node can perform effect processing on the second target video frame according to the effect setting information corresponding to the selected second effect, obtaining the effect-processed second target video frame.
[0141] In this embodiment, the specific implementation of special effects processing for the first video frame and the second target video frame is not limited. Optionally, the forwarding node can perform special effects processing on multiple layers contained in the first video frame according to the special effects setting information corresponding to the first special effect, so as to obtain the first video frame after special effects processing. Correspondingly, the forwarding node can also perform special effects processing on multiple layers contained in the second target video frame according to the special effects setting information corresponding to the second special effect, so as to obtain the second target video frame after special effects processing. In this way, layer-level special effects processing can be realized, and special effects interaction between layers can be realized. Optionally, the same special effects can be set for different layers of the same video frame, or different special effects can be set. The specific special effects setting method can be selected by the director.
[0142] Furthermore, the forwarding node can provide the terminal device with both the processed first video frame and the processed second target video frame for playback. Correspondingly, for the terminal device, the second target video frame disappears from the display screen using the second effect, while the first video frame appears on the display screen using the first effect. Thus, adding transition effects during the transition process helps to further enhance the viewer's viewing experience.
[0143] It is worth noting that the above Figure 2 and Figure 2Optional implementation methods and Figure 3 and Figure 3 The associated implementation methods can be implemented individually or in combination. Figure 2 and Figure 3 When the implementation methods shown are combined, the order of execution is not limited.
[0144] It should be noted that the execution subject of each step of the method provided in the above embodiments can be the same device, or the method can be executed by different devices. For example, the execution subject of steps 201 and 202 can be device A; or the execution subject of step 201 can be device A, and the execution subject of step 202 can be device B; and so on.
[0145] Furthermore, some processes described in the above embodiments and accompanying drawings include multiple operations that appear in a specific order. However, it should be clearly understood that these operations may not be executed in the order they appear herein, or they may be executed in parallel. The operation numbers, such as 201, 202, etc., are merely used to distinguish different operations and do not represent any execution order. In addition, these processes may include more or fewer operations, and these operations may be executed sequentially or in parallel.
[0146] Accordingly, embodiments of this application also provide a computer-readable storage medium storing computer instructions, which, when executed by one or more processors, cause one or more processors to perform the steps in the video playback method described above.
[0147] Figure 4 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Figure 4 As shown, it includes: a memory 40a, a processor 40b, and a communication component 40c. The memory 40a is used to store computer programs.
[0148] The processor 40b is coupled to the memory 40a and is used to execute a computer program for performing the following: acquiring a first video stream provided by a first video source node via a communication component 40c; buffering video frames of the second video stream already provided to the terminal device during the process of providing a second video stream generated based on the first video stream to the terminal device via the communication component 40c; acquiring a first target video frame from the buffered video frames when the video frames provided by the first video source node cannot be acquired; and providing the first target video frame to the terminal device for playback via the communication component 40c.
[0149] In some embodiments, the processor 40b is further configured to: time the interval between receiving two adjacent video frames each time a video frame provided by the first video source node is received through the communication component 40c; if the next video frame provided by the first video source node has not been received within an interval time greater than or equal to a set first duration, then determine that the video frame provided by the first video source node cannot be obtained.
[0150] In other embodiments, when the processor 40b obtains the first target video frame from the cached video frames, it is specifically used to: obtain the first target video frame from the cached video frames according to a set video frame selection strategy.
[0151] Furthermore, when the processor 40b obtains the first target video frame from the cached video frames, it is specifically configured to: obtain the priority of the set video frame selection strategy; determine the target video frame selection strategy from multiple video frame selection strategies according to the priority of the video frame selection strategy; obtain the first target video frame from the cached video frames according to the target video frame selection strategy; or, obtain the target video frame selection strategy selected by the user of the terminal device; and obtain the first target video frame from the cached video frames according to the target video frame selection strategy.
[0152] Furthermore, when the processor 40b retrieves the first target video frame from the cached video frames, it specifically performs the following steps: retrieves the N video frames closest to the current time from the cached second video stream's video frames, as the first target video frame; where N is a positive integer; or, retrieves the tag information of the cached second video stream's video frames; based on the tag information of the cached second video stream's video frames, retrieves video frames with the set tag information from the cached second video stream's video frames, as the first target video frame; or, retrieves the access count of the cached second video stream's video frames; based on the access count of the cached second video stream's video frames, retrieves the first target video frame from the cached second video stream's video frames; or, retrieves video frames containing the target object from the cached second video stream's video frames, as the first target video frame; or, the cached video frames include other video streams that have been played before the second video stream; and uses the video frames of other video streams as the first target video frame.
[0153] In other embodiments, when the processor 40b obtains the first target video frame from the video frames of the cached second video stream, it is specifically configured to: obtain the N video frames that are closest to the current time from the video frames of the cached second video stream as the first target video frame; where N is a positive integer.
[0154] In some other embodiments, there are multiple first video source nodes; the multiple first video source nodes capture the first scene from different perspectives. Accordingly, when the processor 40b acquires the first video stream provided by the first video source nodes, it is specifically used to: acquire the multi-view video streams provided by the multiple first video source nodes through the communication component 40c, as the first video stream.
[0155] Accordingly, the processor 40b is also used to: take the multi-view video frames provided by the multiple first video source nodes received each time through the communication component 40c as multiple layers; and render the multiple layers onto the background layer according to the set rendering template to obtain a video frame in the second video stream.
[0156] In other embodiments, the processor 40b is further configured to: switch the video source from a first video source node to a second video source node in response to a video source switching operation; if no video frame provided by the second video source node is received within a second time period set after the video source switching operation occurs, obtain a second target video frame from the video frames of the cached second video stream; and provide the second target video frame to the terminal device for playback via the communication component 40c. Correspondingly, if a video frame provided by the second video source node is received within the second time period set after the video source switching operation occurs, the currently received first video frame and the second target video frame are provided to the terminal device for playback via the communication component 40c.
[0157] Optionally, when the processor 40b provides the currently received first video frame and second target video frame to the terminal device for playback, it specifically performs the following: in response to an effect selection operation for the first video frame, it performs effect processing on the first video frame according to the effect setting information corresponding to the selected first effect to obtain an effect-processed first video frame; and in response to an effect selection operation for the second target video frame, it performs effect processing on the second target video frame according to the effect setting information corresponding to the selected second effect to obtain an effect-processed second target video frame; and provides the effect-processed first video frame and the effect-processed second target video frame to the terminal device for playback through the communication component 40c.
[0158] The first effect is associated with the entry into the screen; the second effect is associated with the exit from the screen.
[0159] Furthermore, when the processor 40b performs special effects processing on the first video frame, it specifically performs special effects processing on the multiple layers contained in the first video frame according to the special effects setting information corresponding to the first special effects, so as to obtain the first video frame after special effects processing.
[0160] Accordingly, when the processor 40b performs special effects processing on the second target video frame, it specifically performs special effects processing on the multiple layers contained in the second target video frame according to the special effects setting information corresponding to the second special effects, so as to obtain the second target video frame after special effects processing.
[0161] In some alternative implementations, such as Figure 4 As shown, the electronic device may also include components such as a power supply component 40d. In some embodiments, if the electronic device is a terminal device such as a computer, it may also include optional components such as a display screen 40e and an audio component 40f. Figure 4 The diagram only shows some components and does not mean that the electronic device must contain them. Figure 4 The inclusion of all components does not imply that an electronic device can only include... Figure 4 The components shown.
[0162] In this embodiment, the memory is used to store computer programs and can be configured to store various other data to support operation on its host device. The processor can execute the computer programs stored in the memory to implement corresponding control logic. The memory can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.
[0163] In the embodiments of this application, the processor can be any hardware processing device capable of executing the above-described method logic. Optionally, the processor can be a central processing unit (CPU), a graphics processing unit (GPU), or a microcontroller unit (MCU); it can also be a field-programmable gate array (FPGA), a programmable array logic (PAL), a general array logic (GAL), a complex programmable logic device (CPLD), or other programmable devices; or it can be an advanced reduced instruction set (RISC) processor (ARM) or a system on chip (SOC), etc., but is not limited thereto.
[0164] In this embodiment, the communication component is configured to facilitate wired or wireless communication between its host device and other devices. The device housing the communication component can access wireless networks based on communication standards, such as WiFi, 2G or 4G, 5G, or combinations thereof. In one exemplary embodiment, the communication component receives broadcast signals or broadcast-related information from an external broadcast management system via a broadcast channel. In another exemplary embodiment, the communication component may also be implemented based on Near Field Communication (NFC), Radio Frequency Identification (RFID), Infrared Data Association (IrDA), Ultra Wideband (UWB), Bluetooth (BT), or other technologies.
[0165] In embodiments of this application, the display screen may include a liquid crystal display (LCD) and a touch panel (TP). If the display screen includes a touch panel, the display screen can be implemented as a touchscreen to receive input signals from a user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensors can sense not only the boundaries of touch or swipe actions but also the duration and pressure associated with the touch or swipe operation.
[0166] In this embodiment, a power supply component is configured to provide power to various components of the device in which it resides. The power supply component may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to the device in which the power supply component resides.
[0167] In embodiments of this application, the audio component can be configured to output and / or input audio signals. For example, the audio component includes a microphone (MIC), which is configured to receive external audio signals when the device containing the audio component is in an operating mode, such as call mode, recording mode, and voice recognition mode. The received audio signals can be further stored in memory or transmitted via a communication component. In some embodiments, the audio component also includes a speaker for outputting audio signals. For example, in devices with voice interaction capabilities, voice interaction with the user can be achieved through the audio component.
[0168] The electronic device provided in this embodiment can act as a forwarding node. During the process of pushing a video stream to a terminal device, it caches the video frames already provided to the terminal device; and if it cannot obtain video frames from the video source node, it retrieves the target video frame from the cached video frames and provides the target video frame to the terminal device for playback. In this way, even if communication between the video source node and the forwarding node fails, the terminal device can continue playing video to the viewer, thereby reducing the probability of video interruption during playback and improving the user viewing experience.
[0169] It should be noted that the terms "first" and "second" in this article are used to distinguish different messages, devices, modules, etc., and do not represent a chronological order, nor do they limit "first" and "second" to different types.
[0170] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0171] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in one or more blocks of the flowchart illustrations and / or one or more blocks of the block diagrams.
[0172] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means that implement the functions specified in one or more flowcharts and / or one or more block diagrams.
[0173] These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process, such that the instructions, which execute on the computer or other programmable apparatus, provide steps for implementing the functions specified in one or more flowcharts and / or one or more block diagrams.
[0174] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0175] Memory may include non-persistent storage in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.
[0176] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0177] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0178] The above description is merely an embodiment of this application and is not intended to limit this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principle of this application should be included within the scope of the claims of this application.
Claims
1. A video playback system, characterized in that, include: The system comprises a first video source node, a second video source node, a forwarding node, and a terminal device; the second video source node is an image acquisition device. The forwarding node is a cloud broadcasting station provided by the cloud developer and deployed in the cloud developer's public cloud; the first video source node and the second video source node are communicatively connected to the forwarding node; broadcasting services and transition services are provided through the forwarding node, and the transition services include at least one of the following: scene switching, layout switching, and advertisement insertion; The first video source node is used to provide a first video stream to the forwarding node; the first video source node is an image acquisition device. The first video stream is a video stream acquired in real time by the image acquisition device; The forwarding node is configured to, during the process of providing the second video stream to the terminal device, cache video frames of the second video stream already provided to the terminal device, or cache video frames of other video streams that were forwarded to the terminal device before the second video stream; the second video stream is the first video stream or the processed first video stream; and, in the case where a communication failure occurs between the forwarding node and the first video source node, resulting in the inability to obtain video frames provided by the first video source node, the forwarding node retrieves the video frame closest to the current time from the cached video frames as the first target video frame; and provides the first target video frame to the terminal device for playback; wherein, each time the forwarding node receives a video frame provided by the first video source node, it times the interval between receiving two adjacent video frames; If the next video frame provided by the first video source node is not received when the interval time is greater than or equal to the set first duration, it is determined that the video frame provided by the first video source node cannot be obtained. The first duration is the user's visual persistence time. The forwarding node is further configured to: in response to a video source switching operation, switch the video source from the first video source node to the second video source node; if no video frame provided by the second video source node is received within a set second time period after the video source switching operation occurs, obtain a second target video frame from the video frames of the cached second video stream; and provide the second target video frame to the terminal device for playback.
2. The system according to claim 1, characterized in that, When the forwarding node retrieves the first target video frame from the cached video frames, it is specifically used for: According to the set video frame selection strategy, the first target video frame is obtained from the cached video frames.
3. The system according to claim 2, characterized in that, The video frame selection strategy can be multiple; when retrieving the first target video frame from the cached video frames according to the set video frame selection strategy, it is specifically used for: Obtain the priority of the set video frame selection strategy; determine the target video frame selection strategy from the multiple video frame selection strategies according to the priority of the video frame selection strategy; obtain the first target video frame from the cached video frames according to the target video frame selection strategy; or, Obtain the target video frame selection strategy selected by the user of the terminal device; and obtain the first target video frame from the cached video frames according to the target video frame selection strategy.
4. The system according to claim 3, characterized in that, The terminal device is configured to: display selection information items, the selection information items including: multiple video frame selection strategies, for the user to set the priority of the multiple video frame selection strategies; and, in response to a setting completion event, provide the priority of the multiple video frame selection strategies to the forwarding node. or, The terminal device is configured to: display selection information items, the selection information items including: multiple video frame selection strategies for the user to set a target video frame selection strategy; and, in response to a completion event for the selection of the multiple video frame selection strategies, provide the selected video frame selection strategy as an identifier of the target video frame selection strategy to the forwarding node.
5. The system according to claim 2, characterized in that, When the forwarding node retrieves the first target video frame from the cached video frames, it is specifically used for: Obtain the N video frames closest to the current time from the cached video frames of the second video stream, and use them as the first target video frame; where N is a positive integer; or, Obtain the tag information of video frames from the cached second video stream; based on the tag information of the video frames from the cached second video stream, obtain the video frames with the set tag information from the video frames of the cached second video stream, and use them as the first target video frames; or, Obtain the access count of video frames in the cached second video stream; based on the access count of video frames in the cached second video stream, obtain the first target video frame from the video frames in the cached second video stream; or, The video frame containing the target object is obtained from the video frames of the cached second video stream and used as the first target video frame; or, The cached video frames include: other video streams that have been played before the second video stream; the video frames of the other video streams are used as the first target video frame.
6. The system according to claim 1, characterized in that, The number of first video source nodes is multiple; multiple first video source nodes are used to capture the first scene from different perspectives to obtain multi-view video streams as the first video stream; and provide the first video stream in the form of video frames to the forwarding node according to the set video transmission rate; The forwarding node is further configured to: treat the multi-view video frames received each time from multiple first video source nodes as multiple layers; and render the multiple layers onto a background layer according to a set rendering template to obtain a video frame in the second video stream.
7. The system according to claim 1, characterized in that, The forwarding node is also used for: If a video frame provided by the second video source node is received within the second set time period after the video source switching operation occurs, the currently received first video frame and the second target video frame are provided to the terminal device for playback.
8. The system according to claim 7, characterized in that, When the forwarding node provides the currently received first video frame and the second target video frame to the terminal device for playback, it is specifically used for: In response to the effect selection operation for the first video frame, the first video frame is processed with effects according to the effect setting information corresponding to the selected first effect to obtain the first video frame after effect processing. In response to the effect selection operation for the second target video frame, the second target video frame is processed with effects according to the effect setting information corresponding to the selected second effect to obtain the second target video frame after effect processing. The first video frame after special effects processing and the second target video frame after special effects processing are provided to the terminal device for playback.
9. The system according to claim 8, characterized in that, When the forwarding node performs special effects processing on the first video frame, it is specifically used for: Based on the effect setting information corresponding to the first effect, the multiple layers contained in the first video frame are processed with effects respectively to obtain the first video frame after the effects are processed. When the forwarding node performs special effects processing on the second target video frame, it is specifically used for: Based on the effect setting information corresponding to the second effect, the multiple layers contained in the second target video frame are processed with effects respectively to obtain the second target video frame after the effects are processed.
10. The system according to claim 8, characterized in that, The first effect is an effect associated with entering the screen; the second effect is an effect associated with exiting the screen.
11. The system according to claim 8, characterized in that, The forwarding node maintains effect setting information corresponding to various special effects; the various special effects include the first special effect and the second special effect; The special effects settings information corresponding to the various special effects are embedded in the forwarding node in the form of a plugin.
12. The system according to any one of claims 1-11, characterized in that, The forwarding node is a cloud broadcasting station.
13. A video playback method, characterized in that, Applied to forwarding nodes, the method includes: Acquire a first video stream provided by a first video source node; the first video source node is an image acquisition device; the first video stream is a video stream acquired in real time by the image acquisition device. In the process of providing a second video stream generated based on the first video stream to a terminal device, video frames of the second video stream that have been provided to the terminal device are cached, or video frames of other video streams that have been forwarded to the terminal device before the second video stream are cached; the second video stream is the first video stream or the processed first video stream; If a communication failure occurs between the forwarding node and the first video source node, resulting in the inability to obtain the video frame provided by the first video source node, then the video frame closest to the current time is obtained from the cached video frames as the first target video frame. The first target video frame is provided to the terminal device for playback; wherein, each time a video frame provided by the first video source node is received, the interval between receiving two adjacent video frames is timed; if the next video frame provided by the first video source node is not received before the interval is greater than or equal to a set first duration, it is determined that the video frame provided by the first video source node cannot be obtained, and the first duration is the user's visual persistence time. In response to a video source switching operation, the video source is switched from the first video source node to the second video source node. If no video frame is received from the second video source node within a set second time period after the video source switching operation occurs, a second target video frame is obtained from the video frames of the cached second video stream. The second target video frame is then provided to the terminal device for playback. The second video source node is an image acquisition device. The forwarding node is a cloud broadcasting station deployed in the public cloud of the cloud developer. The first video source node, the second video source node, and the forwarding node are communicatively connected. The forwarding node provides broadcasting services and transition services, the transition services including at least one of the following: scene switching, layout switching, and advertisement insertion.
14. The method according to claim 13, characterized in that, The step of obtaining the first target video frame from the cached video frames of the second video stream includes: According to the set video frame selection strategy, the first target video frame is obtained from the cached video frames.
15. The method according to claim 14, characterized in that, The video frame selection strategy can be multiple; when retrieving the first target video frame from the cached video frames according to the set video frame selection strategy, it is specifically used for: The priority of the video frame selection strategy set by the user of the terminal device is obtained; according to the priority of the video frame selection strategy, a target video frame selection strategy is determined from the multiple video frame selection strategies; according to the target video frame selection strategy, a first target video frame is obtained from the cached video frames. or, Obtain the target video frame selection strategy selected by the user of the terminal device; and obtain the first target video frame from the cached video frames according to the target video frame selection strategy.
16. The method according to claim 14, characterized in that, When retrieving the first target video frame from the cached video frames according to the set video frame selection strategy, the specific steps are as follows: Obtain the N video frames closest to the current time from the cached video frames of the second video stream, and use them as the first target video frame; where N is a positive integer; or, Obtain the tag information of the video frames of the cached second video stream; based on the tag information of the video frames of the cached second video stream, obtain the video frames with the set tag information from the video frames of the cached second video stream, and use them as the first target video frames; or, Obtain the access count of video frames in the cached second video stream; based on the access count of video frames in the cached second video stream, obtain the first target video frame from the video frames in the cached second video stream; or, From the video frames of the cached second video stream, obtain the video frame containing the target object, and use it as the first target video frame; or, The cached video frames include: other video streams that have been played before the second video stream; the other video streams are used as the first target video frames.
17. The method according to claim 13, characterized in that, The step of obtaining the first target video frame from the cached video frames of the second video stream includes: Obtain the N video frames that are closest to the current time from the video frames of the cached second video stream, and use them as the first target video frame; where N is a positive integer.
18. The method according to claim 13, characterized in that, The number of first video source nodes is multiple; multiple first video source nodes capture the first scene from different perspectives; The step of obtaining the first video stream provided by the first video source node includes: The multi-view video streams provided by the plurality of first video source nodes are obtained as the first video stream.
19. The method according to claim 18, characterized in that, Also includes: Each time, multiple first video source nodes provide multiple viewpoint video frames as multiple layers; According to the set rendering template, the multiple layers are rendered onto the background layer to obtain a video frame in the second video stream.
20. The method according to claim 13, characterized in that, Also includes: If a video frame provided by the second video source node is received within the second set time period after the video source switching operation occurs, the currently received first video frame and the second target video frame are provided to the terminal device for playback.
21. The method according to claim 20, characterized in that, The step of providing the currently received first video frame and the second target video frame to the terminal device for playback includes: In response to the effect selection operation for the first video frame, the first video frame is processed with effects according to the effect setting information corresponding to the selected first effect to obtain the first video frame after effect processing. In response to the effect selection operation for the second target video frame, the second target video frame is processed with effects according to the effect setting information corresponding to the selected second effect to obtain the second target video frame after effect processing. The first video frame after special effects processing and the second target video frame after special effects processing are provided to the terminal device for playback.
22. The method according to claim 21, characterized in that, The step of performing special effects processing on the first video frame according to the special effects setting information corresponding to the selected first special effects includes: Based on the effect setting information corresponding to the first effect, the multiple layers contained in the first video frame are processed with effects respectively to obtain the first video frame after the effects are processed. The step of performing special effects processing on the second target video frame according to the special effects setting information corresponding to the selected second special effects includes: Based on the effect setting information corresponding to the second effect, the multiple layers contained in the second target video frame are processed with effects respectively to obtain the second target video frame after the effects are processed.
23. The method according to claim 21, characterized in that, The first effect is an effect associated with entering the screen; the second effect is an effect associated with exiting the screen.
24. An electronic device, characterized in that, include: Memory, processor, and communication components; wherein the memory is used to store computer programs; The processor is coupled to the memory for executing the computer program to perform the steps of the method according to any one of claims 13-23.
25. A computer-readable storage medium storing computer instructions, characterized in that, When the computer instructions are executed by one or more processors, the one or more processors are caused to perform the steps of the method according to any one of claims 13-23.