CN105992044A - Method and system of transcoding HLS to RTMP live streaming - Google Patents

Method and system of transcoding HLS to RTMP live streaming Download PDF

Info

Publication number
CN105992044A
CN105992044A CN201510060833.1A CN201510060833A CN105992044A CN 105992044 A CN105992044 A CN 105992044A CN 201510060833 A CN201510060833 A CN 201510060833A CN 105992044 A CN105992044 A CN 105992044A
Authority
CN
China
Prior art keywords
rtmp
data
flow data
hls
stream
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
CN201510060833.1A
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.)
TVM Beijing Technology Co Ltd
Original Assignee
TVM Beijing Technology 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 TVM Beijing Technology Co Ltd filed Critical TVM Beijing Technology Co Ltd
Priority to CN201510060833.1A priority Critical patent/CN105992044A/en
Publication of CN105992044A publication Critical patent/CN105992044A/en
Pending legal-status Critical Current

Links

Landscapes

  • Information Transfer Between Computers (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)

Abstract

The invention discloses a method and system of transcoding HLS (HTTP Live Streaming) to RTMP (Real Time Messaging Protocol) live streaming. The method comprises the steps: according to pre-configuration, downloading an HLS audio and video stream and acquiring a corresponding M3U8 file; according to the M3U8 file, decoding the HLS audio and video stream to obtain the corresponding TS (Transport Stream) data; re-encapsulating the TS data into RTMP stream data and pushing the RTMP stream data to a streaming media server; and pushing the RTMP stream data to a live broadcast user through the streaming media server. The scheme of the method and system of transcoding HLS to RTMP live streaming can convert HLS into RTMP live streaming to enable a mobile phone player or a flash player to directly play videos, can convert and output multi-channel of RTMP live steaming at the same time, and has the advantages of being high in performance and stability, wherein videos can be watched directly in the flash. Besides, the scheme of the method and system of transcoding HLS to RTMP live streaming can convert video streaming, and also can only convert audio streaming, wherein the RTMP audio streaming can be used for radio broadcast, so that the user experience degree is greatly improved.

Description

