Multimedia data transmission method and device

During the multimedia data transmission process, when all data is not received within the target reception time, a stop command is sent and the data is obtained from the content distribution server, which solves the problem of low bandwidth utilization and improves the efficiency of multimedia data transmission.

CN111726658BActive Publication Date: 2024-09-24TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202010533721.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-06-12
Publication Date
2024-09-24
Estimated Expiration
2040-06-12

AI Technical Summary

Technical Problem

The existing technology has low bandwidth utilization in multimedia data transmission. Especially when all multimedia fragmented data is not received within the target reception time, the data node continues to transmit the multimedia fragmented data, resulting in a waste of bandwidth.

Method used

When all multimedia fragment data is not received within the target reception time, a data transmission stop command is sent to the data node to stop the transmission of multimedia fragment data, and the unreceived multimedia fragment data is obtained from the content distribution server.

Benefits of technology

It effectively improves the bandwidth utilization during multimedia data transmission, avoids unnecessary waste of bandwidth, and ensures that all multimedia data can be obtained within a limited time.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN111726658B
    Figure CN111726658B
Patent Text Reader

Abstract

The embodiment of the present application discloses a multimedia data transmission method and device; the embodiment of the present application is related to content distribution. The embodiment of the present application sends a data request for target multimedia data to a data node, wherein the target multimedia data includes multiple multimedia fragment data, and receives the multimedia fragment data returned by the data node based on the data request. When all multimedia fragment data of the target multimedia data are not received within the target reception time, a data transmission stop command is sent to the data node to make the data node stop transmitting the multimedia fragment data and obtain the unreceived multimedia fragment data from the content distribution server; this scheme can improve the bandwidth utilization rate of the multimedia data transmission process.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of networks, and in particular to a multimedia data transmission method and device. Background Art

[0002] In the process of multimedia on-demand or live broadcasting through the Internet, in order to ensure smooth playback to the greatest extent, the existing technology usually combines peer-to-peer (P2P) and content distribution network (CDN) when obtaining multimedia fragment data. For example, multimedia data is first received based on P2P. If all multimedia data cannot be received based on P2P within a set time, the unreceived multimedia data is then obtained based on CDN. In the process of research and practice on the existing technology, the inventor of the present application found that the existing technology has the defect of low bandwidth utilization when transmitting multimedia data. Summary of the invention

[0003] The embodiments of the present application provide a multimedia data transmission method and device, which can improve the bandwidth utilization rate of the multimedia data transmission process.

[0004] The present invention provides a multimedia data transmission method, including:

[0005] Sending a data request for target multimedia data to a data node, wherein the target multimedia data includes a plurality of multimedia slice data;

[0006] Receiving multimedia slice data returned by the data node based on the data request;

[0007] When all multimedia slice data of the target multimedia data are not received within the target receiving time, sending a data transmission stop command to the data node to make the data node stop transmitting the multimedia slice data;

[0008] Acquire the unreceived multimedia segment data from the content distribution server.

[0009] The present invention provides a multimedia data transmission method, including:

[0010] Receiving a data request sent by a requesting node, wherein the data request includes information of multiple multimedia slices;

[0011] Sending multimedia slice data to the requesting node based on the multimedia slice information;

[0012] Obtain the current data sending duration of multimedia segment data in real time;

[0013] When a data transmission stop command is received from the requesting node, or the current data transmission duration is not less than the target transmission duration, the step of sending multimedia fragment data to the requesting node based on the multimedia fragment information is stopped, wherein the data transmission stop command is sent by the requesting node based on the target receiving duration.

[0014] Accordingly, an embodiment of the present application provides a multimedia data transmission device, including:

[0015] A first sending module includes sending a data request for target multimedia data to a data node, wherein the target multimedia data includes a plurality of multimedia slice data;

[0016] A receiving module, comprising receiving multimedia slice data returned by the data node based on the data request;

[0017] A second sending module includes sending a data transmission stop command to the data node when all multimedia fragment data of the target multimedia data are not received within the target receiving time length, so that the data node stops transmitting the multimedia fragment data;

[0018] The acquisition module includes acquiring the unreceived multimedia segment data from the content distribution server.

[0019] In some embodiments of the present application, the multimedia data transmission device further includes:

[0020] A determination module, used to determine a target receiving duration and a target sending duration for a data node, wherein the target sending duration is less than the target receiving duration;

[0021] At this time, the first sending module is used for:

[0022] Based on the target sending duration, a data request for target multimedia data is sent to the data node, where the data request includes the target sending duration.

[0023] In some embodiments of the present application, the determination module includes an acquisition submodule and a determination submodule, wherein:

[0024] An acquisition submodule is used to acquire duration information corresponding to target multimedia data;

[0025] The determination submodule is used to determine a target receiving duration and a target sending duration for the data node based on the duration information.

[0026] In some embodiments of the present application, the second sending module includes a calculation submodule, a real-time detection submodule and a sending submodule, wherein:

[0027] A calculation submodule, used to calculate the current data reception duration based on a preset duration;

[0028] A real-time detection submodule, used for performing real-time detection on the received multimedia segment data;

[0029] The sending submodule is used to determine that all multimedia fragment data of the target multimedia data have not been received within the target receiving time length when the current data receiving time length is greater than or equal to the target receiving time length and all multimedia fragment data of the target multimedia data have not been detected, and send a data transmission stop command to the data node.

[0030] In some embodiments of the present application, the multimedia data transmission device further includes:

[0031] A setting module, used for setting the current time point as the data receiving start time point when sending a data request for target multimedia data to a data node;

[0032] At this time, the calculation submodule is specifically used for:

[0033] The current time point is obtained based on the preset duration, and the difference between the current time point and the data reception start time point is calculated to obtain the current data reception duration.

[0034] Accordingly, an embodiment of the present application provides a multimedia data transmission device, including:

[0035] A receiving module, configured to receive a data request sent by a requesting node, wherein the data request includes information of multiple multimedia slices;

[0036] A sending module, configured to send multimedia slice data to the requesting node based on the multimedia slice information;

[0037] An acquisition module is used to acquire the current data transmission duration of multimedia segment data in real time;

[0038] A stop execution module is used to stop executing the step of sending multimedia fragment data to the requesting node based on the multimedia fragment information when a data transmission stop command sent by the requesting node is received, or the current data sending duration is not less than the target sending duration, wherein the data transmission stop command is sent by the requesting node based on the target receiving duration.

[0039] In some embodiments of the present application, the multimedia data transmission device further includes:

[0040] The parsing module is used to parse the data request to obtain target sending duration and multiple multimedia segment information.

[0041] In some embodiments of the present application, the multimedia data transmission device further includes:

[0042] The generating module is used to generate a target sending duration for multimedia data transmission based on the data request when receiving a data request sent by the requesting node.

[0043] Correspondingly, an embodiment of the present application further provides a storage medium, which stores a computer program, and the computer program is suitable for loading by a processor to execute any multimedia data transmission method provided in the embodiment of the present application.

