Multi-stream redundant video transmission system based on p2p mesh

By introducing redundant encoding and bypass transmission technology into the video transmission system, the video transmission interruption problem caused by dynamic changes in upstream audiences is solved, improving the viewing experience of downstream users and reducing latency.

CN118381960BActive Publication Date: 2025-05-09BEIJING UNIV OF POSTS & TELECOMM
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410423454.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-04-09
Publication Date
2025-05-09
Estimated Expiration
2044-04-09

AI Technical Summary

Technical Problem

In traditional peer-to-peer networks, due to the high dynamicity of video viewers, the joining or leaving behavior of upstream viewers often interrupt the transmission of live streaming media, resulting in poor experience of downstream viewers watching live videos.

Method used

A video transmission system based on p2p mesh multi-stream redundancy is adopted. Video packets are received through the video forwarding terminal and copied in the encoding buffer area, redundant packets are generated, and forwarded to the content distribution terminal and downstream terminal, ensuring that even if the upstream user leaves, downstream users can still decode and continue playing videos through the redundant mechanism.

Benefits of technology

It effectively solves the problem of video transmission interruption caused by dynamic changes in upstream audiences, improves the viewing experience of downstream users, and reduces the delay in video transmission through bypass transmission.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118381960B_ABST
    Figure CN118381960B_ABST
Patent Text Reader

Abstract

The present invention provides a redundant video transmission system based on a p2p mesh multi-stream, comprising: a video forwarding terminal receives a video data packet and copies it into a coding buffer area, and then forwards it to a content distribution terminal; when the number of copies is equal to the number of preset video data packets, a redundant data packet is generated, and the redundant data packet is forwarded to the content distribution terminal; the coding buffer area is initialized; in response to the received video data packet, a step of copying the video data packet into the coding buffer area is executed; when the video data packet or the redundant data packet is received by the content distribution terminal, the video data packet or the redundant data packet is distributed to at least one upstream terminal; when the video data packet or the redundant data packet is received by the upstream terminal, the video data packet or the redundant data packet is forwarded to at least one downstream terminal; the problem that the joining or leaving behavior of the upstream audience interrupts the transmission of the real-time streaming media, resulting in a poor viewing experience of the downstream audience for the live video, can be solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer technology, and in particular to a p2p mesh multi-stream redundant video transmission system. Background Art

[0002] With the development of Internet technology, live video streaming has gradually become a part of people's daily lives. Video transmission is occupying more and more Internet resources such as bandwidth, and people's requirements for video transmission quality are also increasing. Although video forwarding servers are ubiquitous, video viewers still suffer from low-quality experience during peak hours because existing content delivery networks are not sufficient to handle large-scale concurrent streaming media. The rapid rise of Web 3.0 in recent years has provided new impetus for reconsidering and applying classic peer-to-peer networks.

[0003] However, in traditional point-to-point networks, since video viewers are highly dynamic, the joining or leaving of upstream viewers often interrupts the transmission of real-time streaming media, resulting in a poor viewing experience for downstream viewers. Summary of the invention

[0004] In view of this, the embodiment of the present invention provides a p2p mesh multi-stream redundant video transmission system to eliminate or improve one or more defects in the prior art. It can solve the problem that the joining or leaving behavior of upstream viewers often interrupts the transmission of real-time streaming media, resulting in a poor viewing experience of downstream viewers for live video.

[0005] One aspect of the present invention provides a p2p mesh multi-stream redundant video transmission system, comprising:

[0006] A video forwarding terminal, used to: in response to a received video data packet, copy the video data packet to a coding buffer area, and forward the video data packet to a content distribution terminal; determine the number of copies corresponding to the copied video data packet in the coding buffer area; when the number of copies is equal to the preset number of video data packets, based on a preset coding method, a preset number of redundant data packets and the copied video data packets in the coding buffer area, encode and generate redundant data packets corresponding to the preset number of redundant data packets, and forward the redundant data packets to the content distribution terminal; the preset number of video data packets is used to indicate the number of video data packets in a data packet coding group, and the preset number of redundant data packets is used to indicate the number of redundant data packets in a data packet coding group; initialize the coding buffer area; execute the step of copying the video data packet to the coding buffer area in response to the received video data packet;

[0007] The content distribution terminal is used to: when receiving a video data packet or a redundant data packet, distribute the video data packet or the redundant data packet to at least one upstream terminal; each upstream terminal is respectively connected to the content distribution terminal;