A kind of method and system of HLS transcoding RTMP live TV stream
Technical field
The present invention relates to Internet technical field, particularly to the side of a kind of HLS transcoding RTMP live TV stream Method and system.
Background technology
HLS (HTTP Live Streaming) is the dynamic code rate adaptive technique of Apple (Fructus Mali pumilae) company. It is mainly used in the audio frequency and video service of PC (PC) and Apple terminal.Rope including a M3U8 Quotation part, TS media slicing file and ke encrypt string file.
Conventional stream media protocol mainly has HTTP progressive download and real-time streams matchmaker based on RTSP/RTP Body agreement, these two kinds are substantially diverse thing, the most more convenient the most handy be with HTTP gradually Enter method for down loading.Generation in terms of the HTTP Live Streaming of Apple company is this in this Table.It is initially that Apple develops for mobile devices such as iPhone, iPod, iTouch and iPad Stream. seeing now also to have at desktop and much apply, HTML5 is directly to support this.
But the little slicing mode of HLS protocol can generate substantial amounts of file, store or process these file meetings Ample resources is caused to waste.If the time shift of a couple of days to be realized, index amount would is that a huge numeral, and bright Development rings request speed.Therefore, storage I/O is required quite harsh by HLS protocol.To this, Ye You company Propose extraordinary solution.Novel hand sowing server system, has created memory cache data and has cut in real time Chip technology, has overturned this traditional implementation, fundamentally solves the fragment problems of a large amount of section, makes The section obtaining single server is no longer bottleneck with packing ability.Its ultimate principle is as follows:
File of not cut into slices by TS is stored to disk, but exists in the middle of internal memory, and this technology makes server No longer have the file fragmentation of " tons of " above disk, greatly reduce I/O number of disk, extend Service life of server disk, greatly improve the stability that server runs.Simultaneously as use This technology so that directly obtain from the internal memory of server during terminal request data, greatly improve end The response speed of end data request, optimizes video viewing experience.
RTMP is the initial contracting of Real Time Messaging Protocol (real-time messages host-host protocol) Write.This agreement, based on TCP, is a protocol family, including RTMP basic agreement and The multiple mutation such as RTMPT/RTMPS/RTMPE.RTMP is that one is designed to carry out real time data and leads to The procotol of letter, is mainly used at Flash/AIR platform and the Streaming Media/take alternately of supporting RTMP agreement Audio frequency and video and data communication is carried out between business device.The software supporting this agreement includes Adobe Media Server/Ultrant Media Server/red5 etc..
In prior art, various smart machines the most only support the live TV stream of RTMP form.General flash Player and android mobile phone player, or the player on PC all can not directly play HLS Live TV stream, i.e. can not play m3u8 live TV stream.Thus, need badly and want a kind of and new can meet user's intelligence Equipment plays the scheme needed for live TV stream, to improve user experience.
Summary of the invention
The present invention provides the method and system of a kind of HLS transcoding RTMP live TV stream, in order to solve existing skill In art, HLS cannot the problem of direct transcoding RTMP live TV stream.
The present invention provides a kind of method of HLS transcoding RTMP live TV stream, including:
According to being pre-configured with download HLS audio/video flow and obtaining corresponding M3U8 file;
Corresponding TS flow data is obtained according to HLS audio/video flow described in described M3U8 file decoding;
Described TS flow data Reseal is become RTMP flow data and is pushed to streaming media server;
Described streaming media server pushes described RTMP flow data to live user.
Described method also includes:
The HLS audio/video flow of download according to corresponding M3U8 file acquisition corresponding TS file and is spliced Corresponding TS is become to flow;
Corresponding TS flow data is obtained according to described TS stream decoding.
Described method also includes:
Described TS flow data is become RTMP flow data according to X264 encoder Reseal.
Described method also includes:
Described TS flow data is recompiled as h264 and aac data;
Described h264 and aac data are re-packaged into RTMP flow data.
Described method also includes:
Described RTMP flow data only includes audio stream data.
Described method also includes:
Described streaming media server is wowza server;
Described RTMP flow data is issued by described wowza server.
A kind of system of HLS transcoding RTMP live TV stream, including:
Download unit, for according to being pre-configured with download HLS audio/video flow and obtaining corresponding M3U8 literary composition Part;
Decoding unit, for obtaining according to HLS audio/video flow described in described M3U8 file decoding accordingly TS flow data;
Encapsulation unit, for becoming RTMP flow data and being pushed to stream by described TS flow data Reseal Media server element;
Streaming media server unit, is used for pushing described RTMP flow data to live user.
Described system also includes:
Concatenation unit, corresponding according to corresponding M3U8 file acquisition for the HLS audio/video flow that will download TS file and be spliced into corresponding TS stream;
Described decoding unit obtains corresponding TS flow data according to described TS stream decoding.
Described system also includes:
Coding unit, for recompiling described TS flow data as h264 and aac data;
Described h264 and aac data are re-packaged into RTMP flow data by described encapsulation unit.
Described system also includes:
Described encapsulation unit is additionally operable to become described TS flow data Reseal only include voice data RTMP flow data is also pushed to described streaming media server unit;
Described streaming media server unit is additionally operable to only include described in propelling movement the RTMP flow data of voice data To live user.
The embodiment of the present invention is according to being pre-configured with download HLS audio/video flow and obtaining corresponding M3U8 file; Corresponding TS flow data is obtained according to HLS audio/video flow described in described M3U8 file decoding;By described TS flow data Reseal becomes RTMP flow data and is pushed to streaming media server;Described Streaming Media takes Business device pushes described RTMP flow data to live user.The scheme of the embodiment of the present invention, it is possible to by HLS Live TV stream changes into RTMP live TV stream and directly plays video for mobile phone player or flash player, simultaneously can To produce multichannel RTMP live TV stream, performance is high, good stability, can in flash direct viewing video. Meanwhile, both can turn video flowing, it is possible to only turn audio stream, RTMP audio stream can do station broadcast use, greatly Improve user experience.
Other features and advantages of the present invention will illustrate in the following description, and, partly from explanation Book becomes apparent, or understands by implementing the present invention.The purpose of the present invention and other advantages can Realize by structure specifically noted in the description write, claims and accompanying drawing and obtain ?.
Below by drawings and Examples, technical scheme is described in further detail.
Accompanying drawing explanation
Accompanying drawing is for providing a further understanding of the present invention, and constitutes a part for description, with this Bright embodiment is used for explaining the present invention together, is not intended that limitation of the present invention.In the accompanying drawings:
The Method And Principle stream of a kind of HLS transcoding RTMP live TV stream that Fig. 1 provides for the embodiment of the present invention 1 Cheng Tu;
Fig. 2 shows for the system structure of a kind of HLS transcoding RTMP live TV stream that the embodiment of the present invention 3 provides It is intended to.
Detailed description of the invention
Below in conjunction with accompanying drawing, the preferred embodiments of the present invention are illustrated, it will be appreciated that described herein Preferred embodiment is merely to illustrate and explains the present invention, is not intended to limit the present invention.
As it is shown in figure 1, the side of a kind of HLS transcoding RTMP live TV stream provided for the embodiment of the present invention 1 Method principle flow chart, wherein,
Step 11, according to being pre-configured with download HLS audio/video flow and obtaining corresponding M3U8 file.
In the present embodiment, it is necessary first to obtain HLS audio/video flow.Here for the acquisition of HLS stream, can To carry out according to download policy set in advance, it is also possible to carry out according to the address that user specifies.Such as, may be used With pre-configured download policy, after strategy comes into force, carry out concrete download according to this download policy.
Generally, HLS is the dynamic code rate adaptive technique of Apple.It is mainly used in PC and Apple terminal Audio frequency and video service.Illustration and text juxtaposed setting is encrypted including the index file of a M3U8, TS media slicing file and ke Part.M3U8 is also a kind of M3U, and simply its coded format is UTF-8 form.M3U Latin-1 Character set encoding.M3U is the directory information of song, when downloading the audio frequency of FLAC lossless format, and meeting With a M3U catalogue file.
The partition strategy of HLS, substantially recommending is 10 seconds bursts, and certainly, the concrete time also wants root Mark as a rule according to the actual duration of the burst after dividing well, for the reason of the aspects such as caching, at index File can retain up-to-date three burst address, with the form of similar " sliding window ", be updated. M3U8, is index file live for HTTP Live Streaming.M3U8 is substantially it is believed that just Being .m3u formatted file, difference is, M3U8 file uses UTF-8 character code.
Such as, shown in specific as follows:
Thus, obtain corresponding M3U8 file, just obtain the index of HLS audio/video flow, Ke Yiju This decoding HLS audio/video flow file is TS file.
Step 12, obtains corresponding TS fluxion according to M3U8 file decoding height code check HLS audio/video flow According to.
The HLS audio/video flow of download according to corresponding M3U8 file acquisition corresponding TS file and is spliced Corresponding TS is become to flow;Corresponding TS flow data is obtained according to TS stream decoding.
TS flow data is become RTMP flow data according to X264 encoder Reseal.
M3U8 download module can download the M3U8 live TV stream of 2.5M code check according to configuration file, downloading M3U8 live TV stream give TS concatenation module and be combined into TS live TV stream with being stored in shared drive.TS decompresses Contracting module can be taken out TS live TV stream data from shared drive and be decompressed, and solves video data and audio frequency Data.
M3U8 file can be distributed by the mode of http on IOS device and mac, wherein playlist Standard is the M3U8 file expanded by m3u, and media file is MPEG2-TS or AAC file (audio only)。
M3U8 file has two kinds of application scenarios:
1, multi code Rate of Chinese character adaptation stream.
#EXTM3U
#EXT-X-STREAM-INF:PROGRAM-ID=1, BANDWIDTH=1280000
http://example.com/low.M3U8
#EXT-X-STREAM-INF:PROGRAM-ID=1, BANDWIDTH=2560000
http://example.com/mid.M3U8
#EXT-X-STREAM-INF:PROGRAM-ID=1, BANDWIDTH=7680000
http://example.com/hi.M3U8
#EXT-X-STREAM-INF:PROGRAM-ID=1, BANDWIDTH=65000, CODECS= "mp4a.40.5"
http://example.com/audio-only.M3U8
2, single rate adaption stream.
#EXTM3U
#EXT-X-TARGETDURATION:5220
#EXTINF:5220,
http://media.example.com/entire.ts
#EXT-X-ENDLIST
This definition is by International Standards Organization:
rfc doc:http://tools.ietf.org/html/draft-pantos-http-live-streaming-06
M3U8 file is the extension of m3u file.At the keyword of extension defined in this rfc, wherein:
#EXT-X-TARGETDURATION
Define the maximum duration of each TS.
#EXT-X-MEDIA-SEQUENCE
Defining the serial number of first file in current M3U8 file, each ts file is at M3U8 file In have fixing unique serial number, this serial number for when MBR switching code rate align.
#EXT-X-KEY
Definition cipher mode and the url of key file, for obtaining the key file decoding ts file of 16bytes.
Attribute:
METHOD
URL
#EXT-X-PROGRAM-DATE-TIME
The absolute time of first file
#EXT-X-ALLOW-CACHE
Whether allow cache.
#EXT-X-ENDLIST
Show the end of M3U8 file.Live M3U8 not this tag.
#EXT-X-STREAM-INF
Attribute:
BANDWIDTH specifies code check
The unique ID of PROGRAM-ID
CODECS specifies the type of coding of stream
#EXT-X-DISCONTINUITY
When running into this tag when, explanation there occurs change with properties:
file format
number and type of tracks
encoding parameters
encoding sequence
timestamp sequence
This attribute of #EXT-X-VERSION use and disuse can, can not have.
M3U8 divides top M3U8 and two grades of M3U8, top M3U8 mainly to do multi code Rate of Chinese character adaptation, Two grades of M3U8 are only real section file, and first client acquiescence can select the request that code check is the highest, as Fruit finds that code check does not reaches, and can ask the stream of suburb low bit-rate.
One actually used in top M3U8 file as follows:
#EXTM3U
#EXT-X-STREAM-INF:PROGRAM-ID=201273221265, BANDWIDTH=358 400
11.M3U8
#EXT-X-STREAM-INF:PROGRAM-ID=201273221265, BANDWIDTH=972 800
22.M3U8
The most top M3U8 file defines again two second grade files of 11.M3U8 and 22.M3U8, Client can select one of them to obtain its content.
Two grades of M3U8 file contents are as follows:
#EXTM3U
#EXT-X-VERSION:1
#EXT-X-TARGETDURATION:10
#EXT-X-MEDIA-SEQUENCE:0
#EXTINF:3,
1-4.ts
#EXTINF:8,
1-6.ts
#EXTINF:8,
1-8.ts
#EXTINF:8,
1-10.ts
#EXTINF:8,
1-12.ts
#EXTINF:8,
1-14.ts
#EXTINF:8,
1-16.ts
#EXTINF:9,
1-18.ts
#EXTINF:6,
1-20.ts
#EXTINF:8,
1-22.ts
#EXTINF:9,
1-24.ts
#EXTINF:3,
1-26.ts
#EXT-X-ENDLIST
After client takes two grades of M3U8 files above, may proceed to the file inside request, the most just may be used Play out.
The above is the situation of program request, live situation, has attribute and tell it is live inside M3U8 file, Client can the next M3U8 file that please look for novelty of timing.
Step 13, becomes RTMP flow data by TS flow data Reseal and is pushed to streaming media server.
As it has been described above, M3U8 file is an index file, this sound can be obtained according to M3U8 file and regard The TS fragment file that frequency file is corresponding.TS be stream storage format, wherein, each audio-video document by It is divided into several TS fragment files.Each TS fragment file correspond to a bit of interior of this audio-video document Hold.
TS flow data is recompiled h264 and the aac data into low bit-rate;By h264 and aac data It is re-packaged into RTMP flow data.
TS: full name is MPEG2-TS.The TS i.e. abbreviation of " Transport Stream ".It is that subpackage sends , each wraps a length of 188 bytes (the also bag of 192 and 204 bytes).The structure of bag is, bag Head is 4 bytes (first character joint is 0x47), and load is 184 bytes.Can fill out in TS flows Enter the most eurypalynous data, such as video, audio frequency, self-defined information etc..MPEG2-TS is mainly used in reality Time transmit program, the TV programme of such as real-time broadcast.The feature of MPEG2-TS form require exactly from Arbitrary fragment of video flowing starts all can independently decode.Briefly, by the VOB on DVD Before file, one section of cut falls (or corrupted data data) and may result in whole file and cannot decode, And TV programme are whenever to turn on television set to decode (watching).
One section of TS stream, it is necessary to comprise PAT bag, PMT bag, multiple audio pack, multiple video bag, multiple PCR bag and other information bags.Resolve the flow process of TS flow data: searching PID is the bag of 0x0, solves Program_map_PID in analysis PAT, PAT bag represents the PID of PMT;Search PMT, PMT bag In elementary_PID represent that the PCR_PID in PID, the PMT bag of audio frequency and video bag represents PCR's PID, the PID of PCR is identical with the PID of audio frequency or video sometimes, illustrates that PCR can circulate sound The bag of video, notes resolving, and PCR is that oneself individually wraps sometimes;CAT、NIT、SDT、EIT PID be respectively as follows: 0x01,0x10,0x11,0x12.
RTMP agreement, based on TCP, is a protocol family, including RTMP basic agreement and The multiple mutation such as RTMPT/RTMPS/RTMPE.RTMP is that one is designed to carry out real time data and leads to The procotol of letter, is mainly used at Flash/AIR platform and the Streaming Media/take alternately of supporting RTMP agreement Audio frequency and video and data communication is carried out between business device.The software supporting this agreement includes Adobe Media Server/Ultrant Media Server/red5 etc..
RTMP agreement has three kinds of mutation: be operated in the plaintext agreement on TCP, uses port 1935; RTMPT is encapsulated among HTTP request, can pass through fire wall;RTMPS is similar to RTMPT, but uses Be HTTPS connect.
In this step, give data coding module data.This coding module can call X264 encoder and compile Become h264 and the aac data of 3 kinds of low bit-rate, and these data are put in chained list.Another thread meeting Reading h264 Yu aac data from chained list, the wowza being pushed to configuration by RTMP protocol encapsulation is taken On business device.
Step 14, streaming media server pushes RTMP flow data to live user.
Will outwards be issued by streaming media server (wowza server) and push data up, use flash Player, the ordinary playing device on meeting mobile phone just may be viewed by RTMP live TV stream, if only push is audio frequency, Then only has sound.
The method of a kind of HLS transcoding RTMP live TV stream that the embodiment of the present invention 2 provides, wherein,
PHP administration interface is used for configuring HLS and accesses source and wowza server address (for issuing RTMP Service).After configuration is good, having startup stop button, click on after starting, backstage can be opened according to interface configurations A dynamic process.This configuration can also be configured and only pushes audio stream, i.e. removes video, only pushes sound, so Broadcasting the RTMP stream come is only sound, can do music radio station and use.This process can according to configuration first Go to HLS source station to download m3u8 and TS live TV stream, then TS fragment is delivered in decoder module.Solve TS deblocking can be installed to h264 Yu aac data by code module, then these data is stored in chained list.The most another One thread can read h264 Yu aac data from chained list, is pushed to configuration by RTMP protocol encapsulation Wowza server on, now wowza server will outwards issue the data pushed up, uses flash Player, the ordinary playing device on meeting mobile phone just may be viewed by RTMP live TV stream, if only push is audio frequency, Then only has sound.
PHP (Hypertext Preprocessor, HyperText Preprocessor) is a kind of general script language of increasing income Speech.Grammer absorbs the feature of C language, Java and Perl, is beneficial to study, uses extensively, is primarily adapted for use in Web development field.Grammer unique for PHP is mixed with C, Java, Perl and PHP grammer from wound.It Dynamic web page can be more quickly performed than CGI or Perl.The dynamic page made with PHP with other Programming language is compared, and PHP is that program is embedded into HTML (application under standard generalized markup language) Going in document to perform, the CGI that execution efficiency ratio generates HTML markup completely is many higher;PHP is all right Performing compiled code, compiling can reach encryption and Optimized code runs, and makes code run faster.
In the present embodiment, a system server can produce 20 road rtmp live TV streams, and performance is high, stability Good, can in flash direct viewing video.Native system suddenly can turn video, it is possible to only turns audio frequency, rtmp sound Frequently stream can do station broadcast use.
As in figure 2 it is shown, for the embodiment of the present invention 3 provide a kind of HLS transcoding RTMP live TV stream be System structural representation, wherein,
Download unit 31, for according to being pre-configured with download HLS audio/video flow and obtaining corresponding M3U8 File;
Decoding unit 32, for obtaining corresponding TS stream according to M3U8 file decoding HLS audio/video flow Data;
Encapsulation unit 33, for becoming RTMP flow data by described TS flow data Reseal and be pushed to Streaming media server unit 34;
Streaming media server unit 34, is used for pushing RTMP flow data to live user.
Particularly, said system also includes:
Concatenation unit 35, the HLS audio/video flow being used for downloading is according to corresponding M3U8 file acquisition phase The TS file answered also is spliced into corresponding TS stream;
Decoding unit 32 obtains corresponding TS flow data according to TS stream decoding.
Particularly, said system also includes:
Coding unit 36, for recompiling h264 and the aac data into low bit-rate by TS flow data;
H264 and aac data are re-packaged into RTMP flow data by encapsulation unit 33.
Particularly, said system also includes:
Encapsulation unit 33 is additionally operable to TS flow data Reseal becomes the RTMP only including voice data Flow data is also pushed to streaming media server unit 34;
Streaming media server unit 34 is additionally operable to push and only includes that the RTMP flow data of voice data is to live User.
In sum, the embodiment of the present invention is according to being pre-configured with download HLS audio/video flow and obtaining corresponding M3U8 file;Corresponding TS fluxion is obtained according to HLS audio/video flow described in described M3U8 file decoding According to;Described TS flow data Reseal is become RTMP flow data and is pushed to streaming media server;Institute State streaming media server and push described RTMP flow data to live user.The scheme of the embodiment of the present invention, energy Enough RTMP live TV streams that changed into by HLS live TV stream directly play video for mobile phone player or flash player, Can produce multichannel RTMP live TV stream, performance is high simultaneously, and good stability can direct viewing in flash Video.Meanwhile, both can turn video flowing, it is possible to only turn audio stream, RTMP audio stream can do station broadcast use, Greatly improve user experience.
Those skilled in the art are it should be appreciated that embodiments of the invention can be provided as method, system or meter Calculation machine program product.Therefore, the present invention can use complete hardware embodiment, complete software implementation or knot The form of the embodiment in terms of conjunction software and hardware.And, the present invention can use and wherein wrap one or more Computer-usable storage medium containing computer usable program code (include but not limited to disk memory and Optical memory etc.) form of the upper computer program implemented.
The present invention is with reference to method, equipment (system) and computer program product according to embodiments of the present invention The flow chart of product and/or block diagram describe.It should be understood that can by computer program instructions flowchart and / or block diagram in each flow process and/or flow process in square frame and flow chart and/or block diagram and/ Or the combination of square frame.These computer program instructions can be provided to general purpose computer, special-purpose computer, embedding The processor of formula datatron or other programmable data processing device is to produce a machine so that by calculating The instruction that the processor of machine or other programmable data processing device performs produces for realizing at flow chart one The device of the function specified in individual flow process or multiple flow process and/or one square frame of block diagram or multiple square frame.
These computer program instructions may be alternatively stored in and computer or the process of other programmable datas can be guided to set In the standby computer-readable memory worked in a specific way so that be stored in this computer-readable memory Instruction produce and include the manufacture of command device, this command device realizes in one flow process or multiple of flow chart The function specified in flow process and/or one square frame of block diagram or multiple square frame.
These computer program instructions also can be loaded in computer or other programmable data processing device, makes Sequence of operations step must be performed to produce computer implemented place on computer or other programmable devices Reason, thus the instruction performed on computer or other programmable devices provides for realizing flow chart one The step of the function specified in flow process or multiple flow process and/or one square frame of block diagram or multiple square frame.
Obviously, those skilled in the art can carry out various change and modification without deviating from this to the present invention The spirit and scope of invention.So, if these amendments of the present invention and modification belong to the claims in the present invention And within the scope of equivalent technologies, then the present invention is also intended to comprise these change and modification.