[0044] Correspondingly, an embodiment of the present application also provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, any one of the multimedia data transmission methods provided in the embodiment of the present application is implemented.

[0045] In the present application, the requesting node first sends a data request for target multimedia data to the data node, wherein the target multimedia data includes multiple multimedia fragment data, and then receives the multimedia fragment data returned by the data node based on the data request. When all multimedia fragment data of the target multimedia data are not received within the target receiving time, a data transmission stop command is sent to the data node to make the data node stop transmitting the multimedia fragment data, and finally the unreceived multimedia fragment data is obtained from the content distribution server.

[0046] The data node receives a data request sent by a requesting node, where the data request includes multiple multimedia slice information, and then sends the multimedia slice data to the requesting node based on the multimedia slice information, and obtains the current data sending duration of the multimedia slice data in real time; when a data transmission stop command sent by the requesting node is received, or the current data sending duration is not less than the target sending duration, the step of sending the multimedia slice data to the requesting node based on the multimedia slice information is stopped, wherein the data transmission stop command is sent by the requesting node based on the target receiving duration.

[0047] In this scheme, when the requesting node fails to receive all multimedia fragment data of the target multimedia data within the target receiving time, it will send a data transmission stop command to the data node. After receiving the data transmission stop command, the data node will stop sending the multimedia fragment data to the requesting node, thereby avoiding the situation where the data node continues to transmit multimedia data and consumes bandwidth after the requesting node no longer needs the multimedia fragment data transmitted by the data node. Therefore, this scheme can effectively improve the bandwidth utilization rate during multimedia data transmission. BRIEF DESCRIPTION OF THE DRAWINGS

[0048] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For those skilled in the art, other drawings can be obtained based on these drawings without creative work.

[0049] Figure 1 is a schematic diagram of a scenario of a multimedia data transmission device provided in an embodiment of the present application;

[0050] Figure 2 It is a flowchart of a multimedia data transmission method provided in an embodiment of the present application;

[0051] Figure 3 is another flowchart of the multimedia data transmission method provided by an embodiment of the present application;

[0052] Figure 4 It is a schematic diagram of video file segmentation provided in an embodiment of the present application;

[0053] Figure 5 It is a schematic diagram of a video file download data strategy provided by an embodiment of the present application;

[0054] Figure 6 is another flowchart of the multimedia data transmission method provided by an embodiment of the present application;

[0055] Figure 7 is another flowchart of the multimedia data transmission method provided by an embodiment of the present application;

[0056] Figure 8 is a schematic diagram of the structure of a multimedia data transmission device provided in an embodiment of the present application;

[0057] Fig. 9 is another structural schematic diagram of the multimedia data transmission device provided in an embodiment of the present application;

[0058] Fig.10 is another structural schematic diagram of the multimedia data transmission device provided in an embodiment of the present application;

[0059] Fig.11 It is a schematic diagram of the structure of a computer device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0060] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the embodiments described in this application are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of this application.

[0061] The embodiment of the present application provides a multimedia data transmission method and device. Specifically, the embodiment of the present application can be integrated into a first multimedia data transmission device (referred to as the first transmission device) and a second multimedia transmission device (referred to as the second transmission device).

[0062] The first transmission device may be integrated in a first computer device, which may be a requesting node, and the first computer device may include a terminal or a server, etc. The terminal may be a smart phone, a tablet computer, a laptop computer, a desktop computer, a smart speaker, a smart watch, etc., but is not limited thereto. The server may be an independent physical server, or a server cluster or a distributed system composed of multiple physical servers, or a cloud server providing cloud computing services. The terminal and the server may be directly or indirectly connected via wired or wireless communication, and this application does not limit this.

[0063] The second transmission device can be integrated in a second computer device, which can be a data node. The second computer device can include a terminal or a server, etc. The server can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides cloud computing services. The terminal can be a smart phone, a tablet computer, a laptop computer, a desktop computer, a smart speaker, a smart watch, etc., but is not limited to this. The terminal and the server can be directly or indirectly connected via wired or wireless communication, and this application does not limit this.

[0064] like Figure 1 As shown, in the solution of the embodiment of the present application, the requesting node and the data node will interact and transmit multimedia data. Specifically,

[0065] The requesting node can send a data request for target multimedia data to the data node, wherein the target multimedia data includes multiple multimedia fragment data, and then receive the multimedia fragment data returned by the data node based on the data request. When all multimedia fragment data of the target multimedia data are not received within the target receiving time, a data transmission stop command is sent to the data node to make the data node stop transmitting the multimedia fragment data, and finally the unreceived multimedia fragment data is obtained from the content distribution server.

[0066] The data node can receive a data request sent by a requesting node, the data request includes multiple multimedia slice information, and then send the multimedia slice data to the requesting node based on the multimedia slice information, and then obtain the current data sending duration of the multimedia slice data in real time; finally, when a data transmission stop command sent by the requesting node is received, or the current data sending duration is not less than the target sending duration, stop executing the step of sending the multimedia slice data to the requesting node based on the multimedia slice information, wherein the data transmission stop command is sent by the requesting node based on the target receiving duration.

[0067] It should be noted that Figure 1 The scenario diagram of the multimedia data transmission device shown is merely an example. The multimedia data transmission device and scenario described in the embodiment of the present application are intended to more clearly illustrate the technical solution of the embodiment of the present application, and do not constitute a limitation on the technical solution provided in the embodiment of the present application. A person of ordinary skill in the art can appreciate that with the evolution of multimedia data transmission devices and the emergence of new business scenarios, the technical solution provided in the embodiment of the present application is equally applicable to similar technical problems.

[0068] The following are detailed descriptions. In this embodiment, the description will be made from the perspective of the first transmission device. The request node can be integrated into the first transmission device, such as Figure 2 As shown, Figure 2 : is a flowchart of a multimedia data transmission method provided by an embodiment of the present application. The multimedia data transmission method may include:

[0069] 101. Send a data request for target multimedia data to a data node, wherein the target multimedia data includes a plurality of multimedia slice data.

[0070] A data node may be a computer device storing target multimedia data. Before sending a data request to a data node, a data node storing the target multimedia data may be determined from among several nodes. Specifically, a request message may be sent to multiple nodes, and by receiving feedback information returned by each node, the data stored on each node may be determined, and finally the data node storing the target multimedia data may be determined. Nodes may also send storage information to each other at set time intervals, and the storage information may include data information stored on this node. The data node storing the target multimedia data may be determined through the storage information transmitted periodically by several nodes.

[0071] The target multimedia data may include audio data, video data, etc.

[0072] The target multimedia data can be specific to multiple application scenarios, such as online video on demand, online audio on demand, online live broadcast (in video or audio form), etc. For example, a user watches video A online through a video website, and the current playback time point of the video A being played is 15 seconds. In order to ensure smooth playback, the video website has downloaded the video data from 15 seconds to 20 seconds of video A. At this time, it is necessary to pre-download the video data from 20 seconds to 30 seconds. At this time, the target multimedia data can be the video data from 20 seconds to 30 seconds of video A.