[0008] The upstream terminal is used to: when receiving the video data packet or the redundant data packet, forward the video data packet or the redundant data packet to at least one downstream terminal.

[0009] Optionally, the video forwarding terminal is further used to: when the number of copies is less than the preset number of video data packets, execute the steps of copying the video data packets into the encoding buffer area in response to the received video data packets, and forwarding the video data packets to the content distribution terminal.

[0010] Optionally, before forwarding the video data packet to the content distribution terminal, the video forwarding terminal is further used to: determine a data packet sequence number corresponding to the video data packet according to a forwarding sequence corresponding to the video data packet, and add the sequence number to a packet header of the video data packet;

[0011] Before forwarding the redundant data packet to the content distribution terminal, the video forwarding terminal is further used to: determine the data packet sequence number corresponding to the redundant data packet according to the forwarding sequence corresponding to the redundant data packet, and add it to the packet header of the redundant data packet.

[0012] Before forwarding the video data packet to the first downstream terminal through the forwarding sub-stream and forwarding the redundant data packet to the second downstream terminal, the upstream terminal is also used to: obtain a target modulus value; perform a modulus operation on the data packet sequence number corresponding to the video data packet or the data packet sequence number corresponding to the redundant data packet through the target modulus value to obtain a modulus result; based on the modulus result, determine the video data packet or redundant data packet sent by each forwarding sub-stream.

[0013] Optionally, the upstream terminal is further configured to: upon receiving a video data packet or a redundant data packet, determine a data packet sequence number corresponding to the video data packet or a data packet sequence number corresponding to the redundant data packet according to a receiving order, and add the sequence number to a packet header;

[0014] Before forwarding the video data packet to the first downstream terminal through the forwarding sub-stream and forwarding the redundant data packet to the second downstream terminal, the upstream terminal is also used to: obtain a target modulus value; perform a modulus operation on the data packet sequence number corresponding to the video data packet or the data packet sequence number corresponding to the redundant data packet through the target modulus value to obtain a modulus result; based on the modulus result, determine a forwarding sub-stream for forwarding the video data packet and a forwarding sub-stream for forwarding the redundant data packet.

[0015] Optionally, the video forwarding terminal is further used to: add a coding group identifier and a data packet identifier to the video data packet and the redundant data packet respectively; the coding group identifier is used to indicate the data packet coding group to which the video data packet and the redundant data packet belong, and the data packet identifier is used to indicate the data packet type corresponding to the video data packet and the redundant data packet;

[0016] The downstream terminal is used to: determine whether all video data packets in the current data packet coding group are received based on the preset number of video data packets, the coding group identifier and the data packet identifier; in the event that video data packets in the current data packet coding group are lost, restore all video data packets in the current data packet coding group based on the decoding of redundant data packets in the current data packet coding group and the received video data packets.

[0017] Optionally, the upstream terminal is further configured to: upon receiving a video data packet or a redundant data packet, determine the video data packet or the redundant data packet sent by each forwarding sub-flow based on the data packet identifier.

[0018] Optionally, the number of sub-streams corresponding to the forwarding sub-stream is the sum of the number of preset redundant data packets and the number of video data packets.

[0019] Optionally, the video forwarding terminal is further used to: determine a target module value based on a preset number of video data packets and a preset number of redundant data packets; and send the target module value to the content distribution terminal;

[0020] The content distribution terminal is further configured to: upon receiving the target module value, send the target module value to at least one upstream terminal.

[0021] Optionally, in response to the received video data packet, the video data packet is copied into the encoding buffer area, and before the video data packet is forwarded to the content distribution terminal, the video forwarding terminal is also used to: obtain the packet loss test result between the upstream terminal and the downstream terminal; based on the packet loss test result, determine the value of the preset redundant data packet number and the value of the preset video data packet number.

[0022] Optionally, the preset encoding method includes a Reed-Solomon encoding method or an XOR encoding method.