Claims (10)

1. the method for a HLS transcoding RTMP live TV stream, it is characterised in that including:
According to being pre-configured with download HLS audio/video flow and obtaining corresponding M3U8 file;
Corresponding TS flow data is obtained according to HLS audio/video flow described in described M3U8 file decoding;
Described TS flow data Reseal is become RTMP flow data and is pushed to streaming media server;
Described streaming media server pushes described RTMP flow data to live user.
2. the method for claim 1, it is characterised in that described method also includes:
The HLS audio/video flow of download according to corresponding M3U8 file acquisition corresponding TS file and is spliced Corresponding TS is become to flow;
Corresponding TS flow data is obtained according to described TS stream decoding.
3. the method for claim 1, it is characterised in that described method also includes:
Described TS flow data is become RTMP flow data according to X264 encoder Reseal.
4. the method as described in claim 1 or 3, it is characterised in that described method also includes:
Described TS flow data is recompiled as h264 and aac data;
Described h264 and aac data are re-packaged into RTMP flow data.
5. the method for claim 1, it is characterised in that described method also includes:
Described RTMP flow data only includes audio stream data.
6. the method for claim 1, it is characterised in that described method also includes:
Described streaming media server is wowza server;
Described RTMP flow data is issued by described wowza server.
7. the system of a HLS transcoding RTMP live TV stream, it is characterised in that including:
Download unit, for according to being pre-configured with download HLS audio/video flow and obtaining corresponding M3U8 literary composition Part;
Decoding unit, for obtaining according to HLS audio/video flow described in described M3U8 file decoding accordingly TS flow data;
Encapsulation unit, for becoming RTMP flow data and being pushed to stream by described TS flow data Reseal Media server element;
Streaming media server unit, is used for pushing described RTMP flow data to live user.
8. system as claimed in claim 7, it is characterised in that described system also includes:
Concatenation unit, corresponding according to corresponding M3U8 file acquisition for the HLS audio/video flow that will download TS file and be spliced into corresponding TS stream;
Described decoding unit obtains corresponding TS flow data according to described TS stream decoding.
9. system as claimed in claim 7, it is characterised in that described system also includes:
Coding unit, for recompiling described TS flow data as h264 and aac data;
Described h264 and aac data are re-packaged into RTMP flow data by described encapsulation unit.
10. system as claimed in claim 7, it is characterised in that described system also includes:
Described encapsulation unit is additionally operable to become described TS flow data Reseal only include voice data RTMP flow data is also pushed to described streaming media server unit;
Described streaming media server unit is additionally operable to only include described in propelling movement the RTMP flow data of voice data To live user.
CN201510060833.1A 2015-02-05 2015-02-05 Method and system of transcoding HLS to RTMP live streaming Pending CN105992044A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510060833.1A CN105992044A (en) 2015-02-05 2015-02-05 Method and system of transcoding HLS to RTMP live streaming

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510060833.1A CN105992044A (en) 2015-02-05 2015-02-05 Method and system of transcoding HLS to RTMP live streaming