[0073] Multimedia data may include several multimedia fragment data. In order to facilitate data transmission and ensure the smoothness of multimedia playback, a larger multimedia data can be divided into several smaller fragment data. When data transmission is performed, the fragment data can be transmitted in sequence according to the sequence information of the fragment data. The receiving party can play the fragment data after receiving one fragment data. There is no need to play it after receiving the entire multimedia data. In special moments such as poor network conditions and slow network speed, smooth playback can be guaranteed to a certain extent.

[0074] The data request may be used to request the target multimedia data from the data node. The data request may include multimedia slice information of the target multimedia data, the multimedia slice information may be a slice identifier of the slice data, the slice identifier may be information that uniquely identifies the slice data, and the data node may determine the target multimedia data based on the slice identifier.

[0075] For example, a data request O is sent to the data node PP, where the data request O includes relevant information of the target multimedia data.

[0076] In some embodiments, the multimedia data transmission method may further include: determining a target receiving duration and a target sending duration for a data node,

[0077] At this time, the step of "sending a data request for target multimedia data to the data node" may include: based on the target sending duration, sending a data request for target multimedia data to the data node, the data request including the target sending duration.

[0078] Since data nodes can be any computer devices, they are not stable and may be disconnected from the network at any time. In order to ensure that the required target multimedia data is obtained in time, the requesting node can set key information for the data node, such as target receiving time and target sending time.

[0079] The target receiving duration may be the maximum duration that the requesting node and the data node may consume to transmit the target multimedia data.

[0080] The target sending duration can be the maximum duration that the data node can take to transmit the target multimedia slice data to the requesting node. Therefore, the data request sent to the data node can also include the target sending duration. The requesting node can integrate the slice information of the target multimedia data and the target sending duration as a data request and send the data request to the data node.

[0081] The determination of the target sending duration and the target receiving duration can be completed based on multiple factors, such as the current network status (such as maximum bandwidth, congestion, etc.), the characteristics of the data node (such as the distance from the requesting node, etc.), or the target multimedia data (such as the data volume, duration, etc. of the target multimedia data), etc.

[0082] For example, a target sending duration of 10s and a target receiving duration of 11s for the data node PP may be determined, and based on the target sending duration, a data request O is sent to the data node PP, where the data request O includes a data sending duration of 10s.

[0083] In some embodiments, the step of “determining a target receiving duration and a target sending duration for a data node” may include:

[0084] Obtain duration information corresponding to target multimedia data; and determine a target receiving duration and a target sending duration for the data node based on the duration information.

[0085] The target receiving duration and target sending duration of the data node are determined by the duration information. Specifically, the target receiving duration can be determined based on the duration information. The setting of the target receiving duration should ensure the smooth playback of online multimedia to the greatest extent. For example, when all target multimedia data cannot be obtained through the data node, the requesting node can also have enough time to download the target multimedia data that has not been obtained from the server, so as to ensure that all target multimedia data can be obtained within a limited time.

[0086] In addition, the target reception duration can also be determined based on other factors, such as the format of the target multimedia data, the purpose of the target multimedia data, and the hardware characteristics of the requesting node, etc., which can be flexibly determined during actual application and will not be elaborated here.

[0087] After determining the target reception duration, the target sending duration can be set for the data node based on the target reception duration. For example, the time required from the requesting node sending the data request to the data node receiving and parsing the target sending duration in the data request can be predicted according to the current network status, and the target sending duration can be set for the data node based on this time and the target reception duration. For another example, the time consumed by the data node to transmit multimedia fragmented data to the requesting node (such as the time between the data node sending and the requesting node receiving, which is the time consumed by the transmission process) can be predicted, and the target sending duration can be set for the data node based on this time and the target reception duration, and so on. Obviously, the target sending duration should be less than the target reception duration.

[0088] 102. Receive multimedia slice data returned by the data node based on the data request.

[0089] The data node may return the slice data of the target multimedia data to the request node in sequence. The slice data of a multimedia data may be expressed in order by an identifier. For example, different slices may be identified by Arabic numerals.

[0090] The target multimedia data includes multiple fragmented data. When performing data transmission, the data node can perform data transmission in sequence according to the identifier of the fragmented data. Therefore, the requesting node can receive part of the fragmented data of the target multimedia data within a period of time.

[0091] For example, the receiving data node PP returns multimedia slice data based on the data request O. The target multimedia data includes 10 multimedia slice data. The requesting node starts from slice data 1 and receives the multimedia slice data in sequence.

[0092] 103. When all multimedia slice data of the target multimedia data are not received within the target receiving time, a data transmission stop command is sent to the data node to make the data node stop transmitting the multimedia slice data.

[0093] The target receiving time can be the maximum time that the requesting node and the data node can consume for the target multimedia data transmission. Therefore, if the requesting node does not receive all the multimedia fragment data within the target receiving time, the data transmission between the requesting node and the data node should be stopped, that is, the data node should stop sending the multimedia fragment data to the requesting node. If the data node continues to transmit the multimedia fragment data to the requesting node at this time, this process requires bandwidth consumption. However, after exceeding the target receiving time, the requesting node no longer receives the multimedia fragment data sent by the data node, so consuming bandwidth to transmit multimedia fragment data is a waste of bandwidth, resulting in low bandwidth utilization during the complete target multimedia data acquisition process.

[0094] Therefore, in this application, when the requesting node fails to receive all multimedia fragment data within the target receiving time, it will send a data transmission stop command to the requesting node so that the data node stops transmitting the multimedia fragment data to the requesting node, thereby avoiding bandwidth waste here and improving bandwidth utilization.

[0095] The data transmission stop command may include information instructing the data node to stop transmitting multimedia segment data to the requesting node. The data transmission stop command may include key characters that are predefined or based on a set protocol, so that the data node and the requesting node can use this key character as a "language" to communicate information and trigger further operations based on this key character.

[0096] For example, when the requesting node does not receive 10 fragments of the target multimedia data within the target receiving time of 11s, the requesting node sends a data transmission stop command M to the data node PP so that the data node PP no longer transmits the target multimedia data to the requesting node.

[0097] In some embodiments, the step of “sending a data transmission stop command to a data node when all multimedia fragment data of the target multimedia data are not received within the target receiving duration” may include:

[0098] The current data reception duration is calculated based on the preset duration, and the received multimedia fragment data is detected in real time; when the current data reception duration is not less than the target reception duration, and all the multimedia fragment data of the target multimedia data are not detected, it is determined that all the multimedia fragment data of the target multimedia data are not received within the target reception duration, and a data transmission stop command is sent to the data node.

[0099] The preset time length may be a period of time, and the preset time length may be the time length between adjacent current data reception time lengths. For example, the preset time length may be 0.5s, that is, the current data reception time length is calculated every 0.5s.

[0100] The current receiving duration may refer to a time period that has been consumed in the multimedia data transmission process between the requesting node and the data node.

[0101] The received multimedia fragment data is detected in real time. When receiving the multimedia fragment data, the requesting node can determine whether all the multimedia fragment data of the target multimedia data are received by detecting the identifier of the fragment data.