[0023] The p2p mesh multi-stream redundant video transmission system of the present invention receives a video data packet through a video forwarding terminal, copies it to a coding buffer area, and forwards it to a content distribution terminal; when the number of copies is equal to the number of preset video data packets, encodes to generate redundant data packets, and forwards the redundant data packets to the content distribution terminal; initializes the coding buffer area; executes the step of copying the video data packet to the coding buffer area in response to the received video data packet; when the content distribution terminal receives the video data packet or the redundant data packet, the video data packet or the redundant data packet is distributed to at least one upstream terminal; when the upstream terminal receives the video data packet or the redundant data packet, the video data packet or the redundant data packet is forwarded to at least one downstream terminal; the problem that the joining or leaving behavior of the upstream audience often interrupts the transmission of the real-time streaming media, resulting in a poor viewing experience of the downstream audience for the live video, is solved; a lightweight redundant coding function is introduced in the video forwarding terminal, when the upstream user leaves, although the data transmission from the upstream user to the downstream user is interrupted, the downstream user can decode and generate the video data packet required for video playback through the redundant mechanism, so that the downstream user can continue to play, thereby avoiding the viewing interruption of the downstream user and improving the viewing experience of the downstream user. At the same time, through the bypass transmission method, the video forwarding terminal will not be blocked due to redundant coding during the process of forwarding video data packets, thereby reducing the forwarding delay.

[0024] Additional advantages, purposes, and features of the present invention will be described in part in the following description, and will become apparent to those skilled in the art after studying the following, or may be learned from the practice of the present invention. The purposes and other advantages of the present invention may be achieved and obtained by the structures specifically indicated in the specification and the accompanying drawings.

[0025] Those skilled in the art will appreciate that the objectives and advantages that can be achieved with the present invention are not limited to the above specific description, and the above and other objectives that can be achieved by the present invention will be more clearly understood from the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS

[0026] The drawings described herein are used to provide a further understanding of the present invention, constitute a part of this application, and do not constitute a limitation of the present invention. The components in the drawings are not drawn to scale, but are only for illustrating the principles of the present invention. In order to facilitate the illustration and description of some parts of the present invention, the corresponding parts in the drawings may be enlarged, that is, they may become larger relative to other components in the exemplary device actually manufactured according to the present invention. In the drawings:

[0027] Figure 1 A p2p mesh multi-stream redundant video transmission system provided by an embodiment of the present invention;

[0028] Figure 2 A schematic diagram of redundant coding provided in one embodiment of the present invention;

[0029] Figure 3 A schematic diagram of a sequential transmission mode provided by an embodiment of the present invention;

[0030] Figure 4 A schematic diagram of a bypass transmission mode provided in accordance with an embodiment of the present invention. DETAILED DESCRIPTION

[0031] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the embodiments and the accompanying drawings. Here, the illustrative embodiments of the present invention and their descriptions are used to explain the present invention, but are not intended to limit the present invention.

[0032] It should also be noted that, in order to avoid obscuring the present invention due to unnecessary details, only structures and / or processing steps closely related to the solutions according to the present invention are shown in the accompanying drawings, while other details that are not closely related to the present invention are omitted.

[0033] It should be emphasized that the term “include / comprises” when used herein refers to the presence of features, elements, steps or components, but does not exclude the presence or addition of one or more other features, elements, steps or components.

[0034] It should also be noted that, unless otherwise specified, the term “connection” herein may refer not only to a direct connection but also to an indirect connection involving an intermediate.

[0035] Hereinafter, embodiments of the present invention will be described with reference to the accompanying drawings. In the accompanying drawings, the same reference numerals represent the same or similar components, or the same or similar steps.

[0036] Figure 1 FIG. 1 is a schematic diagram of a structure of a p2p mesh multi-stream redundant video transmission system provided by an embodiment of the present application. Figure 1 As shown, the system at least includes: a video forwarding terminal 110, a content distribution terminal 120, an upstream terminal 130 and a downstream terminal 140.

[0037] In this embodiment, the number of the video forwarding terminal 110, the content distribution terminal 120, the upstream terminal 130, and the downstream terminal 140 is 1 respectively for description. In actual implementation, the number of the video forwarding terminal 110, the content distribution terminal 120, the upstream terminal 130, and the downstream terminal 140 is one or at least two, and this embodiment does not limit the number of the video forwarding terminal 110, the content distribution terminal 120, the upstream terminal 130, and the downstream terminal 140.

[0038] The video forwarding terminal 110 refers to a device that can receive video data packets sent by a video source and can forward the received video data packets to the content distribution terminal 120. For example, a streaming media server. A communication connection is established between the video forwarding terminal 110 and the video source, which includes but is not limited to a camera, a video acquisition device, a mobile phone or an encoder.

