CN108271085A - A kind of sending method and device of HTTP real time flow mediums HLS files - Google Patents

A kind of sending method and device of HTTP real time flow mediums HLS files Download PDF

Info

Publication number
CN108271085A
CN108271085A CN201611257282.9A CN201611257282A CN108271085A CN 108271085 A CN108271085 A CN 108271085A CN 201611257282 A CN201611257282 A CN 201611257282A CN 108271085 A CN108271085 A CN 108271085A
Authority
CN
China
Prior art keywords
files
code check
sent
server
check value
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.)
Pending
Application number
CN201611257282.9A
Other languages
Chinese (zh)
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.)
ZTE Corp
Original Assignee
ZTE Corp
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 ZTE Corp filed Critical ZTE Corp
Priority to CN201611257282.9A priority Critical patent/CN108271085A/en
Publication of CN108271085A publication Critical patent/CN108271085A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/80Generation or processing of content or additional data by content creator independently of the distribution process; Content per se
    • H04N21/83Generation or processing of protective or descriptive data associated with content; Content structuring
    • H04N21/845Structuring of content, e.g. decomposing content into time segments
    • H04N21/8456Structuring of content, e.g. decomposing content into time segments by decomposing the content in the time domain, e.g. in time segments
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/25Management operations performed by the server for facilitating the content distribution or administrating data related to end-users or client devices, e.g. end-user or client device authentication, learning user preferences for recommending movies
    • H04N21/266Channel or content management, e.g. generation and management of keys and entitlement messages in a conditional access system, merging a VOD unicast channel into a multicast channel
    • H04N21/2662Controlling the complexity of the video stream, e.g. by scaling the resolution or bitrate of the video stream based on the client capabilities

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Databases & Information Systems (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The embodiment of the invention discloses the method and devices that a kind of HLS files are sent.Wherein, this method principle is the code check that server-side can ask files in stream media according to user terminal, determines to send the transmission rate of this document.Using the technical solution, it can solve present in the relevant technologies, present in the relevant technologies, it can not be adjusted according to the actual conditions of client and send the rate of file code stream for server-side, the problem of causing the waste of server-side resource, realizing server end can carry out sending according to client actual request the transmission rate of files in stream media code check, saved server-side resource, improved the service ability of server-side.

Description

A kind of sending method and device of HTTP real time flow mediums HLS files
Technical field
The present invention relates to HTTP real time flow medium file play-back technologies, in particular to a kind of HTTP real time flow mediums The sending method and device of HLS files.
Background technology
HTTP live streaming stream protocols (HTTP Live Streaming, referred to as HLS) are the real-time streams matchmakers that Apple Inc. proposes Body transport protocol, it can be achieved that the live streaming of Streaming Media, program request, time shift, the functions such as review, at present more and more content suppliers and Operator provides Video service to the user using HLS protocol.
At present, in order to provide the user with the Video service of high-quality smoothness, usually there are two types of ways:(1) streaming media server Film source is cut into advance it is fixed, have different code checks fragment, client is according to screen resolution, network environment of user etc. Factor removes the fragment for determining to ask that code check.(2) streaming media server does not shift to an earlier date cutting piece, when user asks to arrive, root The parameters such as the transmission rate according to the code stream for being sent to user need the code check of fragment that is sliced to adjust.In general, it takes The network performance at business end is good, and network transmission speed is fast, and the network performance of client is poor, and network reception speed is slow, therefore server-side Even if send quickly, it is also desirable to wait for the slow reception of client.And server-side can not according to the actual conditions of client into Row adjusts it and sends the rate of file code stream, causes the waste of server-side resource, currently no effective solution has been proposed.
Invention content
The embodiment provides a kind of sending method and device of HTTP real time flow mediums HLS files, at least It solves in the relevant technologies, it can not be adjusted according to the actual conditions of client and send the rate of file code stream for server-side, make Into server-side resource waste the problem of.
One side according to embodiments of the present invention provides a kind of sending method of HTTP real time flow mediums HLS files, It can include:Obtain the code check value of transport stream TS slicing files to be sent;It is determined according to the code check value described to be sent The transmission rate of TS slicing files;The TS slicing files are sent according to the transmission rate.
Further, the code check value of transport stream TS slicing files to be sent is obtained, can also be included:It obtains and sends M3u8 files, wherein, the m3u8 files are used to describe the TS slicing files to be sent;According to the m3u8 file acquisitions The code check value of the TS slicing files to be sent.
Further, according to the m3u8 file acquisitions TS slicing files code check value, can also include:It is described In the case that the form of m3u8 files is solid size rate, the size and duration of the TS files to be sent are obtained;It is treated according to described The code check value of TS slicing files described in the size and duration calculation of the TS files of transmission.
Further, according to the m3u8 file acquisitions TS slicing files code check value, including:The m3u8 files Form in the case of multi code Rate of Chinese character, to obtain corresponding to the TS slicing files to be sent in the m3u8 files The value of BANDWIDTH, and it is determined as the code check value of the TS slicing files.
Further, the transmission that the TS slicing files to be sent are determined according to the code check value in above example Rate can also include:At least one code check adjusting parameter is set according to the network condition of server-side and client, according to described Code check value and the code check adjusting parameter calculate, and obtain the transmission rate of the TS slicing files.
Another aspect according to embodiments of the present invention provides a kind of sending device of HTTP real time flow mediums HLS files, The device can include:Acquisition module, for obtaining the code check value of transport stream TS slicing files to be sent;Determining module, root The transmission rate of the TS slicing files to be sent is determined according to the code check value;Sending module, for sending speed according to described Rate sends the TS slicing files.
Further, the acquisition module can also include:First acquisition unit, for obtaining and sending m3u8 files, Wherein, the m3u8 files are used to describe the TS slicing files to be sent;Second acquisition unit, for according to the m3u8 The code check value of TS slicing files to be sent described in file acquisition.
Further, the second acquisition unit can be also used for:The form of the m3u8 files is the situation of solid size rate Under, the size and duration of the acquisition TS files to be sent;According to the size and duration calculation of the TS files to be sent The code check value of the TS slicing files;Alternatively, the form of the m3u8 files is in the case of multi code Rate of Chinese character, obtains the m3u8 texts The value of the BANDWIDTH corresponding to the TS slicing files to be sent in part, and it is determined as the code of the TS slicing files Rate value.
Further, the determining module can be also used for:According to the setting of the network condition of server-side and client at least One code check adjusting parameter calculates according to the code check value and the code check adjusting parameter, and obtains the TS slicing files Transmission rate.
According to another embodiment of the invention, a kind of streaming media server can also be provided, which can To include any one device as described above.
By the present invention and embodiment, the code check value for obtaining transport stream TS slicing files to be sent is taken;According to described Code check value determines the transmission rate of the TS slicing files to be sent;The TS slicing files are sent according to the transmission rate Technical solution, can solve present in the relevant technologies, server-side can not be adjusted according to the actual conditions of client It sends the rate of file code stream, and the problem of causing the waste of server-side resource, realizing server end can be according to client End actual request send the transmission rate of files in stream media code check, has saved server-side resource, has improved the clothes of server-side Business ability.
Description of the drawings
Attached drawing described herein is used to provide further understanding of the present invention, and forms the part of the application, this hair Bright illustrative embodiments and their description do not constitute improper limitations of the present invention for explaining the present invention.In the accompanying drawings:
Fig. 1 is a kind of flow diagram of the sending method of HLS files according to embodiments of the present invention;
Fig. 2 is a kind of structure diagram of the sending device of HLS files according to embodiments of the present invention;
Fig. 3 is a kind of structure diagram of the sending device of HLS files according to the preferred embodiment of the invention;
Fig. 4 is a kind of flow diagram of the sending method of HLS files according to the preferred embodiment of the invention.
Specific embodiment
Come that the present invention will be described in detail below with reference to attached drawing and in conjunction with the embodiments.It should be noted that do not conflicting In the case of, the feature in embodiment and embodiment in the application can be combined with each other.
Fig. 1 is a kind of flow diagram of the sending method of HLS files according to embodiments of the present invention.It as shown in Figure 1, should Flow may include steps of:
Step S100 obtains the code check value of transport stream TS slicing files to be sent;
Step S102 determines the transmission rate of the TS slicing files to be sent according to the code check value;
Step S104 sends the TS slicing files according to the transmission rate.
By using method shown in FIG. 1, server-side can ask the code check of files in stream media according to user terminal, determine hair Send the transmission rate of this document.Using the technical solution, can solve present in the relevant technologies, present in the relevant technologies, It can not be adjusted according to the actual conditions of client and send the rate of file code stream for server-side, cause server-side resource The problem of waste, realizing server end can carry out sending according to client actual request the transmission speed of files in stream media code check Rate has saved server-side resource, improves the service ability of server-side.
In this embodiment, the method for HLS files is sent in the code check value for obtaining transport stream TS slicing files to be sent When, it can be there are many realization method.One of which is exactly to take acquisition and send m3u8 files, wherein, the m3u8 files are used In the description TS slicing files to be sent;The code check of TS slicing files to be sent according to the m3u8 file acquisitions The technical solution of value.TS slicing files have corresponding m3u8 index files, and m3u8 index files are corresponding for indexing its TS slicing files, it can include it is many describe the TS files information, server-side can by analyzing these description informations, So as to obtain the code check value of the TS files.
In mode is further carried out, there are many code checks for TS slicing files, and corresponding m3u8 index files are also to have Different code check forms.Therefore basis and is needed at the code check value of its corresponding TS slicing files according to m3u8 file acquisitions The form of m3u8 files takes different technological means.Such as:In the case where the form of m3u8 files is solid size rate, obtain The size and duration of the TS files to be sent;According to TS described in the size and duration calculation of the TS files to be sent points The code check value of piece file.Another situation is that the form of the m3u8 files is in the case of multi code Rate of Chinese character, obtains the m3u8 The value of the BANDWIDTH corresponding to the TS slicing files to be sent in file, and it is determined as the TS slicing files Code check value.
In the case where m3u8 index file forms are solid size rate, server-side is can not to directly acquire the corresponding TS files Code check value, need further to parse the information that m3u8 index files describe TS files, obtain TS files file size and File duration can obtain the code check value of the TS files according to calculation formula.The m3u8 of solid size rate form is not include code check to believe Breath, it is therefore desirable to calculate in this way:Assuming that the size of file is S, the playing duration of file is T, then the code rate V of this document is: Code rate V=S/T.The calculation formula is also used in the big files of common vod and utilizes file size divided by file duration.
In the case where m3u8 index files are multi code Rate of Chinese character, when server-side can not be needed to through TS file sizes and file Length carries out that code check value is calculated;But by analyzing the content information of m3u8 index files, the m3u8 files of multi code Rate of Chinese character form Label E XT-X-STREAM-INF therein in have BANDWIDTH attributes, BANDWIDTH property values just represent corresponding son The code check of ts files in m3u8 files, therefore server-side parses the m3u8 of the multi code Rate of Chinese character form and can be obtained by corresponding TS text The code check value V=BANDWIDTH of part.
In addition, in an embodiment of the present invention, in order to advanced optimize the service ability of server-side, further improve clothes It is engaged in the service ability at end, the TS fragments text to be sent is determined according to the code check value in the sending method of more than HLS files Following technological means may be used in the transmission rate of part, such as sets at least one according to the network condition of server-side and client A code check adjusting parameter calculates according to the code check value and the code check adjusting parameter, and obtains the hair of the TS slicing files Transmission rate.For example, the network speed of server-side is preferable or the client terminal quantity of same period request streaming media service compared with Less or the network speed of client is preferable, can set a valve for being more than 1 based on experience value.According to this valve and TS texts The product of the code check value of part obtains sending the transmission rate of the TS files, and the transmission rate is necessarily more than the code check value.When So can similarly obtain, the client terminal quantity of the network speed of server-side difference or the request streaming media service of same period it is more or The network speed of person's client is poor, which could be provided as being more than 0 and the decimal less than 1, obtained transmission rate are necessarily small In TS file code check values.One valve is set by actual conditions in this way, server-side can more effectively be controlled to send TS files The rate of code check further optimizes the service ability of server-side.
Fig. 2 is the structure diagram for the device that a kind of HLS files according to embodiments of the present invention are sent, as shown in Fig. 2, the dress Acquisition module 20, determining module 22, sending module 24 can be included by putting.The device is illustrated below.
Acquisition module 20 can be used for obtaining the code check value of transport stream TS slicing files to be sent;
Determining module 22 is connect with acquisition module 22, can be used for determining the TS to be sent according to the code check value The transmission rate of slicing files;
Sending module 24 is connect with determining module 22, can be used for sending the TS fragments text according to the transmission rate Part.
The device provided through this embodiment, server-side can ask the code check of files in stream media according to user terminal, determine Send the transmission rate of this document.Using the technical solution, it can solve present in the relevant technologies, exist in the relevant technologies , it can not be adjusted according to the actual conditions of client and send the rate of file code stream for server-side, cause server-side money The problem of waste in source, realizing server end can carry out sending according to client actual request the hair of files in stream media code check Transmission rate has saved server-side resource, improves the service ability of server-side.
In this embodiment, acquisition module 20 can also include:First acquisition unit, for obtaining and sending m3u8 texts Part, wherein, the m3u8 files are used to describe the TS slicing files to be sent;Second acquisition unit, for according to The code check value of TS slicing files to be sent described in m3u8 file acquisitions.TS slicing files have corresponding m3u8 index files, and M3u8 index files are for indexing its corresponding TS slicing files, it can include many information for describing the TS files, Server-side can be by analyzing these description informations, so as to obtain the code check value of the TS files.
Further, second acquisition unit can be also used for:In the case that the form of the m3u8 files is solid size rate, obtain Take the size and duration of the TS files to be sent;According to TS described in the size and duration calculation of the TS files to be sent The code check value of slicing files;Alternatively, the form of the m3u8 files is in the case of multi code Rate of Chinese character, obtains in the m3u8 files The value of BANDWIDTH corresponding to the TS slicing files to be sent, and it is determined as the code check value of the TS slicing files.
In this embodiment, TS slicing files are there are many code check, corresponding m3u8 index files be also have it is different Code check form.Therefore according to m3u8 file acquisitions, the code check value of its corresponding TS slicing files and needs are literary according to m3u8 The form of part takes different technological means.In the case where m3u8 index file forms are solid size rate, server-side is can not The code check value of the corresponding TS files is directly acquired, needs further to parse the information that m3u8 index files describe TS files, The file size of TS files and file duration are obtained, the code check value of the TS files can be obtained according to calculation formula.Solid size rate lattice The m3u8 of formula is not comprising code rate information, it is therefore desirable to calculate in this way:Assuming that the size of file is S, the playing duration of file It is T, then the code rate V of this document is:Code rate V=S/T.It is big using file that the calculation formula is also used in the big files of common vod Small divided by file duration.In the case where m3u8 index files are multi code Rate of Chinese character, server-side can not be needed to through TS file sizes It carries out that code check value is calculated with file duration;But by analyzing the content information of m3u8 index files, multi code Rate of Chinese character form There are BANDWIDTH attributes in the label E XT-X-STREAM-INF therein of m3u8 files, BANDWIDTH property values just represent pair The code check of ts files in the sub- m3u8 files answered, therefore server-side parses the m3u8 of the multi code Rate of Chinese character form and can be obtained by correspondence TS files code check value V=BANDWIDTH.
In addition, in an embodiment of the present invention, in order to advanced optimize the service ability of server-side, further improve clothes The service ability at business end, the sending device of more than HLS files can also include being used for:According to server-side and the network feelings of client Condition sets at least one code check adjusting parameter, is calculated according to the code check value and the code check adjusting parameter, and obtain the TS The transmission rate of slicing files.The network speed of server-side is preferable or the client terminal quantity of same period request streaming media service Less or client network speed is preferable, can set a valve for being more than 1 based on experience value.According to this valve and TS The product of the code check value of file obtains sending the transmission rate of the TS files, and the transmission rate is necessarily more than the code check value. Certainly it can similarly obtain, the client terminal quantity of the network speed of server-side difference or the request streaming media service of same period is more, Or the network speed of client is poor, which could be provided as the decimal more than 0 and less than 1, and obtained transmission rate is necessarily Less than TS file code check values.One valve is set by actual conditions in this way, server-side can more effectively be controlled to send TS texts The rate of part code check further optimizes the service ability of server-side.
The embodiment of the present invention can also provide a kind of streaming media server, which can be with foregoing embodiments Shown in HLS file sending devices, such as include HLS files shown in Fig. 2 send device and its module.
In conjunction with specific embodiment, the present invention will be described below.
Fig. 3 is a kind of structure diagram of HLS files sending device according to the preferred embodiment of the invention.It as shown in figure 3, should Device can include:Code check computing module 30, code stream sending module 32.
Code check computing module 30 is mainly used for obtaining the code rate information of the media file of client request, can realize The same or like function of acquisition module 20 in literary embodiment.
Code check sending device 32 is connect with code check computing module 30, and being mainly used for please according to transmission rate transmission client The files in stream media asked can realize the same or like function of determining module 22 in foregoing embodiments, sending module 23.
In general, the network performance of server-side is good, and network transmission speed is fast, and the network performance of client is poor, net Network receive speed it is slow, even if therefore server-side send quickly, it is also desirable to wait for the slow reception of client.And server-side is to the greatest extent Files in stream media service is possibly provided, this is that one kind is greatly wasted to the service ability and resource of server-side.The relevant technologies In also not operatively solution.The HLS files sending device of the technical solution of the preferred implementation Li Caiyong of the present invention can wrap It includes:Code check computing module 30, code stream sending module 32.
1st, 30 main function of code check computing module is the code rate information for the media file for obtaining user's request, according to m3u8 texts The form of part is segmented into 2 kinds of situations of solid size rate and multi code Rate of Chinese character, and 2 kinds of different-format feelings of solid size rate and multi code Rate of Chinese character are described in detail below Code check computational methods under condition:
(1) the code check computational methods of the m3u8 files of solid size rate form.The m3u8 file samples of solid size rate form, it is as follows:
The m3u8 of solid size rate form is not comprising code rate information, it is therefore desirable to calculate in this way:
Assuming that the size of file is S, the playing duration of file is T, then the code rate V of this document is:Code rate V=S/T.The meter It calculates formula and is also used in the big files of common vod
(2) the code check computational methods of the m3u8 files of multi code Rate of Chinese character form, the m3u8 file samples of multi code Rate of Chinese character form are as follows:
There are BANDWIDTH attributes in the label E XT-X-STREAM-INF therein of the m3u8 files of multi code Rate of Chinese character form, BANDWIDTH property values just represent the code check of the ts files in corresponding sub- m3u8 files, therefore just have:Code rate V= BANDWIDTH
2nd, code stream sending module 32.One transmission of setting is needed according to the situation of network first on code stream sending module 32 Multiple M, the value are configurable, for example, it is 1 times or 2 times that code check, which sends multiple, are then got from code check computing module 30 The code rate V of media file, then the transmission speed speed of code stream be:Speed=V*M
Finally, code stream sending module 32 is just according to the transmission speed of the value control stream of speed.
Therefore, the device provided by the preferred embodiment of the present invention, server-side can ask Streaming Media text according to user terminal The code check of part determines to send the transmission rate of this document.Using the technical solution, can solve present in the relevant technologies, phase Present in the technology of pass, it can not be adjusted according to the actual conditions of client and send the rate of file code stream for server-side, make Into server-side resource waste the problem of, transmission Streaming Media can be carried out according to client actual request by realizing server end The transmission rate of file code check has saved server-side resource, improves the service ability of server-side.
Fig. 4 is a kind of flow diagram of the sending method of HLS files according to embodiments of the present invention.With reference to Fig. 4, The method flow of the preferred embodiment of the present invention is illustrated:
Step S400, user terminal request m3u8 services;
The request of client wants server-side plays media file service, and server receives user request, and user asks instruction To the corresponding m3u8 index files of requested TS files.
Step S402, judgement are solid size rate or multi code Rate of Chinese character;
M3u8 files are for describing its corresponding TS slicing files.Server-side may determine that the m3u8 ropes of user's request The form of quotation part, and the method flow performed according to the format determination of m3u8.M3u8 index files are according to corresponding TS files Can be solid size rate form or multi code Rate of Chinese character form.
In the case where m3u8 forms is solid size rates, step S404 is performed;Or in the situation that m3u8 forms are multi code Rate of Chinese character Under, perform step S406.
Step S404 according to TS file sizes and file duration, calculates the code check of TS files;
In the case where m3u8 forms is solid size rates, server-side can not directly obtain the code check of corresponding TS files.Clothes Business end can obtain the duration and size of TS files according to m3u8 files, according to file size divided by file duration, can obtain The code check of TS files.
Step S406 obtains the code check of the TS files according to bandwidth labels;
In the case where m3u8 forms is multi code Rate of Chinese character, m3u8 index files can directly describe its corresponding TS slicing files Code check.Server-side parses to obtain the bandwidth values in m3u8, which can directly characterize corresponding TS texts The code check value of part.
Step S404 or step S406 after, obtain the code check of TS files, can perform step 408.
Step S408 according to the code check of the TS files and default computation rule, calculates the transmission rate of code stream;
The transmission rate of transmission file that server-side final choice uses can there are many mode, according to TS files code check and Preset rules are that the preferred embodiment of the present invention proposes.It can wherein be set at least according to the network condition of server-side and client One code check adjusting parameter calculates according to the code check value and the code check adjusting parameter, and obtains the TS slicing files Transmission rate.The network speed of server-side is preferable or the client terminal quantity of same period request streaming media service is less or objective The network speed at family end is preferable, can set a valve for being more than 1 based on experience value.According to the code check value of this valve and TS files Product, obtain sending the transmission rates of the TS files, and the transmission rate is necessarily more than the code check value.It certainly similarly can be with It obtains, the client terminal quantity of the network speed of server-side difference or the request streaming media service of same period is more or client Network speed is poor, which could be provided as being more than 0 and the decimal less than 1, obtained transmission rate are necessarily less than TS file codes Rate value.
Step S410, server-side according to the transmission rate send the code check of TS files.
This preferred embodiment is taken, can realize that control server-side sends the rate of TS file code checks, optimize server-side Service ability provides the effective rate of utilization of server-side resource.
Example one, m3u8 index files form are the situation of solid size rate.
The content instance of HLS solid size rates is as follows
Step 1, user first ask the m3u8, since m3u8 files are smaller, do not need to speed limit, server can be returned directly Return the m3u8 files of client request.
M3u8 is equivalent to " index ".HLS, Http Live Streaming are to be used for real-time streams by what Apple companies defined The agreement of transmission, HLS realize that transferring content includes two parts, first, M3U8 describes file, second is that TS media based on http protocol File.
Step 2, user parse ts information therein, continue to ask 1.ts, request server passes according to the m3u8 of return Defeated stream (TS) slicing files.
M3u8 files can be used for describing the information of corresponding TS fragments small documents.
Step 3, server end receive 1.ts requests, a length of 10s when getting;
Step 4 obtains the size of 1.ts files, it is assumed that be 2MB;
Server-side according to the description informations of m3u8 files, can obtain its correspond to the file size of TS slicing files and when It is long.
Step 5, it is assumed that it is 2 times (configurable) to obtain and send multiple, and the transmission code check for calculating 1.ts is 2*2MB/10s =0.4MB/s;
A server-side can be set to send the variate-value of files in stream media based on experience value, such as in ts file code check values Multiple 2 is multiplied by basis.In the preferred embodiment, the code check of the corresponding TS files of solid size rate m3u8 is 2MB/10s= 0.2MB/s.According to calculation formula, the transmission rate finally obtained is v=0.2MB/s* multiples 2=0.4MB/s.
Step 6:Server sends its 1.ts file asked according to 0.4MB/s this rate progress code streams;
Step 7:User terminal asks others TS slicing files, can repeat the above steps one to step 6.
Example two, m3u8 file formats are the situation of multi code Rate of Chinese character.
The content instance of HLS multi code Rate of Chinese character is as follows
Level-one m3u8 contents are
1.m3u8 content is
2.m3u8,3.m3u8 contents it is similar.It is as follows to implement step:
Step 1, user first ask level-one m3u8, and since m3u8 files are smaller, server-side does not need to speed limit, directly return User terminal level-one m3u8;
Step 2, user parse information therein, a kind of code are selected according to the situation of terminal according to the level-one m3u8 of return Rate makes requests on, for example that ask is 1.m3u8;
Step 3, server end receive 1.m3u8 requests, since m3u8 files are smaller, do not need to speed limit, directly return;
Step 4, user get 1.m3u8, parse its content, continue to send request, for example be 1_1.ts;
Step 5, server-side receive 1_1.ts requests, its code check can be 800b/s according to level-one m3u8 content obtainings;
Step 6, it is assumed that it is 2 times (configurable) to obtain and send multiple, and the transmission code check for calculating 1_1.ts is 2*800b/s =1600b/s;
Step 7, server is according to the transmission of 1600b/s this rate progress code streams 1_1.ts files;
Step 8:User terminal continues to ask other ts, and server-side can repeat the above steps one to step 7.
Example one and example two describe the realization principle and step of the preferred embodiment of the present invention from different application scenarios, By the preferred embodiment, server-side can more effectively be controlled to send ts files in stream media rates, further improve stream matchmaker The service ability of body server.
In conclusion by above-described embodiment, preferred embodiment and embodiment, server-side can be asked according to user terminal The code check of files in stream media determines to send the transmission rate of this document.Using the technical solution, can solve to deposit in the relevant technologies , present in the relevant technologies, it can not be adjusted according to the actual conditions of client and send file code stream for server-side Rate, the problem of causing the waste of server-side resource, realizing server end can be sent out according to client actual request The transmission rate of files in stream media code check is sent, has saved server-side resource, improves the service ability of server-side.
Obviously, those skilled in the art should be understood that each module of the above-mentioned present invention or each step can be with general Computing device realize that they can concentrate on single computing device or be distributed in multiple computing devices and be formed Network on, optionally, they can be realized with the program code that computing device can perform, it is thus possible to which they are stored It is performed in the storage device by computing device, and in some cases, it can be to be different from shown in sequence herein performs The step of going out or describing they are either fabricated to each integrated circuit modules respectively or by multiple modules in them or Step is fabricated to single integrated circuit module to realize.It to be combined in this way, the present invention is not limited to any specific hardware and softwares.
The foregoing is only a preferred embodiment of the present invention, is not intended to restrict the invention, for the skill of this field For art personnel, the invention may be variously modified and varied.All within the spirits and principles of the present invention, that is made any repaiies Change, equivalent replacement, improvement etc., should all be included in the protection scope of the present invention.

Claims (10)

1. a kind of sending method of HTTP real time flow mediums HLS files, which is characterized in that including:
Obtain the code check value of transport stream TS slicing files to be sent;
The transmission rate of the TS slicing files to be sent is determined according to the code check value;
The TS slicing files are sent according to the transmission rate.
2. according to the method described in claim 1, it is characterized in that, obtain the code check of transport stream TS slicing files to be sent Value, including:
It obtains and sends m3u8 files, wherein, the m3u8 files are used to describe the TS slicing files to be sent;
The code check value of TS slicing files to be sent according to the m3u8 file acquisitions.
3. according to the method described in claim 2, it is characterized in that, according to the m3u8 file acquisitions TS slicing files Code check value, including:
In the case that the form of the m3u8 files is solid size rate, the size and duration of the TS files to be sent are obtained;
According to the code check value of TS slicing files described in the size and duration calculation of the TS files to be sent.
4. according to the method described in claim 2, it is characterized in that, according to the m3u8 file acquisitions TS slicing files Code check value, including:
In the case that the form of the m3u8 files is multi code Rate of Chinese character, the TS fragments to be sent in the m3u8 files are obtained The value of BANDWIDTH corresponding to file, and it is determined as the code check value of the TS slicing files.
5. according to Claims 1-4 any one method, which is characterized in that determined according to the code check value described to be sent The transmission rate of TS slicing files, including:At least one code check adjustment ginseng is set according to the network condition of server-side and client Number calculates according to the code check value and the code check adjusting parameter, and obtains the transmission rate of the TS slicing files.
6. a kind of sending device of HTTP real time flow mediums HLS files, which is characterized in that including:
Acquisition module, for obtaining the code check value of transport stream TS slicing files to be sent;
Determining module determines the transmission rate of the TS slicing files to be sent according to the code check value;
Sending module, for sending the TS slicing files according to the transmission rate.
7. device according to claim 6, which is characterized in that
The acquisition module includes:First acquisition unit, for obtaining and sending m3u8 files, wherein, the m3u8 files are used In the description TS slicing files to be sent;Second acquisition unit, for be sent according to the m3u8 file acquisitions TS slicing files code check value.
8. device according to claim 7, which is characterized in that the second acquisition unit is additionally operable to:
In the case that the form of the m3u8 files is solid size rate, the size and duration of the TS files to be sent are obtained;
According to the code check value of TS slicing files described in the size and duration calculation of the TS files to be sent;It is alternatively, described In the case that the form of m3u8 files is multi code Rate of Chinese character, the TS slicing files institute to be sent obtained in the m3u8 files is right The value of the BANDWIDTH answered, and it is determined as the code check value of the TS slicing files.
9. device according to claim 6, which is characterized in that the determining module is additionally operable to:According to server-side and client The network condition at end sets at least one code check adjusting parameter, is calculated according to the code check value and the code check adjusting parameter, and Obtain the transmission rate of the TS slicing files.
10. a kind of streaming media server, which is characterized in that including the device as described in claim 6 to 9 any one.
CN201611257282.9A 2016-12-30 2016-12-30 A kind of sending method and device of HTTP real time flow mediums HLS files Pending CN108271085A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201611257282.9A CN108271085A (en) 2016-12-30 2016-12-30 A kind of sending method and device of HTTP real time flow mediums HLS files

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201611257282.9A CN108271085A (en) 2016-12-30 2016-12-30 A kind of sending method and device of HTTP real time flow mediums HLS files

Publications (1)

Publication Number Publication Date
CN108271085A true CN108271085A (en) 2018-07-10

Family

ID=62754540

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201611257282.9A Pending CN108271085A (en) 2016-12-30 2016-12-30 A kind of sending method and device of HTTP real time flow mediums HLS files

Country Status (1)

Country Link
CN (1) CN108271085A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110740174A (en) * 2019-09-30 2020-01-31 北京字节跳动网络技术有限公司 File downloading speed limiting method and device and electronic equipment
US20220239960A1 (en) * 2021-01-28 2022-07-28 Openwave Mobility Inc. Method for determining a play duration estimate of an adaptive bit rate media presentation
US11622164B2 (en) 2019-07-12 2023-04-04 Carrier Corporation System and method for streaming video/s

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1655547A (en) * 2004-09-09 2005-08-17 上海川海信息科技有限公司 A speed control method in stream media transmission system
US20120079132A1 (en) * 2009-06-09 2012-03-29 Huawei Technologies Co., Ltd. Method, device, and system for self-adaptively adjusting data transmission rate
CN103533452A (en) * 2013-10-24 2014-01-22 中国联合网络通信集团有限公司 Transmission control method and device for streaming media
CN103546824A (en) * 2013-10-25 2014-01-29 中国科学院声学研究所 Method and device for controlling transmission rate of streaming media
CN104333818A (en) * 2014-10-17 2015-02-04 中兴通讯股份有限公司 Splicing method and splicing system for HTTP real-time streaming media fragment
CN104349176A (en) * 2013-07-30 2015-02-11 中国电信股份有限公司 Self-adaptive stream media system, downloading method and stream media server, user terminal
CN105898408A (en) * 2016-04-28 2016-08-24 乐视控股(北京)有限公司 Video play method and device

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1655547A (en) * 2004-09-09 2005-08-17 上海川海信息科技有限公司 A speed control method in stream media transmission system
US20120079132A1 (en) * 2009-06-09 2012-03-29 Huawei Technologies Co., Ltd. Method, device, and system for self-adaptively adjusting data transmission rate
CN104349176A (en) * 2013-07-30 2015-02-11 中国电信股份有限公司 Self-adaptive stream media system, downloading method and stream media server, user terminal
CN103533452A (en) * 2013-10-24 2014-01-22 中国联合网络通信集团有限公司 Transmission control method and device for streaming media
CN103546824A (en) * 2013-10-25 2014-01-29 中国科学院声学研究所 Method and device for controlling transmission rate of streaming media
CN104333818A (en) * 2014-10-17 2015-02-04 中兴通讯股份有限公司 Splicing method and splicing system for HTTP real-time streaming media fragment
CN105898408A (en) * 2016-04-28 2016-08-24 乐视控股(北京)有限公司 Video play method and device

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11622164B2 (en) 2019-07-12 2023-04-04 Carrier Corporation System and method for streaming video/s
CN110740174A (en) * 2019-09-30 2020-01-31 北京字节跳动网络技术有限公司 File downloading speed limiting method and device and electronic equipment
US20220239960A1 (en) * 2021-01-28 2022-07-28 Openwave Mobility Inc. Method for determining a play duration estimate of an adaptive bit rate media presentation
US11595708B2 (en) * 2021-01-28 2023-02-28 Openwave Mobility Inc. Method for determining a play duration estimate of an adaptive bit rate media presentation

Similar Documents

Publication Publication Date Title
EP3340633B1 (en) Terminal, cache server, and method for acquiring video slices and device thereof
CN102611945B (en) Streaming media slicing method, slicing server and streaming media demand system
Thang et al. Adaptive streaming of audiovisual content using MPEG DASH
US9923771B2 (en) Adaptive bitrate modification of a manifest file
TWI593282B (en) Method and apparatus for providing a plurality of transcoded content streams
US20120124179A1 (en) Traffic management in adaptive streaming protocols
US20100312828A1 (en) Server-controlled download of streaming media files
CN104967872B (en) Live broadcasting method and server based on dynamic self-adapting code rate transport protocol HLS Streaming Media
CN109964488A (en) The quality and user experience of the live video stream transmission from mobile device are improved using converging network statistics
CN106303562B (en) Multi-view point video adaptive transmitted control algorithm based on PI control
JP7496022B2 (en) Client, server, receiving method and transmitting method
CN108271085A (en) A kind of sending method and device of HTTP real time flow mediums HLS files
CN107920108A (en) A kind of method for pushing of media resource, client and server
CN108833350B (en) A data transmission method suitable for multi-server adaptive streaming media system
CN106453270B (en) Adaptive Transmission Algorithm Based on PI Controlled Streaming Media
CN106454317B (en) Stereoscopic video quality adaptive algorithm based on fuzzy control
CN102291412B (en) A kind of multimedia service realization method based on HTTP, system and device
CN106598966B (en) Webpage processing method and device
CN104683833B (en) The method and device of adaptive media service
CN104581424B (en) A kind of flow-medium transmission method, relevant device and system
Evensen et al. Adaptive media streaming to mobile devices: challenges, enhancements, and recommendations
EP3522498B1 (en) A method for streaming an audio video content
US20240155019A1 (en) Synchronizing independent media and data streams using media stream synchronization points
CN108737355A (en) Streaming media playing based on user bandwidth
Noh et al. Congestion‐aware HTTP adaptive streaming system over SDN‐enabled Wi‐Fi network

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20180710