[0102] Therefore, when it is detected that the current receiving duration is no longer less than the target receiving duration and all multimedia fragment data of the target multimedia data are not detected, it can be determined that all multimedia fragment data of the target multimedia data have not been received within the target receiving duration, that is, a data transmission stop command is sent to the data node.

[0103] For example, the current data receiving duration is calculated every 1 second, and when multimedia fragment data is received, the fragment identifier of the multimedia fragment data is detected to determine whether all multimedia fragment data of the target multimedia data are received. When the target receiving duration of 10 seconds is equal to the current data receiving duration of 10 seconds, and the detected multimedia fragment data is 9 (the preset target multimedia data contains 10 fragments), the requesting node sends a PP data transmission stop command M to the data node.

[0104] In some embodiments, the multimedia data transmission method may further include:

[0105] When sending a data request for target multimedia data to a data node, the current time point is set as the data receiving start time point.

[0106] At this time, the step of "calculating the current data reception duration based on the preset duration" may include:

[0107] The current time point is obtained based on the preset duration, and the difference between the current time point and the data reception start time point is calculated to obtain the current data reception duration.

[0108] Among them, calculating the current data reception duration requires determining the time point corresponding to the starting point of multimedia data transmission between the requesting node and the data node. The starting point can be flexibly set according to actual conditions. For example, the time when the requesting node sends a data request for target multimedia data to the data node can be determined as the starting point. The time point when the requesting node sends the data request to the data node can be recorded, and the time point can be set as the starting time point for data reception.

[0109] Then, the current time point can be obtained with the preset time length as the time interval, and the difference between the current time point and the data reception start time point can be calculated, and the difference can be the current data reception duration.

[0110] For example, the time point a1 when the requesting node sends the data request O to the data node PP can be recorded. The time point a1 is the starting time point of data reception. Then the current time point a2 is obtained every 1s, and the difference A between the current time point a2 and the starting time point a1 of data reception is calculated. The difference A is the current data reception duration.

[0111] 104. Obtain the multimedia segment data that has not been received from the content distribution server.

[0112] Specifically, a data request for the multimedia segment data that has not been received may be sent to the content distribution server. After receiving the data request, the content distribution server may return the multimedia segment data to the requesting node based on the data request.

[0113] The content distribution server is usually stable and has fast data transmission, and can be used as a reliable data source. Therefore, when all multimedia fragment data of the multimedia data cannot be received within the target receiving time, the unreceived multimedia fragment data can be obtained from the content distribution server.

[0114] For example, the requesting node obtains multimedia fragment data 10 from the content distribution server, where the multimedia fragment data 10 is multimedia fragment data of the target multimedia data that the requesting node has not received from the requesting node within the target receiving time duration.

[0115] This embodiment first sends a data request for target multimedia data to a data node, wherein the target multimedia data includes a plurality of multimedia slice data, and then receives the multimedia slice data returned by the data node based on the data request.

[0116] When all multimedia fragment data of the target multimedia data are not received within the target receiving time, a data transmission stop command is sent to the data node to stop the data node from transmitting the multimedia fragment data, and finally the unreceived multimedia fragment data is obtained from the content distribution server.

[0117] In this embodiment, when the requesting node fails to receive all multimedia fragment data of the target multimedia data within the target receiving time, the requesting node no longer needs the multimedia fragment data transmitted by the data node, but directly obtains the unobtained multimedia fragment data from the content distribution server. At this time, the requesting node can send a data transmission stop command to the data node, so that the data node no longer transmits the multimedia fragment data to the requesting node, thereby saving the bandwidth consumed in the original process and significantly improving the bandwidth utilization rate in the multimedia data transmission process.

[0118] In this embodiment, the description will be made from the perspective of the second transmission device. The data node may be integrated on the second transmission device, such as Figure 3 As shown, Figure 3 : is a flowchart of a multimedia data transmission method provided by an embodiment of the present application. The multimedia data transmission method may include:

[0119] 201. Receive a data request sent by a requesting node, where the data request includes information of multiple multimedia slices.

[0120] The requesting node can be a computer device that requests target multimedia data from the data node. Multimedia data is transmitted between the requesting node and the data node. The requesting node and the data node are not unique. In a node set composed of multiple nodes, any node that needs to request data is a requesting node, and any node that can transmit data to the requesting node is a data node. When a node can transmit data to other nodes and needs data from other nodes, the node is both a requesting node and a data node. However, in the solution of the present application, the requesting node and the data node are the receiver and sender of the target multimedia data transmission, and are two different nodes.

[0121] The data request may be used to request target multimedia data from a data node, and the data request may include multimedia slice information of the target multimedia data.

[0122] The multimedia slice information can uniquely identify the multimedia slice data. The data node can determine its unique corresponding multimedia slice data based on the multimedia slice information. The multimedia slice data can be data with a small memory footprint. Several multimedia slice data can constitute a complete target multimedia data.

[0123] The target multimedia data may include audio data, video data, etc. that need to be obtained. The multimedia data may include several multimedia fragment data. In order to facilitate data transmission and smooth playback, a larger multimedia data can be divided into several smaller fragment data. When data transmission is performed, the fragment data can be transmitted in sequence according to the sequence information of the fragment data. The receiver can play the fragment data after receiving one fragment data. There is no need to play it after receiving the entire multimedia data. When the network condition is poor and the network speed is slow, smooth playback can be guaranteed to a certain extent.

[0124] After receiving the data request sent by the requesting node, the data request can be parsed to obtain multimedia slice information, and the corresponding multimedia slice data can be determined based on the slice information, as well as the storage location of the multimedia slice data on the data node.

[0125] For example, a data request O sent by a requesting node KK is received, and the data request O includes multimedia segment information (segment identifiers 1 to 10).

[0126] 202. Send multimedia fragment data to the requesting node based on the multimedia fragment information.

[0127] The data node sends data to the requesting node based on some pre-set related protocols and rules, such as the P2P application used to implement file distribution between the requesting node and the data node, the transmission protocol that provides data transmission services for communication between the requesting node and the data node, such as the User Datagram Protocol (UDP), the protocol that provides communication services for the requesting node and the data node, such as the Internet Protocol (IP), and related protocols of the data link layer and the physical layer during the data transmission process.

[0128] The data node can add necessary information to the sliced ​​data based on the provisions of such protocols or rules. Finally, the multimedia data and related necessary information will be transmitted to the requesting node through the physical layer in the form of digital signals.

[0129] For example, the corresponding multimedia fragment data (fragment data 1 to 10) may be determined based on the multimedia fragment information, and the multimedia fragment data may be sent to the requesting node in sequence.

[0130] 203. Obtain the current data sending duration of the multimedia segment data in real time.

[0131] The current data transmission duration may be the time period that the data node has spent sending multimedia fragment data to the requesting node. The current data transmission duration may be obtained at a set time interval and compared with the target receiving duration. The time point at which the data node receives the data request may be set as the data transmission start time point, and the current time point may be obtained at a set time interval, and the difference between the current time point and the data transmission start time point is calculated, and the difference is the current data transmission duration.

