CN105306424B - A kind of flow-medium transmission method, Streaming Media sending device and stream media transmission system - Google Patents

A kind of flow-medium transmission method, Streaming Media sending device and stream media transmission system Download PDF

Info

Publication number
CN105306424B
CN105306424B CN201410322938.5A CN201410322938A CN105306424B CN 105306424 B CN105306424 B CN 105306424B CN 201410322938 A CN201410322938 A CN 201410322938A CN 105306424 B CN105306424 B CN 105306424B
Authority
CN
China
Prior art keywords
streaming media
transmission
reception device
stream
bit rate
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201410322938.5A
Other languages
Chinese (zh)
Other versions
CN105306424A (en
Inventor
何春晓
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tencent Technology Shenzhen Co Ltd
Tencent Cloud Computing Beijing Co Ltd
Original Assignee
Tencent Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201410322938.5A priority Critical patent/CN105306424B/en
Publication of CN105306424A publication Critical patent/CN105306424A/en
Application granted granted Critical
Publication of CN105306424B publication Critical patent/CN105306424B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

The embodiment of the invention discloses a kind of flow-medium transmission methods, which comprises the streaming media request that Streaming Media sending device is sent according to Streaming Media reception device transmits stream medium data to the Streaming Media reception device with the first transmission stream bit rate;The transmission state information of the Streaming Media reception device is obtained using first time interval as the period, the transmission state information includes the transmission rate reference information and/or transmission stability reference information of Streaming Media reception device;According to the transmission state information of the Streaming Media reception device stream bit rate will be transmitted for second from the first transport stream code rate adjustment to the real-time Transmission stream bit rate of Streaming Media reception device transmission stream medium data.The embodiment of the invention also discloses a kind of Streaming Media sending device and stream media transmission systems.Using the present invention, the transmission of streaming media self-adapting code rate can be realized in Streaming Media transmitting terminal.

Description

A kind of flow-medium transmission method, Streaming Media sending device and stream media transmission system
Technical field
The present invention relates to Internet technical field more particularly to a kind of flow-medium transmission method, Streaming Media sending device and Stream media transmission system.
Background technique
Streaming Media refers to the media formats that play out in internet by the way of stream transmission, as audio, video or Multimedia file.The key technology that Streaming Media is realized is exactly to transmit as a stream, stream transmission refer mainly to entire audio and video and The multimedia files such as three-dimensional media are parsed into compressed package one by one by specific compress mode, from Streaming Media sending device to stream Media receiving apparatus transmission, Streaming Media reception device wait until that entire file is all downloaded not necessarily like using traditional mode of down load like that Finish, but only need to by seconds or tens of seconds start-up study can side broadcast below.
In the prior art, Streaming Media sending device can be transmitted by different transmission stream bit rates to Streaming Media reception device Stream medium data can bring better result of broadcast using higher transmission stream bit rate, but when network bandwidth is insufficient or network Will lead to broadcasting interruption or prolonged buffering, existing Streaming Media reception device when unstable can need to select by user Different transmission stream bit rates uses always the transmission stream bit rate to obtain Streaming Media number from Streaming Media sending device in follow-up play According to, but the transmission stream bit rate of user's selection is not many times preferred plan, and when Network status changes, before The transmission stream bit rate of selection is likely to mismatch with current network state.
Summary of the invention
The technical problem to be solved by the embodiment of the invention is that providing a kind of flow-medium transmission method, Streaming Media is sent Device and stream media transmission system can carry out dynamic code rate switching in Streaming Media sending device, realize streaming media self-adapting code rate Transmission.
In order to solve the above-mentioned technical problem, the embodiment of the invention provides a kind of flow-medium transmission method, the method packets It includes:
Streaming Media sending device is according to the streaming media request that Streaming Media reception device is sent with the first transmission stream bit rate Stream medium data is transmitted to the Streaming Media reception device;
The transmission state information of the Streaming Media reception device, the transmission state are obtained using first time interval as the period Information includes the transmission rate reference information and/or transmission stability reference information of Streaming Media reception device;
According to the transmission state information of the Streaming Media reception device Streaming Media will be transmitted to the Streaming Media reception device The real-time Transmission stream bit rate of data transmits stream bit rate from the first transport stream code rate adjustment for second.
Correspondingly, the embodiment of the invention also provides a kind of Streaming Media sending device, the Streaming Media sending device includes:
Streaming media module, the streaming media for being sent according to Streaming Media reception device are requested with the first transport stream Code rate transmits stream medium data to the Streaming Media reception device;
Transmission state obtains module, for obtaining the transmission of the Streaming Media reception device using first time interval as the period Status information, the transmission state information include the transmission rate reference information of the Streaming Media reception device and/or transmit steady Qualitative reference information;
Real-time code rate adjustment module, for will be to the stream matchmaker according to the transmission state information of the Streaming Media reception device The real-time Transmission stream bit rate that body reception device transmits stream medium data transmits stream bit rate from the first transport stream code rate adjustment for second.
Correspondingly, the embodiment of the invention also discloses a kind of stream media transmission system, including Streaming Media as previously described Sending device and at least one Streaming Media reception device, in which:
The Streaming Media reception device is used to send streaming media to the Streaming Media sending device and request, described in reception The stream medium data that Streaming Media sending device is transmitted according to streaming media request;
The streaming media request that the Streaming Media sending device is used to be sent according to Streaming Media reception device is passed with first Defeated stream bit rate transmits stream medium data to the Streaming Media reception device;The Streaming Media is obtained by the period of first time interval The transmission state information of reception device, the transmission state information include the transmission rate of the Streaming Media reception device with reference to letter Breath and/or transmission stability reference information;It will be to the Streaming Media according to the transmission state information of the Streaming Media reception device The real-time Transmission stream bit rate that reception device transmits stream medium data transmits stream bit rate from the first transport stream code rate adjustment for second.
The present embodiment is by periodically obtaining the stream during transmitting stream medium data to Streaming Media reception device The transmission state information of media receiving apparatus, to determine transmission Streaming Media according to the transmission state information of Streaming Media reception device The real-time Transmission stream bit rate of data realizes the transmission of streaming media self-adapting code rate in Streaming Media transmitting terminal.
Detailed description of the invention
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, to embodiment or will show below There is attached drawing needed in technical description to be briefly described, it should be apparent that, the accompanying drawings in the following description is only this Some embodiments of invention for those of ordinary skill in the art without creative efforts, can be with It obtains other drawings based on these drawings.
Fig. 1 is the flow diagram of one of embodiment of the present invention flow-medium transmission method;
Fig. 2 is the flow diagram of the flow-medium transmission method in another embodiment of the present invention;
Fig. 3 is the flow diagram of the flow-medium transmission method in another embodiment of the present invention;
Fig. 4 is the flow diagram of the flow-medium transmission method in further embodiment of this invention;
Fig. 5 is the structural schematic diagram of one of embodiment of the present invention Streaming Media sending device;
Fig. 6 is the structural schematic diagram of the Streaming Media sending device in another embodiment of the present invention;
Fig. 7 is the structural schematic diagram of one of embodiment of the present invention stream media transmission system.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete Site preparation description, it is clear that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.It is based on Embodiment in the present invention, it is obtained by those of ordinary skill in the art without making creative efforts every other Embodiment shall fall within the protection scope of the present invention.
Streaming media as mentioned in the embodiments of the present invention, can for streaming media video data, streamed audio data or The transmission of other Streaming Media categorical datas, the corresponding Streaming Media sending device can be video server, audio server Or the Streaming Medias sending device such as audio-video conversation server, or the device end with Streaming Media reception device equity, institute Data communication can be carried out by internet and the Streaming Media sending device by stating Streaming Media reception device, and can be with streaming media The stream medium data that sending device transmission comes plays out, and the Streaming Media reception device may include PC, intelligent hand Machine (such as Android phone, iOS mobile phone), tablet computer, palm PC, mobile internet device (MID, Mobile Internet Devices) or the internet devices such as wearable intelligent equipment.
Fig. 1 is the flow diagram of one of embodiment of the present invention flow-medium transmission method, the present embodiment as shown in the figure In flow-medium transmission method may include:
S101, the streaming media that Streaming Media sending device is sent according to Streaming Media reception device are requested with the first transport stream Code rate transmits stream medium data to the Streaming Media reception device.
Such as the target video that Streaming Media reception device selects in internet according to user, it is sent out to Streaming Media sending device The streaming media for target video is sent to request, at this moment Streaming Media sending device can be requested according to the streaming media The stream medium data of the target video is transmitted to Streaming Media reception device with certain real-time Transmission stream bit rate.Specific implementation In, Streaming Media sending device, can be first using preset when receiving the transmission streaming media request of Streaming Media reception device First transmission stream bit rate transmits stream medium data to the Streaming Media reception device, subsequent to receive the Streaming Media again and connect When the streaming media request that receiving apparatus is sent, real-time transmission stream code described in dynamic regulation is carried out by step S102~S104 Rate.In an alternative embodiment, Streaming Media sending device also can decide whether to receive Streaming Media reception device transmission for the first time Streaming media request, if so, preset transmission stream bit rate can be used to the Streaming Media reception device transport stream matchmaker Volume data, if not receive the streaming media request of Streaming Media reception device transmission for the first time, then it can be according to Streaming Media When the forward direction of the sending device Streaming Media reception device transmits stream medium data, the transmission state information of the Streaming Media reception device Determine current real-time Transmission stream bit rate, and then by determining obtained real-time Transmission stream bit rate to the Streaming Media reception device Transmit stream medium data.It should be pointed out that the Streaming Media for receiving Streaming Media reception device transmission for the first time described herein Transmission request, the streaming media for the first time that can be Streaming Media reception device for some target files in stream media are requested.
S102 obtains the transmission state information of the Streaming Media reception device using first time interval as the period.
Specifically, the transmission state information of the Streaming Media reception device may include the biography of the Streaming Media reception device Defeated rate reference information and/or transmission stability reference information, wherein the transmission rate reference information can be in preset time Mean Speed of the Streaming Media sending device to Streaming Media reception device transmission stream medium data in section, or Streaming Media The current instantaneous transmission rate of reception device or the transmission rate of some sampling instant before, the transmission stability reference information It may include the rate that Streaming Media sending device transmits stream medium data to the Streaming Media reception device within a preset period of time Variance.The Streaming Media sending device is during transmitting stream medium data to the Streaming Media reception device at the first time Between be divided into the transmission state information that the period obtains the Streaming Media reception device, the above-mentioned biography to calculate Streaming Media reception device The preset time period of defeated rate reference information or transmission stability reference information, can be identical as the duration of first time interval, It can also be different.
S103, will be to the Streaming Media reception device transport stream according to the transmission state information of the Streaming Media reception device The real-time Transmission stream bit rate of media data transmits stream bit rate from the first transport stream code rate adjustment for second.
In the specific implementation, the Streaming Media sending device can be between preset transmission state information and transmission stream bit rate Mapping relations can be in preset transmission state after the transmission state information that S102 gets the Streaming Media reception device It is searched in mapping relations between information and transmission stream bit rate and obtains the transmission state information pair with the Streaming Media reception device The the second transmission stream bit rate answered.
And in an alternative embodiment, Streaming Media sending device can be believed according to the transmission state of the Streaming Media reception device Breath determines the current transmission state parameter of the Streaming Media reception device, and the transmission state parameter is by value=α * Transmission_speed+ β * transmission_speed_variances is determining, wherein transmission_speed The Mean Speed of stream medium data is transmitted to the Streaming Media reception device for Streaming Media sending device in preset time period, Transmission_speed_variances be in preset time period Streaming Media sending device to the Streaming Media reception device The rate variance of stream medium data is transmitted, α and β are respectively default weighted factor;And then according to preset transmission state parameter with The mapping relations between stream bit rate are transmitted, determine the second transmission corresponding with the transmission state information of the Streaming Media reception device Stream bit rate.In a preferred embodiment, α > β, i.e. transmission rate are the primary reference point of transmission state information.
And then in an alternative embodiment, the Streaming Media sending device, which may determine that, transmits when preceding to Streaming Media reception device The real-time Transmission stream bit rate of stream medium data whether and it is described corresponding with the transmission state information of the Streaming Media reception device Second transmission stream bit rate is identical, if the two is same transmission stream bit rate, continues to use current real-time Transmission stream bit rate to stream matchmaker Body reception device transmits stream medium data and uses the transmission state information with the Streaming Media reception device if the two is different Corresponding second transmission stream bit rate transmits stream medium data to the Streaming Media reception device.In an alternative embodiment, Streaming Media Sending device can receive after the stream medium data piece (i.e. TS file piece) after will currently transmit using with the Streaming Media The corresponding second transmission stream bit rate of the transmission state information of device transmits next TS file piece to the Streaming Media reception device, Such as target video file includes 100 TS file pieces, Streaming Media sending device transmits the 50th TS with the first transmission stream bit rate When file piece according to the transmission state information of the Streaming Media reception device by real-time transmission stream code rate adjustment be the second transport stream Code rate, then the subsequently received Streaming Media reception device send for the 51st TS file piece (or other TS files Piece) streaming media request when, can according to it is described second transmission stream bit rate to the Streaming Media reception device transmission be asked The TS file piece asked.
The present embodiment is by periodically obtaining the stream during transmitting stream medium data to Streaming Media reception device The transmission state information of media receiving apparatus, to adjust transmission Streaming Media according to the transmission state information of Streaming Media reception device The real-time Transmission stream bit rate of data realizes the transmission of streaming media self-adapting code rate in Streaming Media transmitting terminal.
Fig. 2 is the flow diagram of the flow-medium transmission method in another embodiment of the present invention, the present embodiment as shown in the figure In flow-medium transmission method may include:
S201, the streaming media that Streaming Media sending device is sent according to Streaming Media reception device are requested with the first transport stream Code rate transmits stream medium data to the Streaming Media reception device.
Such as the target video that Streaming Media reception device selects in internet according to user, it is sent out to Streaming Media sending device The streaming media for target video is sent to request, at this moment Streaming Media sending device can be requested according to the streaming media The stream medium data of the target video is transmitted to Streaming Media reception device.In the specific implementation, Streaming Media sending device is receiving When sending streaming media request to Streaming Media reception device, can first it be connect using preset transmission stream bit rate to the Streaming Media Receiving apparatus transmits stream medium data, the subsequent streaming media request that ought be received the Streaming Media reception device again and send When, dynamic regulation real-time Transmission stream bit rate is carried out by step S102~S104.In an alternative embodiment, Streaming Media sending device Also it can decide whether the streaming media request for receiving Streaming Media reception device transmission for the first time, if so, can be used Preset transmission stream bit rate transmits stream medium data to the Streaming Media reception device, connects if not receiving the Streaming Media for the first time The streaming media request that receiving apparatus is sent, then can transmit according to the forward direction of the Streaming Media sending device Streaming Media reception device When stream medium data, the transmission state information of the Streaming Media reception device determines current real-time Transmission stream bit rate, and then passes through Determine that obtained real-time Transmission stream bit rate transmits stream medium data to the Streaming Media reception device.It should be pointed out that here The streaming media request for receiving Streaming Media reception device transmission for the first time referred to, can be Streaming Media reception device and is directed to The streaming media for the first time of some target files in stream media is requested.
S202, the Streaming Media sending device obtain the load state information of itself using the second time interval as the period.
Specifically, the load state information may include the flow load information of the Streaming Media sending device, processing Device load information and input and output I/O load information are any one or more of, wherein the flow of the Streaming Media sending device Load information includes Streaming Media sending device current bandwidth utilization (such as curr_flux current server flow/eth0_ Flux network interface card flow rate upper limit) and/or the Streaming Media sending device locating for computer room bandwidth availability ratio (such as curr_dc_flux is current Computer room flow/total_dc_flux computer room upper limit flow), the processor load information includes the Streaming Media sending device Current cpu busy percentage, the input and output I/O load information include the current I/O utilization rate of the Streaming Media sending device, It should be pointed out that above-mentioned utilization rate parameter can be instantaneous value, or the statistical value in preset time period.The stream matchmaker Body sending device obtains during transmitting stream medium data to the Streaming Media reception device using the second time interval as the period It is derived from the load state information of body, the above-mentioned preset time to calculate the load state information of Streaming Media sending device itself Section, can be identical as the duration of the second time interval, can also be different.
S203 will transmit the real-time Transmission stream bit rate of stream medium data according to load state information to Streaming Media reception device It is the second transmission stream bit rate from the first transport stream code rate adjustment.
In the specific implementation, if the Streaming Media sending device determines that itself is in high load according to the load state information State can then reduce the real-time Transmission stream bit rate, i.e., the second transmission stream bit rate is less than the first transmission stream bit rate.In this implementation In example, the real-time Transmission stream bit rate can be for Streaming Media sending device currently or will be to the Streaming Media reception device Transmit the transmission stream bit rate of stream medium data, next (group) transmitted such as Streaming Media sending device to the Streaming Media reception device The transmission stream bit rate of TS file piece, for concrete example, if target video file includes 100 TS file pieces, Streaming Media is sent The real-time Transmission stream bit rate that device is used when transmitting the 50th TS file piece is 80kbps, and then gets institute according to S202 It states load state information and determines that itself is in high load condition, then can reduce real-time Transmission stream bit rate to the second transport stream code Rate, for example, 60kbps, then the subsequently received Streaming Media reception device send for the 51st TS file piece (or Other TS file pieces) streaming media request when, can be according to the real-time Transmission stream bit rate of the determination to the Streaming Media Reception device transmits requested TS file piece.
In an alternative embodiment, when the current bandwidth availability ratio of the Streaming Media sending device, locating computer room bandwidth usage When rate, cpu busy percentage or I/O utilization rate reach corresponding default load-threshold, the real-time Transmission stream bit rate can be reduced.On Stating the corresponding load-threshold of four kinds of utilization rate parameters can be identical numerical value, can also be different, the load of for example, identical numerical value Thresholding, when the current bandwidth availability ratio of the Streaming Media sending device, locating computer room bandwidth availability ratio, cpu busy percentage or I/O benefit Reach 90% with any one numerical value in rate, then can reduce the real-time Transmission stream bit rate.
And then in an alternative embodiment, the Streaming Media sending device can be adjusted current according to the load state information It is receiving and is partly or entirely being flowed in all Streaming Media reception devices of the stream medium data of the Streaming Media sending device transmission The real-time Transmission stream bit rate of media receiving apparatus.Such as it is determined according to the load state information and itself is currently at high load shape State, then can reduce the real-time Transmission stream bit rate of transmission of flow media data task currently transmitted, such as by all tasks The real-time transmission stream code rate of a rank is all lowered, in an alternative embodiment, can also only reduce and use higher real-time Transmission The real-time Transmission stream bit rate of the Streaming Media reception device of stream bit rate such as transmits stream bit rate and is divided into three high speed, middling speed and low speed grades It not, can be by the real-time transmission stream code rate adjustment of all Streaming Media reception devices for using high speed real-time Transmission stream bit rate for middling speed Real-time Transmission stream bit rate.
Streaming Media sending device passes through week during transmitting stream medium data to Streaming Media reception device in the present embodiment The load state information of the acquisition Streaming Media sending device itself of phase property, to adjust transport stream according to load state information The real-time Transmission stream bit rate of media data realizes flexible transfer strategy in Streaming Media transmitting terminal, and invention Streaming Media is avoided to send The system overload of device.
Fig. 3 is the flow diagram of the flow-medium transmission method in another embodiment of the present invention, and the present embodiment is based on stream The angle of media transmission device and Streaming Media reception device describes flow-medium transmission method, as shown in the figure may include to flow down Journey:
S301, Streaming Media reception device send streaming media request to Streaming Media sending device.Such as Streaming Media receives The target video that device selects in internet according to user sends the Streaming Media for being directed to target video to Streaming Media sending device Transmission request.
S302, Streaming Media sending device transmit stream medium data to the Streaming Media reception device.
In the specific implementation, Streaming Media sending device receive Streaming Media reception device send streaming media request when, Stream medium data, the first transmission stream bit rate first can be transmitted to the Streaming Media reception device using the first transmission stream bit rate It can be preset transmission stream bit rate, the subsequent streaming media that ought be received the Streaming Media reception device again and send When request, dynamic regulation real-time Transmission stream bit rate is carried out by step S303~S306.In an alternative embodiment, Streaming Media is sent Device also can decide whether to receive the streaming media request of Streaming Media reception device transmission for the first time, if so, can be with Stream medium data is transmitted to the Streaming Media reception device using preset transmission stream bit rate, if not receiving stream matchmaker for the first time The streaming media request that body reception device is sent, then can be according to the forward direction of the Streaming Media sending device Streaming Media reception device When transmitting stream medium data, the transmission state information of the Streaming Media reception device determines current real-time Transmission stream bit rate, in turn By determining that obtained real-time Transmission stream bit rate transmits stream medium data to the Streaming Media reception device.It should be pointed out that The streaming media request for receiving Streaming Media reception device transmission for the first time described herein, can be Streaming Media reception device For the request of streaming media for the first time of some target files in stream media.
S303, the Streaming Media sending device obtain the biography of the Streaming Media reception device using first time interval as the period Defeated status information.
Specifically, the transmission state information of the Streaming Media reception device may include the biography of the Streaming Media reception device Defeated rate reference information and/or transmission stability reference information, wherein the transmission rate reference information can be in preset time Mean Speed of the Streaming Media sending device to Streaming Media reception device transmission stream medium data in section, or Streaming Media The current instantaneous transmission rate of reception device or the transmission rate of some sampling instant before also may include that the transmission is stablized Property reference information may include within a preset period of time Streaming Media sending device to the Streaming Media reception device transmit Streaming Media The rate variance of data.The Streaming Media sending device is during transmitting stream medium data to the Streaming Media reception device The transmission state information of the Streaming Media reception device is obtained using first time interval as the period, it is above-mentioned to be connect to calculate Streaming Media The transmission rate reference information of receiving apparatus or the preset time period of transmission stability reference information, can be with first time interval Duration is identical, can also be different.
S304, the Streaming Media sending device are adjusted according to the transmission state information of the Streaming Media reception device and are passed in real time Defeated stream bit rate.
In the specific implementation, the Streaming Media sending device can be between preset transmission state information and transmission stream bit rate Mapping relations can be in preset transmission state after the transmission state information that S303 gets the Streaming Media reception device It is searched in mapping relations between information and transmission stream bit rate corresponding with the transmission state information of the Streaming Media reception device Second transmission stream bit rate, thus by making from S302 to the real-time Transmission stream bit rate of Streaming Media reception device transmission stream medium data First transport stream code rate adjustment is the second transmission stream bit rate.
S305, the Streaming Media sending device obtain the load state information of itself using the second time interval as the period.
Specifically, second time interval interval can be identical as first time interval, can also be different.The load Status information may include the flow load information, processor load information and input and output I/O of the Streaming Media sending device Load information is any one or more of, wherein the flow load information of the Streaming Media sending device includes the Streaming Media hair Send device current bandwidth utilization (such as curr_flux current server flow/eth0_flux network interface card flow rate upper limit) and/or institute State (the current computer room flow/total_dc_flux machine of such as curr_dc_flux of computer room bandwidth availability ratio locating for Streaming Media sending device Room upper limit flow), the processor load information includes the current cpu busy percentage of the Streaming Media sending device, the input Exporting I/O load information includes the current I/O utilization rate of the Streaming Media sending device, it should be pointed out that above-mentioned utilization rate Parameter can be instantaneous value, or the statistical value in preset time period.The Streaming Media sending device is to the stream matchmaker The load state information of itself is obtained during body reception device transmission stream medium data using the second time interval as the period, on The preset time period to the transmission rate reference information or transmission stability reference information that calculate Streaming Media reception device is stated, it can With identical as the duration of the second time interval, can also be different.
S306, the Streaming Media sending device adjust the real-time Transmission stream bit rate according to the load state information.Tool It, can if the Streaming Media sending device determines that itself is in high load condition according to the load state information during body is realized To reduce the real-time Transmission stream bit rate.Real-time Transmission stream bit rate described in the present embodiment can be current for Streaming Media sending device It or will be to the transmission stream bit rate of Streaming Media reception device transmission stream medium data.
In the present embodiment, when the current bandwidth availability ratio of the Streaming Media sending device, locating computer room bandwidth availability ratio, When cpu busy percentage or I/O utilization rate reach corresponding default load-threshold, the real-time Transmission stream bit rate can be reduced.It is above-mentioned The corresponding load-threshold of four kinds of utilization rate parameters can be identical numerical value, can also be different, the load door of for example, identical numerical value Limit, when the current bandwidth availability ratio of the Streaming Media sending device, locating computer room bandwidth availability ratio, cpu busy percentage or I/O are utilized Any one numerical value in rate reaches 90%, then can reduce the real-time Transmission stream bit rate.
S307, the Streaming Media sending device receive the streaming media request that the Streaming Media reception device is sent.
The streaming media request that the Streaming Media reception device is sent is received again, and streaming media request can To be directed to same files in stream media with the streaming media request received in S301, that is, belong to same target Streaming Media text The different TS file pieces of part, what it is such as S301 request is the 1st TS file piece, and S307 request is the 5th TS file piece;Optional In embodiment, what the streaming media request that S307 is got can also be directed to the streaming media request received in S301 Be different files in stream media, if receive the Streaming Media reception device this send streaming media request before once connect The streaming media for other files in stream media for receiving Streaming Media reception device transmission is requested, and execution can also can be passed through Process in the present embodiment is to adjust the real-time Transmission stream bit rate to the Streaming Media reception device.
S308, the Streaming Media sending device is according to the real-time Transmission stream bit rate after adjusting to the Streaming Media reception device Transmit stream medium data.
Streaming Media sending device passes through week during transmitting stream medium data to Streaming Media reception device in the present embodiment The transmission state information of the acquisition Streaming Media reception device of phase property and the load condition of the Streaming Media sending device itself Information, so as to according to the real-time transmission stream of transmission state information and load state information dynamic regulation transmission stream medium data Code rate realizes the transmission of streaming media self-adapting code rate and flexible transfer strategy in Streaming Media transmitting terminal, invention Streaming Media is avoided to send out Send the system overload of device.
Fig. 4 is the flow diagram of the flow-medium transmission method in further embodiment of this invention, the present embodiment as shown in the figure In flow-medium transmission method process may include:
S401, Streaming Media sending device are requested according to the streaming media that Streaming Media reception device is sent to the Streaming Media Reception device transmits stream medium data.Streaming Media sending device can be set in this step to the Streaming Media reception device transport stream The real-time Transmission stream bit rate of media data is the first transmission stream bit rate.
S402, the Streaming Media sending device obtain the transmission state of the playback terminal using first time interval as the period Information.
In the present embodiment, the transmission state information of the Streaming Media reception device may include the Streaming Media reception device Transmission rate reference information and transmission stability reference information, wherein the transmission rate reference information be in preset time period Mean Speed of the interior Streaming Media sending device to Streaming Media reception device transmission stream medium data, the transmission stability ginseng Stream medium data can be transmitted to the Streaming Media reception device for Streaming Media sending device within a preset period of time by examining information Rate variance.The Streaming Media sending device is during transmitting stream medium data to the Streaming Media reception device with first Time interval is the transmission state information for obtaining the Streaming Media reception device in the period, above-mentioned to calculate Streaming Media reception device Transmission rate reference information or transmission stability reference information preset time period, can be with the when appearance of first time interval Together, it can also be different.
S403, the Streaming Media sending device determine corresponding with the transmission state information of the Streaming Media reception device the Two transmission stream bit rates.
In the present embodiment, Streaming Media sending device can be determined according to the transmission state information of the Streaming Media reception device The current transmission state parameter of the Streaming Media reception device, the transmission state parameter is by value=α * transmission_ Speed+ β * transmission_speed_variances determines that wherein transmission_speed is in preset time period Mean Speed of the Streaming Media sending device to Streaming Media reception device transmission stream medium data, transmission_ Speed_variances transmits stream medium data to the Streaming Media reception device for Streaming Media sending device in preset time period Rate variance, α and β are respectively default weighted factor;And then according between preset transmission state parameter and transmission stream bit rate Mapping relations, determine it is corresponding with the transmission state parameter of the Streaming Media reception device second transmit stream bit rate.In this choosing In embodiment, α > β, i.e. transmission rate are the primary reference point of transmission state information.The Streaming Media sending device is to institute The Streaming Media is obtained as the period using first time interval during stating Streaming Media reception device transmission stream medium data to receive The transmission state information of device, above-mentioned transmission rate reference information or transmission stability ginseng to calculate Streaming Media reception device The preset time period of information is examined, can be identical as the duration of first time interval, it can also be different.
S404 judges whether the second transmission stream bit rate is different from current transmission stream bit rate, if the determination result is YES S407 can be then executed, S408 otherwise can be executed, is i.e. S403 determines that the second obtained transmission stream bit rate and Streaming Media send and fill It sets that currently employed transmission stream bit rate is identical, then current real-time Transmission stream bit rate is maintained to transmit to the Streaming Media reception device Stream medium data, it is not identical, the real-time Transmission stream bit rate is adjusted, according to the real-time Transmission stream bit rate after adjusting to the stream Media receiving apparatus transmits stream medium data.
S405, the Streaming Media sending device obtain the load state information of itself using the second time interval as the period.
Specifically, the load state information may include the flow load information of the Streaming Media sending device, processing Device load information and input and output I/O load information are any one or more of, wherein the flow of the Streaming Media sending device Load information includes Streaming Media sending device current bandwidth utilization (such as curr_flux current server flow/eth0_ Flux network interface card flow rate upper limit) and/or the Streaming Media sending device locating for computer room bandwidth availability ratio (such as curr_dc_flux is current Computer room flow/total_dc_flux computer room upper limit flow), the processor load information includes the Streaming Media sending device Current cpu busy percentage, the input and output I/O load information include the current I/O utilization rate of the Streaming Media sending device, It should be pointed out that above-mentioned utilization rate parameter can be instantaneous value, or the statistical value in preset time period.The stream matchmaker Body sending device obtains during transmitting stream medium data to the Streaming Media reception device using the second time interval as the period It is derived from the load state information of body, the above-mentioned preset time to calculate the load state information of Streaming Media sending device itself Section, can be identical as the duration of the second time interval, can also be different.And second time interval can be between first time Every identical, execution can be synchronized or be spaced execution, different interval times can also be taken.
S406 judges whether itself is in high load condition according to load state information.
In the specific implementation, if the Streaming Media sending device determines that itself is in high load according to the load state information State can then execute S407, otherwise execute S408.In the present embodiment, the bandwidth current when the Streaming Media sending device When utilization rate, locating computer room bandwidth availability ratio, cpu busy percentage or I/O utilization rate reach corresponding default load-threshold, it can drop The low real-time Transmission stream bit rate.The corresponding load-threshold of above-mentioned four kinds of utilization rate parameters can be identical numerical value, can also not Together, the load-threshold of for example, identical numerical value, when the current bandwidth availability ratio of the Streaming Media sending device, locating computer room bandwidth Any one numerical value in utilization rate, cpu busy percentage or I/O utilization rate reaches 90%, then can execute S407.
Specifically, second time interval interval can be identical as first time interval, can also be different, S402~ S404 and S405~S406 can also execute S402 in an alternative embodiment for mutually indepedent parallel step every time S405~S406 is executed again after~S404.
S407 adjusts the real-time Transmission stream bit rate, is connect according to the real-time Transmission stream bit rate after adjusting to the Streaming Media Receiving apparatus transmits stream medium data.
Specifically, S403 can be used according to the transmission state information of the Streaming Media reception device in Streaming Media sending device Determine that obtain corresponding with the transmission state information of the Streaming Media reception device second transmits stream bit rate to the Streaming Media Reception device transmits stream medium data, judges that Streaming Media sending device is in high load condition according to load state information in S406 When, the transport stream code for next (group) TS file piece that Streaming Media sending device is transmitted to the Streaming Media reception device can be reduced Rate.If Streaming Media sending device using transmission stream bit rate is 80kbps when transmitting the 50th TS file piece, and then basis S202 gets the load state information and determines that itself is in high load condition, then can reduce real-time Transmission stream bit rate, example Such as be reduced to 60kbps, then the subsequently received Streaming Media reception device send for the 51st TS file piece (or Other TS file pieces) streaming media request when, can be according to the real-time Transmission stream bit rate of the determination to the Streaming Media Reception device transmits requested TS file piece.It in an alternative embodiment can also reduce and all or part of currently to transmit The real-time Transmission stream bit rate of transmission of flow media data task, such as all tasks are all lowered to the real-time transmission stream code an of rank Rate can also only reduce the transmission of flow media data task using higher real-time Transmission stream bit rate, such as in an alternative embodiment Transmission stream bit rate is divided into three high speed, middling speed and low speed ranks, can be by all stream matchmakers using high speed real-time Transmission stream bit rate The real-time transmission stream code rate adjustment of body reception device is the real-time Transmission stream bit rate of middling speed.
And then in an alternative embodiment, if currently needing to reduce the real-time Transmission according to according to load state information judgement Stream bit rate, and determined obtained real-time Transmission stream bit rate ratio when preceding to the stream according to the transmission state information of Streaming Media reception device The transmission stream bit rate that media receiving apparatus transmission stream medium data uses wants high, at this moment can not use temporarily and be connect according to Streaming Media The transmission state information of receiving apparatus determines that the obtain second transmission stream bit rate carries out transmission stream medium data, i.e., do not improve temporarily to The real-time Transmission stream bit rate of Streaming Media reception device transmission stream medium data can temporarily reduce the real-time transmission stream code Rate to be currently not high load condition according to the judgement of the load state information of Streaming Media sending device, then is improved to stream matchmaker The transmission stream bit rate of body reception device transmission stream medium data.
S408 maintains current real-time Transmission stream bit rate to transmit stream medium data to the Streaming Media reception device.
Streaming Media sending device passes through week during transmitting stream medium data to Streaming Media reception device in the present embodiment The transmission state information of the acquisition Streaming Media reception device of phase property and the load condition of the Streaming Media sending device itself Information, so as to according to the real-time transmission stream of transmission state information and load state information dynamic regulation transmission stream medium data Code rate realizes the transmission of streaming media self-adapting code rate and flexible transfer strategy in Streaming Media transmitting terminal, invention Streaming Media is avoided to send out Send the system overload of device.
Fig. 5 is the structural schematic diagram of one of embodiment of the present invention Streaming Media sending device, in the embodiment of the present invention Streaming Media sending device can be the Streaming Medias sending devices such as video server, audio server or audio-video conversation server, Or the device end with Streaming Media reception device equity, it such as may include PC, smart phone (such as Android Mobile phone, iOS mobile phone etc.), tablet computer, palm PC, the internets such as mobile internet device (MID) or wearable intelligent equipment Equipment.The Streaming Media sending device in the embodiment of the present invention at least may include: as shown in the figure
Streaming media module 510, the streaming media request for being sent according to Streaming Media reception device are passed with first Defeated stream bit rate transmits stream medium data to the Streaming Media reception device.
Such as the target video that Streaming Media reception device selects in internet according to user, it is sent out to Streaming Media sending device The streaming media for target video is sent to request, at this moment streaming media module 510 can be according to the streaming media The stream medium data of the target video is transmitted in request with certain real-time Transmission stream bit rate to Streaming Media reception device.It is specific real In existing, Streaming Media sending device, can be first using default when receiving the transmission streaming media request of Streaming Media reception device First transmission stream bit rate to the Streaming Media reception device transmit stream medium data, it is subsequent to receive the Streaming Media again When the streaming media request that reception device is sent, dynamic regulation real-time transmission stream is carried out by real-time code rate adjustment module 530 Code rate.In an alternative embodiment, Streaming Media sending device also can decide whether to receive Streaming Media reception device hair for the first time The streaming media request sent, if so, preset transmission stream bit rate can be used to the stream matchmaker in streaming media module 510 Body reception device transmits stream medium data, if not the streaming media for receiving Streaming Media reception device transmission for the first time is asked It asks, real-time code rate adjustment module 530 then can be according to the forward direction of Streaming Media sending device Streaming Media reception device transport stream matchmaker When volume data, the transmission state information of the Streaming Media reception device determines current real-time Transmission stream bit rate, and then Streaming Media passes Defeated module 510 is by determining that the obtain first transmission stream bit rate transmits stream medium data to the Streaming Media reception device, rear Resume it is defeated during, as described in receiving again Streaming Media reception device send streaming media request when, can be according to reality When real-time Transmission stream bit rate of the code rate adjustment module 530 through overregulating to the Streaming Media reception device transmit Streaming Media number According to.It, can be with it should be pointed out that the described herein streaming media request for receiving Streaming Media reception device transmission for the first time It is that Streaming Media reception device is requested for the streaming media for the first time of some target files in stream media.
Transmission state obtains module 520, for obtaining the Streaming Media reception device by the period of first time interval Transmission state information.
Specifically, the transmission state information of the Streaming Media reception device may include the biography of the Streaming Media reception device Defeated rate reference information and/or transmission stability reference information, wherein the transmission rate reference information can be in preset time Mean Speed of the Streaming Media sending device to Streaming Media reception device transmission stream medium data in section, or Streaming Media The current instantaneous transmission rate of reception device or the transmission rate of some sampling instant before, the transmission stability reference information It may include the rate that Streaming Media sending device transmits stream medium data to the Streaming Media reception device within a preset period of time Variance.Transmission state obtains module 520 and transmits stream medium data to the Streaming Media reception device in streaming media module 510 During the transmission state information of the Streaming Media reception device is obtained using first time interval as the period, it is above-mentioned to calculate The transmission rate reference information of Streaming Media reception device or the preset time period of transmission stability reference information, when can be with first Between the duration that is spaced it is identical, can also be different.
Real-time code rate adjustment module 530, for according to the transmission state information of the Streaming Media reception device by Xiang Suoshu Streaming Media reception device transmit stream medium data real-time Transmission stream bit rate from the first transport stream code rate adjustment be the second transport stream Code rate.
In the specific implementation, the Streaming Media sending device can be between preset transmission state information and transmission stream bit rate Mapping relations, after transmission state acquisition module 520 gets the transmission state information of the Streaming Media reception device, real-time code Rate adjustment module 530 can search the stream matchmaker in the mapping relations between preset transmission state information and transmission stream bit rate The corresponding second transmission stream bit rate of the transmission state information of body reception device, thus by real-time Transmission stream bit rate from the first transport stream Code rate adjustment is the second transmission stream bit rate.
And in an alternative embodiment, real-time code rate adjustment module 530 can be according to the transmission of the Streaming Media reception device Status information determines the current transmission state parameter of the Streaming Media reception device, and the transmission state parameter is by value=α * Transmission_speed+ β * transmission_speed_variances is determining, wherein transmission_speed The Mean Speed of stream medium data is transmitted to the Streaming Media reception device for Streaming Media sending device in preset time period, Transmission_speed_variances be in preset time period Streaming Media sending device to the Streaming Media reception device The rate variance of stream medium data is transmitted, α and β are respectively default weighted factor;Real-time code rate adjustment module 530 is in turn according to pre- If transmission state parameter and transmission stream bit rate between mapping relations, determine the Streaming Media reception device transmission state ginseng The corresponding second transmission stream bit rate of number.In a preferred embodiment, α > β, i.e. transmission rate are the Primary Reference of transmission state information Factor.
In the specific implementation, real-time code rate adjustment module 530, which may determine that, transmits Streaming Media to Streaming Media reception device when preceding The real-time Transmission stream bit rate of data the second transport stream code whether corresponding with the transmission state information of the Streaming Media reception device Rate is identical, if the two is same transmission stream bit rate, continues to use the transmission stream bit rate to Streaming Media reception device transport stream matchmaker Volume data determines that obtain second transmits stream bit rate to the stream matchmaker using real-time code rate adjustment module 530 if the two is different Body reception device transmits stream medium data.In an alternative embodiment, streaming media module 510 can be to will currently transmit Stream medium data piece (i.e. TS file piece) after, using it is described according to the transmission state information of the Streaming Media reception device determine Obtained real-time Transmission stream bit rate transmits next TS file piece to the Streaming Media reception device, as target video file includes 100 TS file pieces, 530 basis of real-time code rate adjustment module when transmitting the 50th TS file piece of streaming media module 510 The transmission state information determination of the Streaming Media reception device needs to adjust real-time Transmission stream bit rate, then in subsequently received institute When stating the streaming media request for being directed to the 51st TS file piece (or other TS file pieces) of Streaming Media reception device transmission, stream Media transmission module 510 can be transmitted according to the real-time Transmission stream bit rate of the determination to the Streaming Media reception device requested TS file piece.
Optionally, the Streaming Media sending device in the embodiment of the present invention can further include:
Load condition obtains module 540, for obtaining itself load state information using the second time interval as the period.
Specifically, the load state information may include the flow load information of the Streaming Media sending device, processing Device load information and input and output I/O load information are any one or more of, wherein the flow of the Streaming Media sending device Load information includes Streaming Media sending device current bandwidth utilization (such as curr_flux current server flow/eth0_ Flux network interface card flow rate upper limit) and/or the Streaming Media sending device locating for computer room bandwidth availability ratio (such as curr_dc_flux is current Computer room flow/total_dc_flux computer room upper limit flow), the processor load information includes the Streaming Media sending device Current cpu busy percentage, the input and output I/O load information include the current I/O utilization rate of the Streaming Media sending device, It should be pointed out that above-mentioned utilization rate parameter can be instantaneous value, or the statistical value in preset time period.The load State acquisition module 540 can transmit the mistake of stream medium data in streaming media module 510 to the Streaming Media reception device The load state information of itself, the above-mentioned biography to calculate Streaming Media reception device are obtained using the second time interval as the period in journey The preset time period of defeated rate reference information or transmission stability reference information, can be identical as the duration of the second time interval, It can also be different.Second time interval interval can be identical as first time interval, can also be different.
The real-time code rate adjustment module 530 is also used to adjust the real-time transmission stream according to the load state information Code rate.
In the specific implementation, if the Streaming Media sending device determines that itself is in high load according to the load state information State can then reduce the real-time Transmission stream bit rate.In the present embodiment, the real-time Transmission stream bit rate can be Streaming Media Sending device currently or will to the Streaming Media reception device transmit stream medium data transmission stream bit rate, such as Streaming Media The transmission stream bit rate for next (group) TS file piece that sending device is transmitted to the Streaming Media reception device, for concrete example, If target video file includes 100 TS file pieces, Streaming Media sending device uses transmission when transmitting the 50th TS file piece Stream bit rate is 80kbps, and then gets the load state information determination according to load condition acquisition module 540 and be in certainly In high load condition, then real-time code rate adjustment module 530 can reduce real-time Transmission stream bit rate, such as be reduced to 60kbps, that In the stream for the 51st TS file piece (or other TS file pieces) that the subsequently received Streaming Media reception device is sent When media transmission is requested, streaming media module 510 can be according to the real-time Transmission stream bit rate of the determination to the Streaming Media Reception device transmits requested TS file piece.
In an alternative embodiment, when the current bandwidth availability ratio of the Streaming Media sending device, locating computer room bandwidth usage When rate, cpu busy percentage or I/O utilization rate reach corresponding default load-threshold, real-time code rate adjustment module 530 can reduce institute State real-time Transmission stream bit rate.The corresponding load-threshold of above-mentioned four kinds of utilization rate parameters can be identical numerical value, can also be different, example The load-threshold of for example identical numerical value, when the current bandwidth availability ratio of the Streaming Media sending device, locating computer room bandwidth usage Any one numerical value in rate, cpu busy percentage or I/O utilization rate reaches 90%, then real-time code rate adjustment module 530 can reduce institute State real-time Transmission stream bit rate.
And then in an alternative embodiment, real-time code rate adjustment module 530 can adjust according to the load state information and work as In all Streaming Media reception devices of the preceding stream medium data for receiving the Streaming Media sending device transmission partly or entirely The real-time Transmission stream bit rate of Streaming Media reception device.Such as determine that itself is currently at high load according to the load state information State, then real-time code rate adjustment module 530 can reduce the real-time Transmission for the transmission of flow media data task currently transmitted Stream bit rate, such as all tasks are all lowered to the real-time transmission stream code rate an of rank, in an alternative embodiment, real-time code rate tune Section module 530 can also only reduce the real-time transmission stream code of the Streaming Media reception device using higher real-time Transmission stream bit rate Rate such as transmits stream bit rate and is divided into three high speed, middling speed and low speed ranks, and real-time code rate adjustment module 530 can be by all uses The real-time transmission stream code rate adjustment of the Streaming Media reception device of high speed real-time Transmission stream bit rate is the real-time Transmission stream bit rate of middling speed.
And then in an alternative embodiment, current according to being judged according to load state information when real-time code rate adjustment module 530 It needs to reduce the real-time Transmission stream bit rate, and determines obtained real-time biography according to the transmission state information of Streaming Media reception device Defeated stream bit rate is higher than the transmission stream bit rate used before to Streaming Media reception device transmission stream medium data, at this moment can be temporary When not according to preferentially determining that obtained real-time Transmission stream bit rate is transmitted according to the transmission state information of Streaming Media reception device Stream medium data does not improve the transmission stream bit rate to Streaming Media reception device transmission stream medium data or temporarily reduction temporarily The real-time Transmission stream bit rate, to be currently not high load condition according to the judgement of the load state information of Streaming Media sending device , then improve the transmission stream bit rate to Streaming Media reception device transmission stream medium data.
Streaming Media sending device passes through week during transmitting stream medium data to Streaming Media reception device in the present embodiment The transmission state information of the acquisition Streaming Media reception device of phase property, so as to be passed according to transmission state information dynamic regulation The real-time Transmission stream bit rate of defeated stream medium data realizes the transmission of streaming media self-adapting code rate in Streaming Media transmitting terminal, and then also The negative of Streaming Media sending device itself can be periodically obtained during transmitting stream medium data to Streaming Media reception device Status information is carried, to adjust the real-time Transmission stream bit rate of transmission stream medium data according to load state information, is sent out in Streaming Media Sending end realizes flexible transfer strategy, avoids the system overload of invention Streaming Media sending device.
Fig. 6 is the structural schematic diagram of the Streaming Media sending device in another embodiment of the present invention, the present embodiment as shown in the figure In Streaming Media sending device may include:
At least one processor 601, such as CPU, at least one network interface 604, memory 605, at least one communication Bus 602.Wherein, communication bus 602 is for realizing the connection communication between these components.Wherein.Network interface 604 is optional It may include standard wireline interface and wireless interface (such as WI-FI interface).Memory 605 can be high speed RAM memory, It can be non-labile memory (non-volatile memory), for example, at least a magnetic disk storage.Memory 605 It optionally can also include that at least one is located remotely from the storage device of aforementioned processor 601.As shown in fig. 6, as a kind of meter It may include operating system, network communication module and streaming media program in the memory 605 of calculation machine storage medium.
In Streaming Media sending device shown in Fig. 6, network interface 604, which is mainly used for receiving by network and Streaming Media, to be filled It sets and is communicated;And processor 601 can be used for calling the streaming media program stored in memory 605, and execute following Operation:
The streaming media request sent according to Streaming Media reception device is connect with the first transmission stream bit rate to the Streaming Media Receiving apparatus transmits stream medium data.Specifically,
The transmission state information of the Streaming Media reception device is obtained using first time interval as the period, the transmission shape State information includes the transmission rate reference information and/or transmission stability reference information of Streaming Media reception device;
According to the transmission state information of the Streaming Media reception device Streaming Media will be transmitted to the Streaming Media reception device The real-time Transmission stream bit rate of data transmits stream bit rate from the first transport stream code rate adjustment for second.
In one embodiment, processor 601 calls the streaming media program stored in memory 605 can also be performed It operates below:
The load state information of itself is obtained using the second time interval as the period;
The real-time Transmission stream bit rate is adjusted according to the load state information.
In an alternative embodiment, the transmission state information according to the Streaming Media reception device will be to the Streaming Media The transmission stream bit rate of reception device transmission stream medium data is that the second transmission stream bit rate includes: from the first transport stream code rate adjustment
It is determining to be received with the Streaming Media according to the mapping relations between preset transmission state information and transmission stream bit rate The corresponding second transmission stream bit rate of the transmission state information of device.
In an alternative embodiment, the transmission rate reference information include Streaming Media sending device within a preset period of time to The Mean Speed of the Streaming Media reception device transmission stream medium data, the transmission stability reference information include Streaming Media hair Send rate variance of the device within a preset period of time to Streaming Media reception device transmission stream medium data.
In an alternative embodiment, the transmission state information according to the Streaming Media reception device will be to the Streaming Media The real-time Transmission stream bit rate that reception device transmits stream medium data transmits stream bit rate packet from the first transport stream code rate adjustment for second It includes:
The current transmission of the Streaming Media reception device is determined according to the transmission state information of the Streaming Media reception device State parameter, the transmission state parameter is by value=α * transmission_speed+ β * transmission_speed_ Variances determines, wherein transmission_speed be in preset time period Streaming Media sending device to the Streaming Media Reception device transmits the Mean Speed of stream medium data, and transmission_speed_variances is stream in preset time period Rate variance from media transmission device to Streaming Media reception device transmission stream medium data, α and β be respectively default weighting because Son;
The Streaming Media sending device is according to the mapping relations between preset transmission state parameter and transmission stream bit rate, really Fixed the second transmission stream bit rate corresponding with the transmission state parameter of the Streaming Media reception device.
In an alternative embodiment, described to include: according to the load state information adjusting real-time Transmission stream bit rate
If the Streaming Media sending device determines that itself is in high load condition, reduces according to the load state information The real-time Transmission stream bit rate.
In an alternative embodiment, the load state information include the Streaming Media sending device flow load information, Processor load information and input and output I/O load information are any one or more of.
In an alternative embodiment, the flow load information of the Streaming Media sending device includes the Streaming Media sending device Computer room bandwidth availability ratio locating for current bandwidth utilization and/or the Streaming Media sending device, the processor load packet The current cpu busy percentage of the Streaming Media sending device is included, the input and output I/O load information includes that the Streaming Media is sent The current I/O utilization rate of device.
In an alternative embodiment, the Streaming Media sending device adjusts the real-time Transmission according to the load state information Stream bit rate includes:
As the current bandwidth availability ratio of the Streaming Media sending device, locating computer room bandwidth availability ratio, cpu busy percentage or I/ When O utilization rate reaches corresponding default load-threshold, the real-time Transmission stream bit rate is reduced.
In an alternative embodiment, the Streaming Media sending device adjusts the real-time Transmission according to the load state information Stream bit rate includes:
The Streaming Media number that the Streaming Media sending device transmission is currently being received is adjusted according to the load state information According to all Streaming Media reception devices in part or all of Streaming Media reception device real-time Transmission stream bit rate.
In an alternative embodiment, the Streaming Media sending device is asked according to the streaming media that Streaming Media reception device is sent It asks and is included with the first transmission stream bit rate to Streaming Media reception device transmission flow media data packet:
When receiving the streaming media request that the Streaming Media reception device is sent for the first time, passed using preset first Defeated stream bit rate transmits stream medium data to the Streaming Media reception device.
In an alternative embodiment, the transmission state information according to the Streaming Media reception device will be to the Streaming Media The real-time Transmission stream bit rate that reception device transmits stream medium data transmits stream bit rate packet from the first transport stream code rate adjustment for second It includes:
When receiving the streaming media request that the Streaming Media reception device is sent again, using according to the stream matchmaker The second transmission stream bit rate that the transmission state information of body reception device is adjusted is to the Streaming Media reception device transport stream matchmaker Volume data.
Fig. 7 is the structural schematic diagram of one of embodiment of the present invention stream media transmission system, the present embodiment as shown in the figure In stream media transmission system may include Streaming Media sending device 710 and at least one Streaming Media reception device 720, in which:
The Streaming Media reception device 720 is used to send streaming media request to the Streaming Media sending device 710, connects The Streaming Media sending device 710 is received according to the stream medium data of streaming media request transmission;
The Streaming Media sending device 710 Streaming Media reception device as described in Fig. 5 or Fig. 6 above is used for root The streaming media request sent according to Streaming Media reception device 720 transmits stream bit rate to the Streaming Media reception device with first 720 transmission stream medium datas;The transmission state letter of the Streaming Media reception device 720 is obtained using first time interval as the period Breath, the transmission state information includes the transmission rate reference information and/or transmission stability of the Streaming Media reception device 720 Reference information;It will be transmitted to the Streaming Media reception device 720 according to the transmission state information of the Streaming Media reception device 720 The real-time Transmission stream bit rate of stream medium data transmits stream bit rate from the first transport stream code rate adjustment for second.
In an alternative embodiment, the Streaming Media sending device 710 is also used to be obtained from using the second time interval as the period The load state information of body, and the real-time Transmission stream bit rate is adjusted according to the load state information.
In an alternative embodiment, the Streaming Media sending device 710 is adjusted described real-time according to the load state information Transmitting stream bit rate includes:
The Streaming Media sending device 710 is currently being received the Streaming Media according to load state information adjusting and sends out Part or all of Streaming Media reception device 720 in all Streaming Media reception devices 720 for the stream medium data for sending device 710 to transmit Real-time Transmission stream bit rate.
Streaming Media sending device is by transmitting stream medium data process to Streaming Media reception device in the embodiment of the present invention In periodically obtain the transmission state information of the Streaming Media reception device, so as to be adjusted according to transmission state information dynamic The real-time Transmission stream bit rate of section transmission stream medium data realizes the transmission of streaming media self-adapting code rate in Streaming Media transmitting terminal, into And Streaming Media sending device itself can also be periodically obtained during transmitting stream medium data to Streaming Media reception device Load state information, thus according to load state information adjust transmission stream medium data real-time Transmission stream bit rate, stream matchmaker Body transmitting terminal realizes flexible transfer strategy, avoids the system overload of invention Streaming Media sending device.
Those of ordinary skill in the art will appreciate that realizing all or part of the process in above-described embodiment method, being can be with Relevant hardware is instructed to complete by computer program, the program can be stored in a computer-readable storage medium In, the program is when being executed, it may include such as the process of the embodiment of above-mentioned each method.Wherein, the storage medium can be magnetic Dish, CD, read-only memory (Read-Only Memory, ROM) or random access memory (Random Access Memory, RAM) etc..
The above disclosure is only the preferred embodiments of the present invention, cannot limit the right model of the present invention with this certainly It encloses, therefore equivalent changes made in accordance with the claims of the present invention, is still within the scope of the present invention.

Claims (23)

1. a kind of flow-medium transmission method, which is characterized in that the described method includes:
The streaming media request that Streaming Media sending device is sent according to Streaming Media reception device transmits stream bit rate to institute with first State Streaming Media reception device transmission stream medium data;
The transmission state information of the Streaming Media reception device, the transmission state information are obtained using first time interval as the period Transmission rate reference information and transmission stability reference information including Streaming Media reception device, the transmission rate reference information Transmit the Mean Speed of stream medium data to the Streaming Media reception device within a preset period of time including Streaming Media sending device, The transmission stability reference information includes that Streaming Media sending device is passed to the Streaming Media reception device within a preset period of time The rate variance of defeated stream medium data;
According to the mapping relations between preset transmission state information and transmission stream bit rate, the determining and Streaming Media reception device Transmission state information it is corresponding second transmission stream bit rate;
The load state information of itself is obtained using the second time interval as the period;
If the second transmission stream bit rate is than when preceding the first transmission used to Streaming Media reception device transmission stream medium data Stream bit rate wants high, then, will be to after being currently not high load condition according to the confirmation of the load state information of Streaming Media sending device The real-time Transmission stream bit rate of the Streaming Media reception device transmission stream medium data is passed from the first transport stream code rate adjustment for second Defeated stream bit rate.
2. flow-medium transmission method as described in claim 1, which is characterized in that the method also includes:
The real-time Transmission stream bit rate is adjusted according to the load state information.
3. flow-medium transmission method as described in claim 1, which is characterized in that described according to the Streaming Media reception device Transmission state information will be to the real-time Transmission stream bit rate of Streaming Media reception device transmission stream medium data from the first transport stream Code rate adjustment is that the second transmission stream bit rate includes:
The current transmission state of the Streaming Media reception device is determined according to the transmission state information of the Streaming Media reception device Parameter, the transmission state parameter is by value=α * transmission_speed+ β * transmission_speed_ Variances determines, wherein transmission_speed be in preset time period Streaming Media sending device to the Streaming Media Reception device transmits the Mean Speed of stream medium data, and transmission_speed_variances is stream in preset time period Rate variance from media transmission device to Streaming Media reception device transmission stream medium data, α and β be respectively default weighting because Son;
According to the mapping relations between preset transmission state parameter and transmission stream bit rate, the determining and Streaming Media reception device Transmission state parameter it is corresponding second transmission stream bit rate.
4. flow-medium transmission method as claimed in claim 2, which is characterized in that described to be adjusted according to the load state information The real-time Transmission stream bit rate includes:
If the Streaming Media sending device is determined according to the load state information itself is in high load condition, described in reduction Real-time Transmission stream bit rate.
5. flow-medium transmission method as claimed in claim 2, which is characterized in that the load state information includes the stream matchmaker The flow load information of body sending device, processor load information and input and output I/O load information are any one or more of.
6. flow-medium transmission method as claimed in claim 5, which is characterized in that the flow load of the Streaming Media sending device Information includes the benefit of computer room bandwidth locating for the Streaming Media sending device current bandwidth utilization and/or the Streaming Media sending device With rate, the processor load information includes the current cpu busy percentage of the Streaming Media sending device, the input and output I/O Load information includes the current I/O utilization rate of the Streaming Media sending device.
7. flow-medium transmission method as claimed in claim 6, which is characterized in that described to be adjusted according to the load state information The real-time Transmission stream bit rate includes:
When the current bandwidth availability ratio of the Streaming Media sending device, locating computer room bandwidth availability ratio, cpu busy percentage or I/O benefit When reaching corresponding default load-threshold with rate, the real-time Transmission stream bit rate is reduced.
8. flow-medium transmission method as claimed in claim 2, which is characterized in that described to be adjusted according to the load state information The real-time Transmission stream bit rate includes:
The stream medium data that the Streaming Media sending device transmission is currently being received is adjusted according to the load state information The real-time Transmission stream bit rate of part or all of Streaming Media reception device in all Streaming Media reception devices.
9. such as flow-medium transmission method according to any one of claims 1 to 8, which is characterized in that the Streaming Media sends dress It sets the streaming media request sent according to Streaming Media reception device and transmits stream bit rate to the Streaming Media reception device with first Transmission flow media data packet includes:
When receiving the streaming media request that the Streaming Media reception device is sent for the first time, preset first transport stream is used Code rate transmits stream medium data to the Streaming Media reception device.
10. flow-medium transmission method as claimed in claim 9, which is characterized in that described according to the Streaming Media reception device Transmission state information by the Streaming Media reception device transmission stream medium data real-time Transmission stream bit rate from first transmission Stream bit rate is adjusted to the second transmission stream bit rate
When receiving the streaming media request that the Streaming Media reception device is sent again, connect using according to the Streaming Media The second transmission stream bit rate that the transmission state information of receiving apparatus is adjusted transmits Streaming Media number to the Streaming Media reception device According to.
11. a kind of Streaming Media sending device, which is characterized in that the Streaming Media sending device includes:
Streaming media module, the streaming media request for being sent according to Streaming Media reception device is with the first transmission stream bit rate Stream medium data is transmitted to the Streaming Media reception device;
Transmission state obtains module, for obtaining the transmission state of the Streaming Media reception device using first time interval as the period Information, the transmission state information include the transmission rate reference information and/or transmission stability of the Streaming Media reception device Reference information, the transmission rate reference information are received including Streaming Media sending device within a preset period of time to the Streaming Media Device transmits the Mean Speed of stream medium data, and the transmission stability reference information includes Streaming Media sending device when default Between rate variance of the Streaming Media sending device to Streaming Media reception device transmission stream medium data in section;
Load condition obtains module, and the load condition for obtaining Streaming Media sending device as the period using the second time interval is believed Breath;
Real-time code rate adjustment module, for according to preset transmission state information and transmission stream bit rate between mapping relations, really Fixed the second transmission stream bit rate corresponding with the transmission state information of the Streaming Media reception device, if the second transmission stream bit rate The first transmission stream bit rate than using before to Streaming Media reception device transmission stream medium data is high, then according to Streaming Media It, will be to the Streaming Media reception device transport stream matchmaker after the load state information confirmation of sending device is currently not high load condition The real-time Transmission stream bit rate of volume data transmits stream bit rate from the first transport stream code rate adjustment for second.
12. Streaming Media sending device as claimed in claim 11, which is characterized in that further include: the real-time code rate adjusts mould Block is also used to adjust the real-time Transmission stream bit rate according to the load state information.
13. Streaming Media sending device as claimed in claim 11, which is characterized in that the real-time code rate adjustment module is used for:
The current transmission state of the Streaming Media reception device is determined according to the transmission state information of the Streaming Media reception device Parameter, the transmission state parameter is by value=α * transmission_speed+ β * transmission_speed_ Variances determines, wherein transmission_speed be in preset time period Streaming Media sending device to the Streaming Media Reception device transmits the Mean Speed of stream medium data, and transmission_speed_variances is stream in preset time period Rate variance from media transmission device to Streaming Media reception device transmission stream medium data, α and β be respectively default weighting because Son;
According to the mapping relations between preset transmission state parameter and transmission stream bit rate, the determining and Streaming Media reception device Transmission state parameter it is corresponding second transmission stream bit rate.
14. Streaming Media sending device as claimed in claim 12, which is characterized in that the real-time code rate adjustment module is according to institute Stating the load state information adjusting real-time Transmission stream bit rate includes:
It itself is in high load condition if determining according to the load state information, the real-time code rate adjustment module reduces institute State real-time Transmission stream bit rate.
15. Streaming Media sending device as claimed in claim 12, which is characterized in that the load state information includes the stream Any one of flow load information, processor load information and input and output I/O load information of media transmission device are more Kind.
16. Streaming Media sending device as claimed in claim 15, which is characterized in that the flow of the Streaming Media sending device is negative Information carrying breath includes computer room bandwidth locating for the Streaming Media sending device current bandwidth utilization and/or the Streaming Media sending device Utilization rate, the processor load information include the current cpu busy percentage of the Streaming Media sending device, the input and output I/ O load information includes the current I/O utilization rate of the Streaming Media sending device.
17. Streaming Media sending device as claimed in claim 16, which is characterized in that the real-time code rate adjustment module is according to institute Stating the load state information adjusting real-time Transmission stream bit rate includes:
When the current bandwidth availability ratio of the Streaming Media sending device, locating computer room bandwidth availability ratio, cpu busy percentage or I/O benefit When reaching corresponding default load-threshold with rate, real-time code rate adjustment module reduces the real-time Transmission stream bit rate.
18. Streaming Media sending device as claimed in claim 12, which is characterized in that the real-time code rate adjustment module is according to institute Stating the load state information adjusting real-time Transmission stream bit rate includes:
The real-time code rate adjustment module is currently being received the Streaming Media according to load state information adjusting and sends dress Set the real-time transmission stream of part or all of Streaming Media reception device in all Streaming Media reception devices of the stream medium data of transmission Code rate.
19. the Streaming Media sending device as described in any one of claim 11~18, which is characterized in that the streaming media Module is used for:
When receiving the streaming media request that the Streaming Media reception device is sent for the first time, preset first transport stream is used Code rate transmits stream medium data to the Streaming Media reception device.
20. Streaming Media sending device as claimed in claim 19, which is characterized in that the streaming media module is also used to:
When receiving the streaming media request that the Streaming Media reception device is sent again, is received and filled according to the Streaming Media The transmission state information set will be passed to the real-time Transmission stream bit rate of Streaming Media reception device transmission stream medium data from first Defeated stream bit rate is adjusted to the second transmission stream bit rate.
21. a kind of stream media transmission system, which is characterized in that including the Streaming Media as described in any one of claim 11~20 Sending device and at least one Streaming Media reception device, in which:
The Streaming Media reception device is used to send streaming media request to the Streaming Media sending device, receives the stream matchmaker The stream medium data that body sending device is transmitted according to streaming media request;
The streaming media that the Streaming Media sending device is used to be sent according to Streaming Media reception device is requested with the first transport stream Code rate transmits stream medium data to the Streaming Media reception device;The Streaming Media is obtained as the period using first time interval to receive The transmission state information of device, the transmission state information include the transmission rate reference information of the Streaming Media reception device And/or transmission stability reference information;It will be connect to the Streaming Media according to the transmission state information of the Streaming Media reception device The real-time Transmission stream bit rate that receiving apparatus transmits stream medium data transmits stream bit rate from the first transport stream code rate adjustment for second.
22. stream media transmission system as claimed in claim 21, which is characterized in that
The Streaming Media sending device is also used to obtain the load state information of itself, and root using the second time interval as the period The real-time Transmission stream bit rate is adjusted according to the load state information.
23. stream media transmission system as claimed in claim 22, which is characterized in that the Streaming Media sending device is according to Load state information adjusts the real-time Transmission stream bit rate
The Streaming Media sending device is currently being received according to load state information adjusting in the Streaming Media sending device The real-time transmission stream code of part or all of Streaming Media reception device in all Streaming Media reception devices of the stream medium data of transmission Rate.
CN201410322938.5A 2014-07-08 2014-07-08 A kind of flow-medium transmission method, Streaming Media sending device and stream media transmission system Active CN105306424B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410322938.5A CN105306424B (en) 2014-07-08 2014-07-08 A kind of flow-medium transmission method, Streaming Media sending device and stream media transmission system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410322938.5A CN105306424B (en) 2014-07-08 2014-07-08 A kind of flow-medium transmission method, Streaming Media sending device and stream media transmission system

Publications (2)

Publication Number Publication Date
CN105306424A CN105306424A (en) 2016-02-03
CN105306424B true CN105306424B (en) 2019-05-03

Family

ID=55203182

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410322938.5A Active CN105306424B (en) 2014-07-08 2014-07-08 A kind of flow-medium transmission method, Streaming Media sending device and stream media transmission system

Country Status (1)

Country Link
CN (1) CN105306424B (en)

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107154918B (en) * 2016-03-03 2019-11-08 北京大学 Net cast transfer control method and system based on PID control
CN106803919B (en) * 2017-03-02 2019-08-02 无锡纽微特科技有限公司 The video call system and implementation method of load can be reduced
KR102307447B1 (en) * 2017-05-02 2021-09-30 삼성전자주식회사 Server, method, and client terminal for http adaptive streaming based on network environment mornitoring
CN107071567A (en) * 2017-05-18 2017-08-18 深圳算云微豆投资中心(有限合伙) A kind of monitoring method and system of multi-medium data transmitting procedure
CN107911840A (en) * 2017-11-21 2018-04-13 青岛海信电器股份有限公司 The control method and device of streaming media
CN107995172A (en) * 2017-11-23 2018-05-04 莫宝兰 A kind of data stream transmitting control system and method
CN107948153A (en) * 2017-11-23 2018-04-20 莫宝兰 A kind of streaming media control system and method
CN109982110B (en) * 2017-12-28 2021-03-30 华为技术有限公司 Method and device for video playing
CN110611789A (en) * 2018-06-14 2019-12-24 杭州海康威视数字技术股份有限公司 Video streaming transmission control method and device, electronic equipment and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1764184A (en) * 2005-10-20 2006-04-26 中兴通讯股份有限公司 Real-time flow media communication transmission system and method
CN1980238A (en) * 2006-10-30 2007-06-13 上海广电(集团)有限公司中央研究院 II.264 flow-media transmission control method based on real-time transmission/control protocl
CN101499918A (en) * 2009-02-10 2009-08-05 宇龙计算机通信科技(深圳)有限公司 Adaptive stream media playing method, apparatus, system and mobile terminal
CN101668310A (en) * 2009-09-24 2010-03-10 中兴通讯股份有限公司 Method for broadcasting stream media and device therefor

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1764184A (en) * 2005-10-20 2006-04-26 中兴通讯股份有限公司 Real-time flow media communication transmission system and method
CN1980238A (en) * 2006-10-30 2007-06-13 上海广电(集团)有限公司中央研究院 II.264 flow-media transmission control method based on real-time transmission/control protocl
CN101499918A (en) * 2009-02-10 2009-08-05 宇龙计算机通信科技(深圳)有限公司 Adaptive stream media playing method, apparatus, system and mobile terminal
CN101668310A (en) * 2009-09-24 2010-03-10 中兴通讯股份有限公司 Method for broadcasting stream media and device therefor

Also Published As

Publication number Publication date
CN105306424A (en) 2016-02-03

Similar Documents

Publication Publication Date Title
CN105306424B (en) A kind of flow-medium transmission method, Streaming Media sending device and stream media transmission system
CN104394486B (en) A kind of video stream processing method and device based on cloud desktop
CN104125429B (en) The adjusting method and device of video data transmission
US9462032B2 (en) Streaming media content
CN104254007B (en) A kind of audio-frequency processing method and device
CN114363667B (en) Client, server, receiving method and transmitting method
CN106851799B (en) Method and device for sending heartbeat packet in long connection
CN102412999A (en) Packet capturing based remote fault location method, system and device
CN108901077A (en) Antenna accounting setting method, device, user equipment and storage medium
CN105450785A (en) File transmission method and device
CN102883372A (en) Traffic controlling method and terminal
CN108738007B (en) Audio transmission method, equipment and system
CN105828072A (en) Image processing method, remote controlled device and virtual reality system
CN103607395A (en) Touch sense data transmission method and apparatus
CN105763476A (en) Method and apparatus for customizing data business service strategies
CN110446080B (en) Video playing method and device
CN104581424B (en) A kind of flow-medium transmission method, relevant device and system
CN104581340A (en) Client-side, streaming media data receiving method and streaming media data transmission system
CN107124603A (en) A kind of multi-view point video adaptive transmission method based on caching
CN105141644B (en) A kind of method for down loading and terminal of files in stream media
CN104509061A (en) Method and device for regulating streaming media data transmission
CN105208461A (en) Resource distribution method and apparatus
CN103888586B (en) A kind of method transmitting data and terminal
CN113949417B (en) Power grid data transmission method and device based on hybrid communication
CN106792030B (en) A kind of audio data processing method and TV

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20190731

Address after: Shenzhen Futian District City, Guangdong province 518000 Zhenxing Road, SEG Science Park 2 East Room 403

Co-patentee after: Tencent cloud computing (Beijing) limited liability company

Patentee after: Tencent Technology (Shenzhen) Co., Ltd.

Address before: Shenzhen Futian District City, Guangdong province 518000 Zhenxing Road, SEG Science Park 2 East Room 403

Patentee before: Tencent Technology (Shenzhen) Co., Ltd.