[0039] In a mesh (Peer-to-Peer, p2p) network, in order to improve the audience's viewing experience and reduce the transmission path and network congestion when the audience watches videos or live broadcasts, the video data packet sent by the video source is received by the video forwarding terminal 110 and forwarded to the content distribution terminal 120. After that, the video data packet is sent to the user nearby by relying on the content distribution terminals 120 distributed in various places.

[0040] Traditional file transfer methods based on peer-to-peer networks are mostly based on the Transmission Control Protocol (TCP). Nodes that need to obtain specific video content will search and discover resources through the mesh network to find other nodes that have the target video content; then, the node will establish a TCP connection with the neighboring nodes and exchange data through the TCP protocol.

[0041] However, the traditional file transmission method based on peer-to-peer network is only applied to pre-generated, non-real-time file or video downloads, and its user dynamics can be ignored. In the real-time video transmission scenario, users are extremely dynamic. The sudden departure of the upstream audience will cause the downstream audience to suddenly stop playing. It takes a certain amount of time to find a new upstream to re-establish transmission. During this period, the downstream audience cannot play the video normally, which gives the user a very poor viewing experience.

[0042] Based on the above technical problems, in this embodiment, users are divided into two parts: upstream users and downstream users, wherein the video data packets of the upstream users come from the content distribution terminal 120, and the video data packets of the downstream users come from the forwarding of the upstream users. In order to solve the problem that the dynamic departure of the upstream user causes the interruption of the downstream user's playback, this embodiment introduces a lightweight redundant coding function in the video forwarding terminal 110. When the upstream user leaves, although the data transmission from the upstream user to the downstream user is interrupted, the downstream user can decode the video data packets required for video playback through the redundant mechanism, so that the downstream user can continue to play, thereby avoiding the interruption of the downstream user's viewing and improving the viewing experience of the downstream user.

[0043] Specifically, the video forwarding terminal 110 is used to: in response to a received video data packet, copy the video data packet to a coding buffer area, and forward the video data packet to a content distribution terminal; determine the number of copies corresponding to the copied video data packet in the coding buffer area; when the number of copies is equal to the preset number of video data packets, based on a preset encoding method, a preset number of redundant data packets and the copied video data packets in the coding buffer area, encode and generate redundant data packets corresponding to the preset number of redundant data packets, and forward the redundant data packets to the content distribution terminal; the preset number of video data packets is used to indicate the number of video data packets in a data packet coding group, and the preset number of redundant data packets is used to indicate the number of redundant data packets in a data packet coding group; initialize the coding buffer area; and execute the step of copying the video data packet to the coding buffer area in response to the received video data packet.

[0044] In this embodiment, after receiving the data packet sent by the video source, the video forwarding terminal 110 copies the video data packet to a preset encoding buffer area. When the number of copied video data packets in the encoding buffer area reaches the preset number of video data packets, redundant data packets of a preset number of redundant data packets are generated according to the preset encoding method and the copied video data packets in the encoding buffer area.

[0045] The coding buffer refers to a memory area used to temporarily store data during data transmission or processing. In this embodiment, the coding buffer is used to temporarily store a copy of a video data packet corresponding to a video data packet. The preset coding method refers to a pre-selected coding method, including a Reed-Solomon code method or an Exclusive OR (XOR) coding method.

[0046] The preset number of video data packets refers to the number of video data packets in a preset encoding group; the preset number of redundant data packets refers to the number of redundant data packets in an encoding group, wherein an encoding group refers to a set of related video data packets and redundant data packets.

[0047] For example: Reference Figure 2Taking the preset number of video data packets as 2 and the preset number of redundant data packets as 1 as an example, video data packet pkt-1 and video data packet pkt-2 are XOR encoded to obtain redundant data packet rdt-1; video data packet pkt-3 and video data packet pkt-4 are XOR encoded to obtain redundant data packet rdt-2; video data packet pkt-5 and video data packet pkt-6 are XOR encoded to obtain redundant data packet rdt-3; encoding group 1 includes video data packet pkt-1, video data packet pkt-2 and redundant data packet rdt-1; encoding group 2 includes video data packet pkt-3, video data packet pkt-4 and redundant data packet rdt-2; encoding group 1 includes video data packet pkt-5, video data packet pkt-6 and redundant data packet rdt-3.