[0132] 204. When a data transmission stop command is received from a requesting node, or the current data transmission duration is not less than the target transmission duration, stop executing the step of sending multimedia fragment data to the requesting node based on the multimedia fragment information, wherein the data transmission stop command is sent by the requesting node based on the target receiving duration.

[0133] When receiving a data transmission stop command sent by the requesting node, the step of sending multimedia slice data to the requesting node based on the multimedia slice information is stopped. Specifically,

[0134] The data transmission stop command may include information instructing the data node to stop transmitting multimedia segment data to the requesting node. The data transmission stop command may include key characters that are predefined or based on a set protocol, so that the data node and the requesting node can use this key character as a "language" to communicate information and trigger further operations based on this key character.

[0135] After receiving the multimedia fragmentation information sent by the requesting node, the data node sends all the multimedia fragmentation data corresponding to the multimedia fragmentation information to the requesting node by default. It usually takes a certain amount of time to complete this process. When the network condition is poor, such as congestion, it will take longer. In order to ensure that all the multimedia fragmentation data are received within the set time period, the requesting node will set a duration for the multimedia data transmission process between the data node and the requesting node, that is, the target receiving duration. When the requesting node determines that the duration of the multimedia data transmission process with the data node reaches the target receiving duration, it will send a data transmission stop command to the data node. After receiving the data transmission stop command, the data node stops sending multimedia fragmentation data to the requesting node, avoiding the data node from continuing to send multimedia fragmentation data that the requesting node no longer needs, avoiding unnecessary bandwidth consumption, and thus improving the bandwidth utilization rate during multimedia data transmission.

[0136] For example, when a data transmission stop command M sent by the requesting node KK is received, the step of sending multimedia segment data to the requesting node is stopped.

[0137] When the current data transmission duration is not less than the target transmission duration, the step of sending the multimedia slice data to the requesting node based on the multimedia slice information is stopped. Specifically,

[0138] The target sending duration may be the maximum duration that a data node may spend in transmitting target multimedia fragment data to a requesting node. The target sending duration may be flexibly set based on the target receiving duration, network conditions, characteristics of the data node and the requesting node, and is not limited here. Usually, the target sending duration is less than the target receiving duration.

[0139] In order to ensure that the requesting node obtains all multimedia slice data of the target multimedia data within the set time period and improve the bandwidth utilization, the present embodiment can also set a target sending duration for the data node. The data node can send the multimedia slice data to the requesting node within the target sending duration. When the time period consumed for sending the multimedia slice data reaches the target sending duration, the data node no longer needs to send the multimedia slice data to the requesting node, that is, stops sending the multimedia slice data operation, avoids the data node sending unnecessary multimedia slice data to the requesting node, thereby avoiding bandwidth waste and effectively improving the bandwidth utilization of the multimedia data transmission process.

[0140] It should be noted that, in actual application, in order to effectively improve the bandwidth utilization rate during multimedia data transmission and avoid unnecessary bandwidth waste, the step of sending multimedia fragment data can be stopped when a data transmission stop command is received; the step of sending multimedia fragment data can be stopped when the current data sending duration reaches the target sending duration; the step of sending multimedia fragment data can be stopped when a data transmission stop command is received or the current data sending duration reaches the target sending duration, etc.

[0141] For example, if the target sending duration is 10 seconds, and the current data sending duration is calculated to be 10 seconds, the step of sending the multimedia segment data to the requesting node is stopped.

[0142] In some embodiments, the multimedia data transmission method further includes:

[0143] The data request is parsed to obtain the target sending duration and multiple multimedia segment information.

[0144] When the requesting node sends a data request to the data node, it can set the target sending duration for the data node in advance. After receiving the data request, the data node parses the data request to obtain the target sending duration. For example, by parsing the data request, the target sending duration can be 10s.

[0145] In some embodiments, the multimedia data transmission method further includes:

[0146] When a data request sent by a requesting node is received, a target sending duration for multimedia data transmission is generated based on the data request.

[0147] The target sending duration can be generated by the data node itself based on relevant information. For example, based on the data request sent by the requesting node, the characteristics of the requesting node, the size of the target multimedia data, the target receiving duration set by the requesting node, etc. can be determined, and based on the characteristics of the data node itself, network conditions, etc., the target sending duration for transmitting the target multimedia data with the requesting node is generated.

[0148] The data node of the present application first receives a data request sent by a requesting node, the data request includes multiple multimedia fragmentation information, and then sends multimedia fragmentation data to the requesting node based on the multimedia fragmentation information, then obtains the current data transmission duration of the multimedia fragmentation data in real time, and finally stops executing the step of sending multimedia fragmentation data to the requesting node based on the multimedia fragmentation information when receiving a data transmission stop command sent by the requesting node, or the current data transmission duration is not less than the target transmission duration, wherein the data transmission stop command is sent by the requesting node based on the target reception duration. When receiving the data transmission stop command, this embodiment stops transmitting the multimedia fragmentation data that the requesting node no longer needs, thus avoiding wasting bandwidth and effectively improving the bandwidth utilization of the multimedia data transmission process.

[0149] The method described in the above embodiment is further described in detail below with examples.

[0150] This application will be described in detail by taking the target multimedia data as video data (video data for video on demand) as an example. Figure 4 As shown in the figure, the target multimedia data is a 500KB video file. In order to facilitate the transmission of video data in the network, the video file can be sliced ​​according to a fixed size. As shown in the figure, the video file is divided into 50 multimedia slice data, and the slice identifiers 0 to 49 are marked in sequence. When the requesting node requests the target multimedia data from the data node or the content distribution server, it can do so by carrying the slice identifier.

[0151] In the process of video on demand, you can use a combination of P2P and CDN to obtain segment data. Usually, CDN is stable online and has a large bandwidth, and is a reliable data source, but the cost of CDN is high, and the nodes in the P2P method may go offline at any time, and the network status is not stable. Therefore, in order to ensure smooth video playback during video on demand, you can use CDN to obtain video segment data close to the current playback time point, and use P2P to obtain video segment data far from the current playback time point, such as Figure 5 As shown in FIG. 1 , the current playback time point (ie, the current playback point in the figure) is the 10th second, the multimedia segment data from 10s to 20s is downloaded via CDN, and the multimedia segment data from 20s to 30s is downloaded via P2P.

[0152] like Figure 6 Show, Figure 6 The embodiment of the present application provides a schematic diagram of a merchant entry method, wherein:

[0153] 301. A requesting node obtains a total duration of target multimedia data and slice identifiers of a plurality of multimedia slice data of the target multimedia data.

[0154] For example, node A is a requesting node, node B is a data node, and node A determines that the totalPieceDuration (total duration) of the target multimedia data is 10s, and the slice identifiers (1 to 20) of 20 slice data of the target multimedia data.

[0155] 302. The requesting node determines, based on the total duration, a target receiving duration and a target sending duration required for multimedia data transmission with the data node.

[0156] For example, node A determines the requestTimeout (target receiving duration) to be 10 seconds and the responseTimeout (target sending duration) to be 9 seconds based on totalPieceDuration.