Publications (1)

Publication Number Publication Date
CN105992044A true CN105992044A (en) 2016-10-05

Family

ID=57037833

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510060833.1A Pending CN105992044A (en) 2015-02-05 2015-02-05 Method and system of transcoding HLS to RTMP live streaming

Country Status (1)

Country Link
CN (1) CN105992044A (en)

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106507115A (en) * 2016-11-30 2017-03-15 上海爱葛网络科技有限公司 Based on the coding/decoding method of the VR videos of iOS device, device and terminal device
CN106713361A (en) * 2017-02-24 2017-05-24 宁波联视网络科技有限公司 Multi-terminal multi-protocol streaming media release method
CN108391176A (en) * 2018-04-09 2018-08-10 四川百视通科技有限公司 The real time conversion system and its working method of a kind of RTMP agreements to HLS protocol
CN109714540A (en) * 2019-02-26 2019-05-03 浪潮软件集团有限公司 A kind of H265 format monitor video merging method, device and system
CN111901692A (en) * 2020-08-06 2020-11-06 杭州当虹科技股份有限公司 System for synthesizing VR (virtual reality) based on multi-audio and video streams
CN112995714A (en) * 2021-04-08 2021-06-18 天津天地伟业智能安全防范科技有限公司 Method and device for converting private video stream into RTMP standard stream
CN113382278A (en) * 2021-06-11 2021-09-10 中国电信股份有限公司 Video pushing method and device, electronic equipment and readable storage medium
CN114363303A (en) * 2021-12-31 2022-04-15 上海网达软件股份有限公司 Stream media transcoding method for realizing quick playing of monitoring video

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120170642A1 (en) * 2011-01-05 2012-07-05 Rovi Technologies Corporation Systems and methods for encoding trick play streams for performing smooth visual search of media encoded for adaptive bitrate streaming via hypertext transfer protocol
CN103826139A (en) * 2014-02-27 2014-05-28 北京六间房科技有限公司 CDN system, watching server and streaming media data transmission method
CN103986942A (en) * 2014-06-05 2014-08-13 北京赛维安讯科技发展有限公司 Data distribution system and method based on CDN (content distribution network)
CN104243430A (en) * 2013-06-20 2014-12-24 腾讯科技(深圳)有限公司 Streaming media playing method and device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120170642A1 (en) * 2011-01-05 2012-07-05 Rovi Technologies Corporation Systems and methods for encoding trick play streams for performing smooth visual search of media encoded for adaptive bitrate streaming via hypertext transfer protocol
CN104243430A (en) * 2013-06-20 2014-12-24 腾讯科技(深圳)有限公司 Streaming media playing method and device
CN103826139A (en) * 2014-02-27 2014-05-28 北京六间房科技有限公司 CDN system, watching server and streaming media data transmission method
CN103986942A (en) * 2014-06-05 2014-08-13 北京赛维安讯科技发展有限公司 Data distribution system and method based on CDN (content distribution network)