[0048] When the number of copied video data packets in the encoding buffer is less than the preset number of video data packets, the video forwarding terminal 110 continues to copy and forward the video data packets after receiving the video data packets sent by the video source. Specifically, the video forwarding terminal 110 is also used to: when the number of copies is less than the preset number of video data packets, execute the steps of copying the video data packets to the encoding buffer in response to the received video data packets, and forwarding the video data packets to the content distribution terminal 120.

[0049] In addition, before the video forwarding terminal 110 receives and forwards the video data packets sent by the video source, the video forwarding terminal 110 is also used to obtain a preset number of video data packets and a preset number of redundant data packets, so that the video forwarding terminal 110 can generate redundant data packets based on the preset number of video data packets and the preset number of redundant data packets.

[0050] In one example, the video forwarding terminal 110 receives the preset number of video data packets and the preset number of redundant data packets input by the user. Specifically, the user can input the preset number of video data packets and the preset number of redundant data packets through an input device such as a mouse and keyboard connected to the video forwarding terminal 110, or the user can input the preset number of video data packets and the preset number of redundant data packets through an operation acting on a touch display screen.

[0051] In another example, the video forwarding terminal 110 obtains the packet loss test results between the upstream terminal and the downstream terminal, and based on the packet loss test results and the preset relationship between the packet loss test results and the number of redundant data packets and the number of video data packets, determines the value of the preset number of redundant data packets and the value of the preset number of video data packets through query.

[0052] Specifically, in response to the received video data packet, the video data packet is copied into the encoding buffer area, and before the video data packet is forwarded to the content distribution terminal, the video forwarding terminal 110 is also used to: obtain the packet loss test result between the upstream terminal 130 and the downstream terminal 140; based on the packet loss test result, determine the value of the preset redundant data packet number and the value of the preset video data packet number.

[0053] In addition, in the traditional video data packet forwarding process, a sequential transmission mode is usually adopted, that is, after waiting for all video data packets in the same data packet coding group to arrive, a redundant packet is generated, and then the video data packet is forwarded together with the redundant data packet.

[0054] For example: Reference Figure 3 , video data packet pkt-1 and video data packet pkt-2 arrive at time T0 and T1 respectively. Redundant encoding is performed after the arrival of video data packet pkt-2 to generate redundant data packet rdt-1, and then all data packets in the data packet coding group are transmitted in sequence at T2, T3, and T4.

[0055] However, the sequential transmission method will cause each data packet to be blocked, which violates the low-latency requirement of video transmission and has the problem of high video transmission delay.

[0056] Based on this, in order to solve this technical problem, this embodiment provides a bypass transmission mode. Figure 4 , video data packets pkt-1 and pkt-2 arrive at T0 and T1 respectively and are forwarded immediately; at the same time, they will be copied to the encoding buffer to generate redundant data packet rdt-1 in a bypass manner, and the redundant data packet rdt-1 will be forwarded at T2. Through this bypass transmission method, the video data packet will not be blocked due to redundant encoding, thereby reducing the forwarding delay.

[0057] In this embodiment, the content distribution terminal 120 is used to distribute the video data packet or the redundant data packet to at least one upstream terminal 130 when receiving the video data packet or the redundant data packet.

[0058] In this embodiment, each upstream terminal 130 establishes a communication connection with the content distribution terminal 120. The upstream terminal 130 is configured to forward the video data packet or the redundant data packet to at least one downstream terminal 140 upon receiving the video data packet or the redundant data packet.

[0059] The number of substreams corresponding to the forwarding substream is the sum of the number of preset redundant data packets and the number of video data packets. Alternatively, in actual implementation, the number of substreams corresponding to the forwarding substream can also be adjusted according to the actual mesh situation. This embodiment does not limit the number of substreams corresponding to the forwarding substream.

[0060] In this embodiment, the upstream terminal 130 sends the received video data packet or redundant data packet to at least one downstream terminal 140 through a preset forwarding sub-flow. At least one of the following methods is included:

[0061] First, before forwarding the video data packet or the redundant data packet, the video forwarding terminal 110 determines the data packet sequence number of each data packet according to the forwarding order and adds it to the packet header, and the upstream terminal 130 performs a modulo operation on the data packet sequence number of the redundant data packet or the video data packet, and determines the forwarding sub-stream for forwarding the redundant data packet or the video data packet based on the result of the modulo operation.