[0157] 303. The requesting node sends a data request to the data node, where the data request includes several shard identifiers and a target sending duration.

[0158] For example, node A creates a p2pRequest (data request), which carries the fragment identifier (1 to 20) of the target multimedia data and responseTimeout (target sending duration). At the same time, node A starts a timer with a timing duration of requestTimeout.

[0159] 304. The data node receives the data request, and parses the data request to obtain the target sending duration and the fragment identifier.

[0160] For example, after receiving the p2pRequest (data request), node B parses it to obtain the fragmentation identifier (1 to 20) and responseTimeout (target sending duration), and node B starts the timer with a timing duration of responseTimeout.

[0161] 305. The data node sends the multimedia segment data to the requesting node based on the segment identifier.

[0162] For example, node B determines corresponding multimedia fragment data (fragment data 1 to 20) based on the fragment identifiers (1 to 20), and sends these multimedia fragment data to node A in sequence.

[0163] 306. When the requesting node fails to receive all multimedia fragment data of the target multimedia data within the target receiving time, the requesting node sends a data transmission stop command to the data node.

[0164] For example, when the timer on the node A side expires and indicates that the target reception time has been reached, and node A has not received all the multimedia fragment data (fragment data 1 to 20), node A sends a close command (data transmission stop command) to node B so that node B no longer transmits multimedia fragment data to node A.

[0165] 307. When the data node receives a data transmission stop command or fails to send all multimedia fragment data corresponding to the fragment identifier within the target receiving time, the data node stops executing the step of sending the multimedia fragment data to the requesting node based on the fragment identifier.

[0166] For example, when the timer on the node B side is expired, indicating that the target transmission duration has been reached, or the node B receives a closing command sent by the node A, the node B stops transmitting the multimedia segment data with the node A.

[0167] 308. The requesting node obtains the target multimedia data that has not been received from the content distribution server.

[0168] For example, node A obtains remainingPieces data (ie, multimedia segment data that has not been received) from the CDN.

[0169] In actual application scenarios, problems that affect transmission speed, such as network congestion, may exist at any time. This embodiment can complete multimedia data transmission by simultaneously adopting data transmission notification commands and target reception durations to maximize the guarantee that when network congestion occurs, the data node can promptly stop sending multimedia fragment data to the requesting node, thereby avoiding useless multimedia fragment data transmission, thereby improving the bandwidth utilization of the multimedia data transmission process.

[0170] For example, if network congestion occurs when the requesting node sends a data request including a target receiving time, the data node receives the data request after a long period of time, causing the target receiving time set by the requesting node to no longer have a reference significance. However, when the requesting node reaches the target receiving time, the data transmission stop command sent by the requesting node can still take effect, stopping the data node from sending useless multimedia fragment data to the requesting node, thereby avoiding wasting bandwidth and improving bandwidth utilization in the multimedia data transmission process.

[0171] For another example, network congestion occurs during the sending process of a data transmission stop command, resulting in the data node receiving the data transmission stop command after a long period of time. However, the network condition during the sending process of the data request is good, that is, the target sending duration can be used normally. Then, the data node can stop sending multimedia segment data to the requesting node when the target sending duration is reached, thus avoiding possible bandwidth waste and improving the bandwidth utilization of the multimedia data transmission process.

[0172] like Figure 7 As shown, Figure 7 This is a flow chart of the present application. Node A (i.e., requesting node) sends a P2P slice data request and response timeout parameter (i.e., target sending duration) to node B (i.e., data node). After receiving it, node B starts to send slice data (i.e., multimedia slice data) until node B triggers the timeout response parameter and stops sending data. At this time, node A's request times out (i.e., reaches the target receiving duration), node A only receives part of the slice data or none of it, node A sends a shutdown command (i.e., data transmission stop command), and node B stops sending data to node A after receiving the shutdown command. Next, node A requests slice data from CDN (this slice data is the multimedia slice data that is not received), and CDN (i.e., content distribution server) returns the slice data required by node A.

[0173] In this embodiment, when the requesting node fails to receive all multimedia fragment data of the target multimedia data within the target receiving time, the requesting node no longer needs the multimedia fragment data transmitted by the data node, but directly obtains the multimedia fragment data that has not been obtained from the content distribution server. At this time, the requesting node can send a data transmission stop command to the data node, so that the data node no longer transmits multimedia fragment data to the requesting node. At the same time, when sending a data request, the requesting node sends the target sending time to the data node. If the data node fails to send all multimedia fragment data within the target sending time, it will automatically stop sending multimedia fragment data to the requesting node, thereby saving bandwidth, so that this scheme can significantly improve the bandwidth utilization rate during multimedia data transmission.

[0174] In order to better implement the multimedia data transmission method provided in the embodiment of the present application, the embodiment of the present application also provides a device based on the multimedia data transmission method. The meanings of the terms are the same as those in the multimedia data transmission method, and the specific implementation details can refer to the description in the method embodiment.

[0175] like Figure 8 As shown, Figure 8 A schematic diagram of the structure of a multimedia data transmission device provided in an embodiment of the present application, wherein the multimedia data transmission device may include a first sending module 401, a receiving module 402, a second sending module 403 and an acquisition module 404, wherein:

[0176] A first sending module 401 is used to send a data request for target multimedia data to a data node, wherein the target multimedia data includes a plurality of multimedia slice data;

[0177] The receiving module 402 is used to receive the multimedia slice data returned by the data node based on the data request;

[0178] The second sending module 403 is used to send a data transmission stop command to the data node when all multimedia fragment data of the target multimedia data are not received within the target receiving time length, so that the data node stops transmitting the multimedia fragment data;

[0179] The acquisition module 404 is used to acquire the unreceived multimedia segment data from the content distribution server.

[0180] In some embodiments of the present application, the multimedia data transmission device further includes:

[0181] A determination module, used to determine a target receiving duration and a target sending duration for a data node;

[0182] At this time, the first sending module is used for:

[0183] Based on the target sending duration, a data request for the target multimedia data is sent to the data node, where the data request includes the target sending duration.

[0184] In some embodiments of the present application, the determination module includes an acquisition submodule and a determination submodule, wherein:

[0185] An acquisition submodule is used to acquire duration information corresponding to target multimedia data;

[0186] The determination submodule is used to determine a target receiving duration and a target sending duration for the data node based on the duration information, and the target sending duration is less than the target receiving duration.

[0187] In some embodiments of the present application, Fig. 9 As shown, the second sending module 403 includes a calculation submodule 4031, a real-time detection submodule 4032 and a sending submodule 4033, wherein:

[0188] A calculation submodule 4031 is used to calculate the current data reception duration based on a preset duration;

[0189] A real-time detection submodule 4032 is used to perform real-time detection on the received multimedia segment data;

[0190] The sending submodule 4033 is used to determine that all multimedia fragment data of the target multimedia data have not been received within the target receiving time length when the current data receiving time length is greater than or equal to the target receiving time length and all multimedia fragment data of the target multimedia data have not been detected, and send a data transmission stop command to the data node.