Cited By (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106507115A (en) * 2016-11-30 2017-03-15 上海爱葛网络科技有限公司 Based on the coding/decoding method of the VR videos of iOS device, device and terminal device
CN106507115B (en) * 2016-11-30 2019-10-15 上海音绮文化发展有限公司 Coding/decoding method, device and the terminal device of VR video based on iOS device
CN106713361A (en) * 2017-02-24 2017-05-24 宁波联视网络科技有限公司 Multi-terminal multi-protocol streaming media release method
CN108391176A (en) * 2018-04-09 2018-08-10 四川百视通科技有限公司 The real time conversion system and its working method of a kind of RTMP agreements to HLS protocol
CN109714540A (en) * 2019-02-26 2019-05-03 浪潮软件集团有限公司 A kind of H265 format monitor video merging method, device and system
CN111901692A (en) * 2020-08-06 2020-11-06 杭州当虹科技股份有限公司 System for synthesizing VR (virtual reality) based on multi-audio and video streams
CN112995714A (en) * 2021-04-08 2021-06-18 天津天地伟业智能安全防范科技有限公司 Method and device for converting private video stream into RTMP standard stream
CN113382278A (en) * 2021-06-11 2021-09-10 中国电信股份有限公司 Video pushing method and device, electronic equipment and readable storage medium
CN113382278B (en) * 2021-06-11 2022-09-09 天翼云科技有限公司 Video pushing method and device, electronic equipment and readable storage medium
CN114363303A (en) * 2021-12-31 2022-04-15 上海网达软件股份有限公司 Stream media transcoding method for realizing quick playing of monitoring video
CN114363303B (en) * 2021-12-31 2023-06-02 上海网达软件股份有限公司 Streaming media transcoding method for realizing rapid playing of surveillance video

Similar Documents

Publication Publication Date Title
CN105992044A (en) Method and system of transcoding HLS to RTMP live streaming
Sodagar The mpeg-dash standard for multimedia streaming over the internet
CN106471574B (en) Information processing apparatus, information processing method, and computer program
US20120233345A1 (en) Method and apparatus for adaptive streaming
US20170245022A1 (en) Splicing method and splicing system for http live streaming media fragment
CN105828096B (en) Method and device for processing media stream file
US20120246335A1 (en) Method, terminal, and server for implementing fast playout
CN104754349A (en) Method and device for hardware decoding of audio/video
US20200336526A1 (en) Reception device, reception method, transmission device, and transmission method for distributing signaling information
US20190342862A1 (en) Reception apparatus, reception method, transmission apparatus, and transmission method
KR102499231B1 (en) Receiving device, sending device and data processing method
CN103491427A (en) Method and device for processing video
JP7238948B2 (en) Information processing device and information processing method
CN104410901A (en) Play method and play device of M3U8 format live stream
CN105992022A (en) On-line recording and downloading method and system
CN105992016A (en) HLS on-line transcoding method and system
CN108174284B (en) Android system-based video decoding method
CN109640162A (en) Code stream conversion method and system
KR102137858B1 (en) Transmission device, transmission method, reception device, reception method, and program
US11368745B2 (en) Processing media data structures
JP6597604B2 (en) Reception device, transmission device, data communication method, and data processing method
CN102487454A (en) Method and system for rapidly starting segment programs
Stockhammer MPEG's Dynamic Adaptive Streaming over HTTP (DASH)–Enabling Formats for Video Streaming over the Open Internet
RU2658672C2 (en) Content provision device, program, terminal device and content provision system
CN106330667A (en) WeChat postcard generation method and system

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20161005