[0062] Specifically, before forwarding the video data packet to the first downstream terminal through the forwarding sub-stream and forwarding the redundant data packet to the second downstream terminal 140, the upstream terminal 130 is also used to: obtain a target modulus value; perform a modulus operation on the data packet sequence number corresponding to the video data packet or the data packet sequence number corresponding to the redundant data packet through the target modulus value to obtain a modulus result; based on the modulus result, determine a forwarding sub-stream for forwarding the video data packet and a forwarding sub-stream for forwarding the redundant data packet.

[0063] Among them, the target modulus value can be expressed by the following formula:

[0064] M=R+S

[0065] Wherein, M represents the target modulus value; R represents the preset number of redundant data packets; and S represents the preset number of video data packets.

[0066] Accordingly, in this embodiment, the proportion of redundant data packets in the total data packets, that is, the redundancy corresponding to the redundant data packets can be expressed by the following formula:

[0067] D=R / (R+S)

[0068] Wherein, D represents redundancy; R represents the number of preset redundant data packets; S represents the number of preset video data packets.

[0069] In this embodiment, the video forwarding terminal 110 is also used to: determine the target module value based on a preset number of video data packets and a preset number of redundant data packets; send the target module value to the content distribution terminal 120; the content distribution terminal 120 is also used to: upon receiving the target module value, send the target module value to at least one upstream terminal 130.

[0070] Accordingly, before forwarding the video data packet or the redundant data packet, the video forwarding terminal 110 adds a data packet sequence number to the packet header of the video data packet or the packet header of the redundant data packet.

[0071] Specifically, before forwarding the video data packet to the content distribution terminal, the video forwarding terminal 110 is further used to: determine the data packet sequence number corresponding to the video data packet according to the forwarding sequence corresponding to the video data packet, and add the sequence number to the packet header of the video data packet.

[0072] Before forwarding the redundant data packet to the content distribution terminal, the video forwarding terminal 110 is further used to: determine the data packet sequence number corresponding to the redundant data packet according to the forwarding sequence corresponding to the redundant data packet, and add the sequence number to the header of the redundant data packet.

[0073] For example, taking the target modulus value as 3 and the redundancy as 1 / 3 as an example, the number of redundant data packets is preset to be 1, and the number of video data packets is preset to be 2; the data packet numbers of the four video data packets are 0, 1, 2, and 3, respectively. A redundant data packet is obtained by encoding video data packet 0 and video data packet 1, and a redundant data packet is obtained by encoding video data packet 2 and video data packet 3. Then, after the video data packets and redundant data packets are smoothly sorted according to forwarding, video data packet 0, video data packet 1, redundant data packet 2, video data packet 3, video data packet 4, and redundant data packet 5 are obtained; the upstream terminal 130 takes the modulus of the packet numbers of these data packets, and the packets with the same modulus are sent to the downstream terminal 140 through the same substream, that is, video data packet 0 and video data packet 3 are sent through substream No. 0, video data packet 1 and video data packet 4 are sent through substream No. 1, and redundant data packet 3 and redundant data packet 5 are sent through substream No. 2.

[0074] The second method is that after receiving the video data packet or the redundant data packet, the upstream terminal 130 determines the data packet sequence number of each data packet according to the order in which the data packets are received, and then determines the video data packet or redundant data packet sent by each forwarding sub-stream based on the result of the modulo operation by performing a modulo operation on the data packet sequence number of the redundant data packet or the video data packet.

[0075] The upstream terminal 130 is further configured to: upon receiving a video data packet or a redundant data packet, determine a data packet sequence number corresponding to the video data packet or a data packet sequence number corresponding to the redundant data packet according to a receiving order, and add the sequence number to the packet header.

[0076] Before forwarding the video data packet to the first downstream terminal and forwarding the redundant data packet to the second downstream terminal through the forwarding sub-stream, the upstream terminal 130 is also used to: obtain a target modulus value; perform a modulus operation on the data packet sequence number corresponding to the video data packet or the data packet sequence number corresponding to the redundant data packet according to the target modulus value to obtain a modulus result; and determine, based on the modulus result, that each forwarding sub-stream sends a video data packet or a redundant data packet.

[0077] The third method is that the upstream terminal 130 determines the video data packet or redundant data packet sent by each forwarding sub-flow through the data packet identifier of the video data packet or the data packet identifier of the redundant data packet. Specifically, the upstream terminal 130 is further configured to: determine the video data packet or redundant data packet sent by each forwarding sub-flow based on the data packet identifier when receiving the video data packet or redundant data packet.