[0191] In some embodiments of the present application, the multimedia data transmission device further includes:

[0192] A setting module, used for setting the current time point as the data receiving start time point when sending a data request for target multimedia data to a data node;

[0193] At this time, the calculation submodule is specifically used for:

[0194] The current time point is obtained based on the preset duration, and the difference between the current time point and the data reception start time point is calculated to obtain the current data reception duration.

[0195] In this embodiment, the first sending module 401 first sends a data request for target multimedia data to the data node, wherein the target multimedia data includes multiple multimedia fragment data, and then the receiving module 402 receives the multimedia fragment data returned by the data node based on the data request. When all multimedia fragment data of the target multimedia data are not received within the target receiving time, the second sending module 403 sends a data transmission stop command to the data node to make the data node stop transmitting the multimedia fragment data. Finally, the acquisition module 404 acquires the unreceived multimedia fragment data from the content distribution server.

[0196] In this embodiment, when the requesting node fails to receive all multimedia fragment data of the target multimedia data within the target receiving time, the requesting node no longer needs the multimedia fragment data transmitted by the data node, but directly obtains the unobtained multimedia fragment data from the content distribution server. At this time, the requesting node can send a data transmission stop command to the data node, so that the data node no longer transmits the multimedia fragment data to the requesting node, thereby saving the bandwidth consumed in the original process and significantly improving the bandwidth utilization rate in the multimedia data transmission process.

[0197] In order to better implement the multimedia data transmission method provided in the embodiment of the present application, the embodiment of the present application also provides a device based on the multimedia data transmission method. The meanings of the terms are the same as those in the multimedia data transmission method, and the specific implementation details can refer to the description in the method embodiment.

[0198] like Fig.10 As shown, Fig.10 A schematic diagram of the structure of a multimedia data transmission device provided in an embodiment of the present application, wherein the multimedia data transmission device may include a receiving module 501, a sending module 502, an acquisition module 503 and a stop execution module 504, wherein:

[0199] A receiving module 501 is used to receive a data request sent by a requesting node, where the data request includes information of multiple multimedia slices;

[0200] A sending module 502, configured to send multimedia slice data to a requesting node based on the multimedia slice information;

[0201] An acquisition module 503 is used to acquire the current data transmission duration of the multimedia segment data in real time;

[0202] The stop execution module 504 is used to stop executing the step of sending multimedia fragment data to the requesting node based on the multimedia fragment information when a data transmission stop command sent by the requesting node is received, or the current data transmission duration is not less than the target transmission duration, wherein the data transmission stop command is sent by the requesting node based on the target receiving duration.

[0203] In some embodiments of the present application, the multimedia data transmission device further includes:

[0204] The parsing module is used to parse the data request to obtain the target sending duration and multiple multimedia fragment information.

[0205] In some embodiments of the present application, the multimedia data transmission device further includes:

[0206] The generating module is used to generate a target sending duration for multimedia data transmission based on the data request when receiving a data request sent by the requesting node.

[0207] In this embodiment, the receiving module 501 first receives a data request sent by a requesting node, the data request includes a plurality of multimedia fragment information, and then the sending module 502 sends the multimedia fragment data to the requesting node based on the multimedia fragment information, and then the obtaining module 503 obtains the current data transmission duration of the multimedia fragment data in real time, and finally, when the data transmission stop command sent by the requesting node is received, or the current data transmission duration is not less than the target transmission duration, the stop execution module 504 stops executing the step of sending the multimedia fragment data to the requesting node based on the multimedia fragment information. In this embodiment, when the data transmission stop command is received, wherein the data transmission stop command is sent by the requesting node based on the target receiving duration, the multimedia fragment data that is no longer needed by the requesting node is stopped from being transmitted, thereby avoiding wasting bandwidth and effectively improving the bandwidth utilization rate of the multimedia data transmission process.

[0208] In addition, the embodiment of the present application also provides a computer device, which can be a terminal or a server. Fig.11 As shown, it shows a schematic diagram of the structure of the computer device involved in the embodiment of the present application, specifically:

[0209] The computer device may include components such as a processor 601 with one or more processing cores, a memory 602 with one or more computer-readable storage media, a power supply 603, and an input unit 604. Those skilled in the art will appreciate that Fig.11The computer device structure shown in the figure does not constitute a limitation on the computer device, and may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently. Among them:

[0210] The processor 601 is the control center of the computer device, and uses various interfaces and lines to connect various parts of the entire computer device. It executes various functions of the computer device and processes data by running or executing software programs and / or modules stored in the memory 602, and calling data stored in the memory 602. Optionally, the processor 601 may include one or more processing cores; preferably, the processor 601 may integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, user pages and application programs, etc., and the modem processor mainly processes wireless communications. It is understandable that the above-mentioned modem processor may not be integrated into the processor 601.

[0211] The memory 602 can be used to store software programs and modules. The processor 601 executes various functional applications and data processing by running the software programs and modules stored in the memory 602. The memory 602 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area may store data created according to the use of the computer device, etc. In addition, the memory 602 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other volatile solid-state storage devices. Accordingly, the memory 602 may also include a memory controller to provide the processor 601 with access to the memory 602.

[0212] The computer device also includes a power supply 603 for supplying power to various components. Preferably, the power supply 603 can be logically connected to the processor 601 through a power management system, so as to manage charging, discharging, and power consumption through the power management system. The power supply 603 can also include any components such as one or more DC or AC power supplies, recharging systems, power failure detection circuits, power converters or inverters, and power status indicators.

[0213] The computer device may further include an input unit 604, which may be used to receive input digital or character information and generate keyboard, mouse, joystick, optical or trackball signal input related to user settings and function control.

[0214] Although not shown, the computer device may further include a display unit, etc., which will not be described in detail herein. Specifically in this embodiment, the processor 601 in the computer device will load the executable files corresponding to the processes of one or more application programs into the memory 602 according to the following instructions, and the processor 601 will run the application programs stored in the memory 602, thereby realizing various functions, as follows:

[0215] Sending a data request for target multimedia data to a data node, wherein the target multimedia data includes a plurality of multimedia fragment data; receiving the multimedia fragment data returned by the data node based on the data request; when all multimedia fragment data of the target multimedia data are not received within a target receiving time, sending a data transmission stop command to the data node to make the data node stop transmitting the multimedia fragment data; and obtaining the unreceived multimedia fragment data from a content distribution server.

[0216] And, receiving a data request sent by a requesting node, the data request includes multiple multimedia fragmentation information; sending multimedia fragmentation data to the requesting node based on the multimedia fragmentation information; obtaining the current data transmission duration of the multimedia fragmentation data in real time; when a data transmission stop command sent by the requesting node is received, or the current data transmission duration is not less than the target transmission duration, stopping the step of sending multimedia fragmentation data to the requesting node based on the multimedia fragmentation information, wherein the data transmission stop command is sent by the requesting node based on the target receiving duration.

[0217] The specific implementation of the above operations can be found in the previous embodiments, which will not be described in detail here.