[0078] In this embodiment, the video forwarding terminal 110 is further used to add a coding group identifier and a data packet identifier to the video data packet and the redundant data packet, respectively. The coding group identifier is used to indicate the data packet coding group to which the video data packet and the redundant data packet belong, and the data packet identifier is used to indicate the data packet type corresponding to the video data packet and the redundant data packet.

[0079] The downstream terminal 140 is used to: determine whether all video data packets in the current data packet coding group are received based on the preset number of video data packets, the coding group identifier and the data packet identifier; in the event that there is packet loss in the video data packets in the current data packet coding group, restore all video data packets in the current data packet coding group based on the decoding of redundant data packets in the current data packet coding group and the received video data packets.

[0080] In summary, the p2p mesh multi-stream redundant video transmission system provided in this embodiment receives a video data packet through a video forwarding terminal, copies it to a coding buffer area, and forwards it to a content distribution terminal; when the number of copies is equal to the preset number of video data packets, encodes to generate redundant data packets, and forwards the redundant data packets to the content distribution terminal; initializes the coding buffer area; executes the step of copying the video data packet to the coding buffer area in response to the received video data packet; when the content distribution terminal receives a video data packet or a redundant data packet, the video data packet or the redundant data packet is distributed to at least one upstream terminal; when the upstream terminal receives a video data packet or a redundant data packet, the video data packet or the redundant data packet is forwarded to at least one downstream terminal; it can solve the problem that the joining or leaving behavior of the upstream audience often interrupts the transmission of the real-time streaming media, resulting in a poor viewing experience of the downstream audience for the live video; a lightweight redundant coding function is introduced in the video forwarding terminal, when the upstream user leaves, although the data transmission from the upstream user to the downstream user is interrupted, the downstream user can decode the video data packet required for video playback through the redundant mechanism, so that the downstream user can continue to play, thereby avoiding the interruption of the downstream user's viewing and improving the viewing experience of the downstream user. At the same time, through the bypass transmission method, the video forwarding terminal will not be blocked due to redundant coding during the process of forwarding video data packets, thereby reducing the forwarding delay.

[0081] It should be understood by those skilled in the art that the exemplary components, systems and methods described in conjunction with the embodiments disclosed herein can be implemented in hardware, software or a combination of the two. Whether it is performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention. When implemented in hardware, it can be, for example, an electronic circuit, an application specific integrated circuit (ASIC), appropriate firmware, a plug-in, a function card, etc. When implemented in software, the elements of the present invention are programs or code segments used to perform the required tasks. The program or code segment can be stored in a machine-readable medium, or transmitted on a transmission medium or a communication link via a data signal carried in a carrier.

[0082] It should be clear that the present invention is not limited to the specific configuration and processing described above and shown in the figures. For the sake of simplicity, a detailed description of the known method is omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of the present invention is not limited to the specific steps described and shown, and those skilled in the art can make various changes, modifications and additions, or change the order between the steps after understanding the spirit of the present invention.

[0083] In the present invention, features described and / or illustrated for one embodiment may be used in the same or similar manner in one or more other embodiments, and / or combined with features of other embodiments or replace features of other embodiments.

[0084] The above are only preferred embodiments of the present invention and are not intended to limit the present invention. For those skilled in the art, the embodiments of the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.

Claims

1. A p2p mesh multi-stream redundant video transmission system, characterized in that: The video transmission system comprises: A video forwarding terminal, used for: in response to a received video data packet, copying the video data packet into a coding buffer area, and forwarding the video data packet to a content distribution terminal, the coding buffer area being used to temporarily store a copied video data packet corresponding to the video data packet; determining the number of copies corresponding to the copied video data packet in the coding buffer area; when the number of copies is equal to the number of preset video data packets, based on a preset coding method, a preset number of redundant data packets and the copied video data packets in the coding buffer area, encoding and generating redundant data packets corresponding to the preset number of redundant data packets, and forwarding the redundant data packets to the content distribution terminal, the preset number of video data packets being used to indicate the number of video data packets in a data packet coding group, and the preset number of redundant data packets being used to indicate the number of redundant data packets in a data packet coding group; initializing the coding buffer area, and executing the step of copying the video data packet into the coding buffer area in response to the received video data packet; The content distribution terminal is used to: upon receiving the video data packet or the redundant data packet, distribute the video data packet or the redundant data packet to at least one upstream terminal; each upstream terminal is respectively connected to the content distribution terminal; The upstream terminal is configured to: upon receiving the video data packet or the redundant data packet, forward the video data packet or the redundant data packet to at least one downstream terminal via a forwarding sub-flow.