[0218] Those skilled in the art will appreciate that all or part of the steps in the various methods of the above embodiments may be completed by a computer program, or by controlling related hardware through a computer program. The computer program may be stored in a computer-readable storage medium and loaded and executed by a processor.

[0219] To this end, an embodiment of the present application further provides a storage medium in which a computer program is stored, and the computer program can be loaded by a processor to execute the steps in any of the multimedia data transmission methods provided in the embodiments of the present application. For example, the computer program can execute the following steps:

[0220] Sending a data request for target multimedia data to a data node, wherein the target multimedia data includes a plurality of multimedia fragment data; receiving the multimedia fragment data returned by the data node based on the data request; when all multimedia fragment data of the target multimedia data are not received within a target receiving time, sending a data transmission stop command to the data node to make the data node stop transmitting the multimedia fragment data; and obtaining the unreceived multimedia fragment data from a content distribution server.

[0221] And, receiving a data request sent by a requesting node, the data request includes multiple multimedia fragmentation information; sending multimedia fragmentation data to the requesting node based on the multimedia fragmentation information; obtaining the current data transmission duration of the multimedia fragmentation data in real time; when a data transmission stop command sent by the requesting node is received, or the current data transmission duration is not less than the target transmission duration, stopping the step of sending multimedia fragmentation data to the requesting node based on the multimedia fragmentation information, wherein the data transmission stop command is sent by the requesting node based on the target receiving duration.

[0222] The storage medium may include: a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, etc.

[0223] Since the computer program stored in the storage medium can execute the steps in any multimedia data transmission method provided in the embodiments of the present application, the beneficial effects that can be achieved by any multimedia data transmission method provided in the embodiments of the present application can be achieved. Please refer to the previous embodiments for details and will not be repeated here.

[0224] The above is a detailed introduction to a multimedia data transmission method and device provided in an embodiment of the present application. Specific examples are used in this article to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method of the present application and its core idea; at the same time, for technical personnel in this field, according to the idea of ​​the present application, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present application.

Claims

1. A multimedia data transmission method, characterized in that: Applied to the requesting node, including: Acquire duration information corresponding to target multimedia data, wherein the target multimedia data includes data that needs to be pre-downloaded by the requesting node in an online playback scenario, and the duration information represents the playback duration of the target multimedia data; The duration information is set as a target receiving duration for a point-to-point data node, and a target sending duration is set based on the target receiving duration, wherein the target sending duration is less than the target receiving duration; Sending a data request for target multimedia data to a point-to-point data node, wherein the target multimedia data includes a plurality of multimedia slice data, and the data request includes the target sending duration; Receiving multimedia slice data returned by the point-to-point data node based on the data request; Calculate the current data reception duration based on the preset duration, and perform real-time detection on the received multimedia segment data; When the current data reception duration is greater than or equal to the target reception duration for the data node and all multimedia slice data of the target multimedia data are not detected, determining that all multimedia slice data of the target multimedia data are not received within the target reception duration, and sending a data transmission stop command to the point-to-point data node to cause the point-to-point data node to stop transmitting the multimedia slice data; Acquire the unreceived multimedia segment data from the content distribution server.

2. The method according to claim 1, characterized in that The method further comprises: When sending a data request for target multimedia data to a point-to-point data node, setting the current time point as the data reception start time point; The calculating the current data receiving duration based on the preset duration includes: The current time point is obtained based on the preset duration, and the difference between the current time point and the data reception start time point is calculated to obtain the current data reception duration.

3. A multimedia data transmission method, characterized in that: Applicable to peer-to-peer data nodes, including: Receive a data request sent by a requesting node, the data request including information of multiple multimedia segments and a target sending duration, the target sending duration is determined based on a target receiving duration, the target receiving duration is duration information of target multimedia data to be transmitted at the requesting node, the target multimedia data includes data that the requesting node needs to pre-download in an online playback scenario, and the duration information represents the playback duration of the target multimedia data; Sending multimedia slice data to the requesting node based on the multimedia slice information; Obtain the current data sending duration of multimedia segment data in real time; When a data transmission stop command is received from the requesting node, or the current data transmission duration is not less than the target transmission duration, the step of sending multimedia fragment data to the requesting node based on the multimedia fragment information is stopped, wherein the data transmission stop command is sent by the requesting node based on the target receiving duration.

4. The method according to claim 3, characterized in that: After receiving the data request sent by the requesting node, the method further includes: The data request is parsed to obtain target sending duration and multiple multimedia segment information.

5. The method according to claim 4, characterized in that After receiving the data request sent by the requesting node, the method further includes: When a data request sent by a requesting node is received, a target sending duration for multimedia data transmission is generated based on the data request.

6. A multimedia data transmission device, characterized in that: Applied to the requesting node, including: A determination module is used to obtain duration information corresponding to target multimedia data, wherein the target multimedia data includes data that the requesting node needs to pre-download in an online playback scenario, and the duration information represents the playback duration of the target multimedia data; set the duration information as a target reception duration for a point-to-point data node, and set a target sending duration based on the target reception duration, wherein the target sending duration is less than the target reception duration; A first sending module, configured to send a data request for target multimedia data to a point-to-point data node, wherein the target multimedia data includes a plurality of multimedia slice data, and the data request includes the target sending duration; A receiving module, configured to receive multimedia slice data returned by the point-to-point data node based on the data request; A second sending module is used to calculate the current data reception duration based on a preset duration, and to perform real-time detection on the received multimedia slice data; when the current data reception duration is greater than or equal to the target reception duration for the data node, and all multimedia slice data of the target multimedia data are not detected, it is determined that all multimedia slice data of the target multimedia data are not received within the target reception duration, and a data transmission stop command is sent to the point-to-point data node to stop the point-to-point data node from transmitting the multimedia slice data; The acquisition module is used to acquire the unreceived multimedia segment data from the content distribution server.

7. A multimedia data transmission device, characterized in that: Applicable to peer-to-peer data nodes, including: A receiving module, configured to receive a data request sent by a requesting node, wherein the data request includes information of multiple multimedia segments and a target sending duration, wherein the target sending duration is determined based on a target receiving duration, wherein the target receiving duration is duration information of target multimedia data to be transmitted, wherein the target multimedia data includes data that the requesting node needs to pre-download in an online playback scenario, and wherein the duration information represents a playback duration of the target multimedia data; A sending module, configured to send multimedia slice data to the requesting node based on the multimedia slice information; An acquisition module is used to acquire the current data transmission duration of multimedia segment data in real time; A stop execution module is used to stop executing the step of sending multimedia fragment data to the requesting node based on the multimedia fragment information when a data transmission stop command sent by the requesting node is received, or the current data sending duration is not less than the target sending duration, wherein the data transmission stop command is sent by the requesting node based on the target receiving duration.

8. A storage medium storing a computer program, wherein the computer program is suitable for being loaded by a processor to execute the multimedia data transmission method according to any one of claims 1 to 5.

9. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the computer program, the multimedia data transmission method according to any one of claims 1 to 5 is implemented.