2. The system according to claim 1, characterized in that The video forwarding terminal is also used to: when the number of copies is less than the preset number of video data packets, execute the steps of copying the video data packets to the encoding buffer area in response to the received video data packets and forwarding the video data packets to the content distribution terminal.

3. The system according to claim 1, characterized in that Before forwarding the video data packet to the content distribution terminal, the video forwarding terminal is further used to: determine the data packet sequence number corresponding to the video data packet according to the forwarding sequence corresponding to the video data packet, and add the sequence number to the packet header of the video data packet; Before forwarding the redundant data packet to the content distribution terminal, the video forwarding terminal is further used to: determine the data packet sequence number corresponding to the redundant data packet according to the forwarding order corresponding to the redundant data packet, and add the sequence number to the header of the redundant data packet; Before forwarding the video data packet or the redundant data packet to at least one downstream terminal via a forwarding substream, the upstream terminal is further used to: obtain a target modulus value; perform a modulus operation on a data packet sequence number corresponding to the video data packet or a data packet sequence number corresponding to the redundant data packet using the target modulus value to obtain a modulus result; and determine, based on the modulus result, the video data packet or redundant data packet sent by each forwarding substream.

4. The system according to claim 1, characterized in that The upstream terminal is further configured to: upon receiving the video data packet or the redundant data packet, determine the data packet sequence number corresponding to the video data packet or the data packet sequence number corresponding to the redundant data packet according to the receiving order, and add the sequence number to the packet header; Before forwarding the video data packet or the redundant data packet to at least one downstream terminal via a forwarding substream, the upstream terminal is further used to: obtain a target modulus value; perform a modulus operation on a data packet sequence number corresponding to the video data packet or a data packet sequence number corresponding to the redundant data packet using the target modulus value to obtain a modulus result; and determine a forwarding substream for forwarding the video data packet and a forwarding substream for forwarding the redundant data packet based on the modulus result.

5. The system according to claim 1, characterized in that The video forwarding terminal is further used to: add a coding group identifier and a data packet identifier to the video data packet and the redundant data packet respectively; the coding group identifier is used to indicate the data packet coding group to which the video data packet and the redundant data packet belong, and the data packet identifier is used to indicate the data packet type corresponding to the video data packet and the redundant data packet; The downstream terminal is used to: determine whether all video data packets in the current data packet coding group are received based on the preset number of video data packets, the coding group identifier and the data packet identifier; In the case that there is packet loss in the video data packet in the current data packet coding group, all the video data packets in the current data packet coding group are restored based on the redundant data packets in the current data packet coding group and the received video data packets.

6. The system according to claim 5, characterized in that The upstream terminal is further configured to: upon receiving the video data packet or the redundant data packet, determine the video data packet or the redundant data packet sent by each forwarding sub-flow based on the data packet identifier.

7. The system according to any one of claims 3 to 6, characterized in that: The number of sub-streams corresponding to the forwarding sub-stream is the sum of the number of the preset redundant data packets and the number of the video data packets.

8. The system according to any one of claims 3 to 4, characterized in that: The video forwarding terminal is further used to: determine the target module value based on the preset number of video data packets and the preset number of redundant data packets; and send the target module value to the content distribution terminal; The content distribution terminal is further configured to: upon receiving the target module value, send the target module value to the at least one upstream terminal.

9. The system according to claim 1, characterized in that In response to the received video data packet, the video data packet is copied into the encoding buffer area, and before the video data packet is forwarded to the content distribution terminal, the video forwarding terminal is also used to: obtain the packet loss test result between the upstream terminal and the downstream terminal; based on the packet loss test result, determine the value of the preset redundant data packet number and the value of the preset video data packet number.

10. The system according to claim 1, characterized in that The preset encoding method includes a Reed-Solomon encoding method or an XOR encoding method.

Citation Information

Patent Citations

  • Video stream processing method and device based on confluence sending mechanism, equipment and medium

    CN116634187A

  • Redundant information assisted coding cache retransmission method and system

    CN117640622A