CN105228001B - A kind of method and system that FLV format videos play online - Google Patents
A kind of method and system that FLV format videos play online Download PDFInfo
- Publication number
- CN105228001B CN105228001B CN201510624981.1A CN201510624981A CN105228001B CN 105228001 B CN105228001 B CN 105228001B CN 201510624981 A CN201510624981 A CN 201510624981A CN 105228001 B CN105228001 B CN 105228001B
- Authority
- CN
- China
- Prior art keywords
- file
- flv
- format video
- flv format
- fragments
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 26
- 239000012634 fragment Substances 0.000 claims abstract description 91
- 238000013467 fragmentation Methods 0.000 claims description 6
- 238000006062 fragmentation reaction Methods 0.000 claims description 6
- 241001269238 Data Species 0.000 abstract 2
- 238000006243 chemical reaction Methods 0.000 description 19
- 230000005540 biological transmission Effects 0.000 description 14
- 230000008878 coupling Effects 0.000 description 4
- 238000010168 coupling process Methods 0.000 description 4
- 238000005859 coupling reaction Methods 0.000 description 4
- 238000005516 engineering process Methods 0.000 description 4
- 230000000694 effects Effects 0.000 description 3
- 238000012986 modification Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 230000000750 progressive effect Effects 0.000 description 2
- 238000005070 sampling Methods 0.000 description 2
- 235000002595 Solanum tuberosum Nutrition 0.000 description 1
- 244000061456 Solanum tuberosum Species 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 230000003139 buffering effect Effects 0.000 description 1
- 230000006835 compression Effects 0.000 description 1
- 238000007906 compression Methods 0.000 description 1
- 238000010586 diagram Methods 0.000 description 1
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/40—Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
- H04N21/43—Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
- H04N21/44—Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs
- H04N21/4402—Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs involving reformatting operations of video signals for household redistribution, storage or real-time display
- H04N21/440218—Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs involving reformatting operations of video signals for household redistribution, storage or real-time display by transcoding between formats or standards, e.g. from MPEG-2 to MPEG-4
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/80—Generation or processing of content or additional data by content creator independently of the distribution process; Content per se
- H04N21/83—Generation or processing of protective or descriptive data associated with content; Content structuring
- H04N21/845—Structuring of content, e.g. decomposing content into time segments
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)
Abstract
This application discloses the methods that FLV format videos play online, including:When server storage FLV format videos, the file header of FLV format video data packets is obtained;Corresponding description fileinfo is generated, and all description fileinfos are put together at before video file and are preserved;Client is received sends the asked FLV format video datas and corresponding description fileinfo that FLV format videos file returns after line playing request to server, and description fileinfo includes:FLV format video files are converted to the required information of TS fragments;Client generates corresponding TS index files according to description fileinfo and is sent to the player of client respectively, generates TS index file lists on a player;Player sends TS fragment playing requests according to TS index files tab sequential to client;Client is converted to TS fragments according to the corresponding FLV format video datas of TS fragment playing requests acquisition and is back to player;Player receives TS fragments and sequentially plays out.
Description
Technical Field
The present application relates to the field of video playing, and in particular, to a method and a system for online playing of FLV format video.
Background
Currently, a mobile terminal broadcasts videos from internet multimedia more and more widely, and the commonly used videos have various formats. Video format refers to the manner in which video data, audio data, and related information data in a video are organized. Video data is realized according to a certain specific format in the processes of storage and transmission, and the different video formats are realized in different modes. The video formats commonly used at present mainly include FLV, HLS, and the like.
FLV is short for FLASH VIDEO, and the FLV streaming media format is a VIDEO format developed along with the introduction of FLASH MX. The video file can be watched on the network due to the fact that the file formed by the video file is extremely small and the loading speed is extremely high, and the video file can be effectively watched on the network.
FLV is adopted by many new generation video sharing websites, and is the fastest growing and most widespread video transmission format at present. Developed on the basis of the compression algorithm of sorenson corporation. The FLV format can be easily imported into Flash, has extremely high speed, can play a role in protecting copyright, and can play videos without local Microsoft or REAL players.
FLV, an emerging web video format, is supported by numerous websites and is not occasional. Besides the characteristics of low occupancy rate, good video quality, small volume and the like of the FLV video format, the FLV video format is suitable for network development, and rich and various resources are also an important factor for the uniform online playing of the FLV video format. From the latest transformers to jail-off and then to various sports programs, even self-timer videos made by net friends and the like can be easily found in the network.
There are two types of websites for providing FLV videos on the internet, one is a special video sharing website such as YouTube website in the united states, six rooms in the country, potato web, and the like. The other is that the portal provides a block of video podcasts, provides its own video channels, such as the Sino video podcasts, etc., and also uses FLV format video. In addition, the hundredth degree also promotes the function of video searching, and videos searched in the video searching basically adopt the popular FLV format.
HLS (HTTP Live Streaming) is mainly used for audio and video services of PC and Apple terminals. The media playback method comprises an m3u (8) index file, a TS media fragment file and a key encryption string file, wherein the index file is used for a player to perform seek operation on the TS media fragment file, and the TS media fragment file comprises played video data.
The commonly used streaming media protocols mainly include HTTP progressive download and real-time streaming media protocol based on RTSP/RTP, which are basically completely different things, and currently, the HTTP progressive download method is more convenient and better.
As a separate FLV file. While Flash video files are typically the control of the Flash Player being delivered, the FLV files themselves are fully functional to themselves and may be played out or converted to other formats, stored locally, such as on a hard disk or CD.
Video processing in the FLV format has the following benefits:
FLV is a brand-new streaming media video format, and integrates video into Flash animation by utilizing a Flash Player platform widely used on a webpage. That is to say, as long as the visitor of the website can watch the Flash animation, the visitor can naturally watch the FLV format video without additionally installing other video plug-ins, and the use of the FLV video brings great convenience to video transmission.
Based on the above advantages, it is popular to store the video file in the FLV format on the server, and distribute and play the video file after receiving the video playing request from the client. The client receives the video file sent by the server, then downloads the video information part with the FLV file header, and then downloads the actual FLV format video data for playing.
FLV, a popular video file format, can be played on multiple platforms. With the development of network technology, online playing of videos is more and more popular with people. However, since the FLV format video file contains information such as indexes of all audio and video frames in its header, the FLV format video file header is particularly large, and the buffering time at the beginning of the video is particularly long when playing the FLV format video file. If the FLV file is played online, that is, played at the bottom of the file, a long download buffer time of the video start file header is needed, and the download buffer time differs according to the difference of the total length of the video, which generally can reach 1M, and the experience of watching the FLV video file online by the user is seriously affected.
The current solution is to complete the conversion of FLV format video files by the server, by the following means:
(1) the video file format is converted into an FLV file format, and then the FLV file format is transmitted to a local player for playing, and the video playing starting fast buffer playing mode is carried out by utilizing the characteristic of small head of the FLV.
(2) The FLV format video file is divided into a plurality of FLV files of small segments of videos, so that the head of each small file is small, and the purpose of quick playing can be achieved.
(3) And converting the FLV format video file into a plurality of TS format video files, and playing the TS format video files by using an HLS technology.
If the format conversion process of the FLV format video is completely completed in the background server according to the above scheme, the following problems may be caused:
(1) in the prior art, the video file in the FLV format is converted into the video file in other formats on the server, but the converted video file is converted into a plurality of formats to adapt to different video playing platforms, so that the storage capacity of the service is greatly increased, and the cost of the server is increased.
(2) In the prior art, the video file in the FLV format is converted into the video files in other formats on the server, so that the same video stores the files in a plurality of formats on the server, and great troubles are brought to the file management of the server.
(3) In the prior art, the video file in the FLV format is converted into the video file in other format, that is, the fragmented video file, in the server, the data transmission of a plurality of small fragmented files may affect the transmission effect of the file, which is not beneficial to the playing of the client video.
(4) In the prior art, the video file in the FLV format is converted into the video file in other formats on the server, and the efficiency of network transmission performance between the streaming module and the format conversion module of the server is low, so that the problem that the client cannot smoothly receive the video file for playing is caused.
Disclosure of Invention
In order to solve the problems in the prior art, the present invention provides a method and a system for online playing FLV-format video.
The invention provides a method for playing FLV format video on line, which comprises the following steps:
when the server stores the FLV format video, acquiring a file header of a FLV format video data packet;
generating corresponding description file information according to the acquired file header, and intensively placing all the description file information in front of the video file for storage;
the client receives the requested FLV format video data and the corresponding description file information which are returned after the FLV format video file online playing request is sent to the server, wherein,
the description file information includes: the FLV format video file is converted into information required by TS fragmentation;
the client generates corresponding TS index files according to the description file information and sends the TS index files to a player of the client, and a TS index file list is generated on the player;
the player sends a TS fragment playing request to a client according to the TS index file list sequence;
the client acquires corresponding FLV format video data according to the TS fragment playing request, converts the video data into TS fragments and returns the TS fragments to the player;
and the player receives the TS fragments and plays the TS fragments in sequence.
Further, the client receives the requested FLV format video data and the corresponding description file information, which are returned after the client sends the FLV format video file online playing request to the server, and further includes:
after receiving an FLV format video source file, the server disperses a file header of the FLV format video source file into respective file header fragments according to a key frame of the FLV format video source file and stores the file header fragments in respective corresponding positions in the FLV format video source file;
and generating corresponding FLV index files according to the file header fragments, and sequentially saving all the generated FLV index files in front of the FLV format video file with the file header fragments to form the description file information.
Further, wherein the description file information further includes:
the description file information records key frame information required for generating the TS index file, wherein,
the TS index file is further an m3u8 file.
Further, the TS index file records an offset of each key frame in the current TS slice.
Further, the sending, by the player, a TS segment playing request to the client according to the TS index file list sequence, further includes:
and the player sends an HTTP request for TS fragment playing to the client according to the TS index file.
6. A system for online playing FLV format video, the system being provided on a client, the system comprising: a receiving module, a processing module and a player,
the receiving module is used for receiving the requested FLV format video data and the corresponding description file information after the FLV format video file online playing request is sent to the server, wherein,
when the FLV format video is stored in the server, the server acquires a file header of a FLV format video data packet;
generating corresponding description file information according to the acquired file header, and intensively placing all the description file information in front of the video file for storage;
the description file information includes: the FLV format video file is converted into information required by TS fragmentation;
the processing module is used for respectively generating corresponding TS index files according to the description file information and sending the TS index files to a player of the client, and generating a TS index file list on the player;
acquiring corresponding FLV format video data according to the TS fragment playing request, converting the video data into TS fragments and returning the TS fragments to the player;
the player is used for sending a TS fragment playing request to a client according to the TS index file list sequence; and
and receiving the TS fragments and playing the TS fragments in sequence.
Further, wherein the description file information further includes:
after the description file information is received by the server, the file headers of the FLV format video source files are dispersed into respective file header fragments according to the key frames of the FLV format video source files, and the respective file header fragments are stored in respective corresponding positions of the FLV format video source files;
and generating corresponding FLV index files according to the file header fragments, and sequentially saving all the generated FLV index files in front of the FLV format video file with the file header fragments to form the FLV index file.
Further, wherein the description file information further includes:
the description file information records key frame information required for generating the TS index file, wherein,
the TS index file is further an m3u8 file.
Further, the TS index file records an offset of each key frame in the current TS slice.
Further, wherein the player is further configured to:
and sending an HTTP request of TS slicing playing to the client according to the TS index file.
Compared with the prior art, the method and the system for online playing the FLV format video have the following advantages:
(1) the invention disperses the file header of the FLV format video file to each corresponding position according to the key frame on the server, adds the file header information on the FLV format video file according to the dispersed file header, and returns the file header information according to the online video playing request of the client, the client generates the index file of the TS fragment according to the dispersed file header, and converts the downloaded FLV video file into the video file of the TS fragment according to the generated index file and sends the video file of the TS fragment to the player for playing, thus, the file header information prepared in advance on the server only carries the information such as the video key frame position and the like required for converting the TS index file, and compared with downloading the file header with larger FLV in advance, the invention greatly reduces the first buffer time of the online playing of the FLV format video file.
(2) The invention processes the FLV format video file on the server and performs the format conversion of the FLV format video file on the client, thereby not only reducing the format conversion management on the server, but also reducing the management of storing a plurality of format video files on the server and reducing the server cost.
(3) The invention processes the FLV format video file on the server, and performs the format conversion of the FLV format video file on the client, the FLV format video file stored on the server is a complete video file comprising a file header and video data, the influence of transmission on the video file can be reduced by performing the transmission of the complete video file, and the client is ensured to receive the complete video file for conversion and play.
(4) According to the invention, the FLV format video file is processed on the server, and the format conversion of the FLV format video file is carried out on the client, so that the problem that the client is not smooth when receiving the video file for playing due to low network transmission performance efficiency between the streaming module and the format conversion module caused by the video format conversion on the server is avoided.
(5) The invention processes the FLV format video file on the server, and performs the format conversion of the FLV format video file on the client, and the single FLV file is transmitted on the network, and the P2P technology can be used for accelerating transmission.
Of course, it is not necessary for any one product to achieve all of the above-described technical effects simultaneously.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the application and together with the description serve to explain the application and not to limit the application. In the drawings:
FIG. 1 is a flow chart of the method for online playing FLV video according to the present invention;
fig. 2 is a schematic flow chart of a method for online playing FLV-format video according to embodiment 2 of the present invention;
fig. 3 is a block diagram of the system structure of FLV format video online playing of the present invention.
Detailed Description
As used in the specification and in the claims, certain terms are used to refer to particular components. As one skilled in the art will appreciate, manufacturers may refer to a component by different names. This specification and claims do not intend to distinguish between components that differ in name but not function. In the following description and in the claims, the terms "include" and "comprise" are used in an open-ended fashion, and thus should be interpreted to mean "include, but not limited to. "substantially" means within an acceptable error range, and a person skilled in the art can solve the technical problem within a certain error range to substantially achieve the technical effect. Furthermore, the term "coupled" is intended to encompass any direct or indirect electrical coupling. Thus, if a first device couples to a second device, that connection may be through a direct electrical coupling or through an indirect electrical coupling via other devices and couplings. The description which follows is a preferred embodiment of the present application, but is made for the purpose of illustrating the general principles of the application and not for the purpose of limiting the scope of the application. The protection scope of the present application shall be subject to the definitions of the appended claims.
The present application will be described in further detail below with reference to the accompanying drawings, but the present application is not limited thereto.
Example 1:
as shown in fig. 1, a method for online playing FLV format video according to embodiment 1 of the present invention includes:
step 101, when a server stores an FLV format video, acquiring a file header of an FLV format video data packet; generating corresponding description file information according to the acquired file header, and intensively placing all the description file information in front of the video file for storage; the client receives the requested FLV format video data and the corresponding description file information which are returned after the FLV format video file online playing request is sent to the server, wherein,
the description file information includes: the FLV format video file is converted into information required by TS fragmentation; wherein,
the general FLV format video file has a relatively large header, and includes not only video key information, but also information such as an audio/video encoding format, a video resolution, an audio/video sampling rate, a sampling accuracy, a channel number, size information of each audio/video packet, and a timestamp corresponding to each audio/video packet in the video file.
When the FLV format video file is stored on a server, the file header of the FLV format video source file is dispersed into respective file header fragments according to the key frame of the FLV format video source file and is stored in respective corresponding positions in the FLV format video source file; and adding the description file information in front of the file header of the FLV format video file, wherein the description file information records the offset information of each key frame in the FLV format video file.
When the client plays online, the description file information is downloaded first, and accordingly, an index file of the TS fragments is generated, and a file header of a video source file in an FLV format does not need to be downloaded when the video playing is started. Compared with the file header of the FLV format video source file, the description file information only needs to record the information required for generating the TS fragment index file, so that the size of the description file information is greatly reduced.
102, the client generates corresponding TS index files according to the description file information and sends the TS index files to a player of the client, and a TS index file list is generated on the player; wherein,
the generated TS index file records the offset information of each key frame in the FLV format video file to be converted, and when a player plays seek operation, the TS fragment file can be quickly found.
And 103, the player sends a TS fragment playing request to the client according to the TS index file list sequence.
Step 104, the client acquires corresponding FLV format video data according to the TS fragment playing request, converts the video data into TS fragments and returns the TS fragments to the player; wherein,
the video files in the FLV format are provided with larger file headers, so that the video files are not convenient for a client to buffer and play quickly, and are converted into file headers, namely TS index files, and format videos of smaller TS fragments, so that the client can buffer the first video file quickly when playing online.
And 105, the player receives the TS fragments and plays the TS fragments in sequence.
Example 2:
as shown in fig. 2, on the basis of embodiment 1, the method for playing FLV format video online according to the present invention includes:
step 201, when the server stores the FLV format video, obtaining a file header of the FLV format video data packet; generating corresponding description file information according to the acquired file header, and intensively placing all the description file information in front of the video file for storage; the client receives the requested FLV format video data and the corresponding description file information which are returned after the FLV format video file online playing request is sent to the server, wherein,
the description file information includes: the FLV format video file is converted into information required by TS fragmentation;
the storage process of the FLV format video file in the server is as follows:
after receiving an FLV format video source file, the server disperses a file header of the FLV format video source file into respective file header fragments according to a key frame of the FLV format video source file and stores the file header fragments in respective corresponding positions in the FLV format video source file;
and generating corresponding FLV index files according to the file header fragments, and sequentially saving all the generated FLV index files in front of the FLV format video file with the file header fragments to form the description file information.
The FLV header fragment has information on the number and size of all frames before each key frame, and the key frame index is added to the TS index file generated for convenience.
Step 202, the client generates corresponding TS index files according to the description file information and sends the TS index files to a player of the client, and a TS index file list is generated on the player;
the description file information records information required for generating a TS index file, wherein the TS index file is further an m3u8 file; the description file information is generated according to the file header of the FLV format video when the FLV format video file is saved by the server;
the TS index file records the offset of each key frame in the current TS fragment file.
Step 203, the player sends a TS fragment playing request to a client according to the sequence of the TS index file list; the TS fragment playing request is an HTTP request sent by a local server, for example, the player requests playing to a client local server by HTTP://127.0.0.1/vod.m3u8 link.
And step 204, the client acquires corresponding FLV format video data according to the TS fragment playing request, converts the video data into TS fragments and returns the TS fragments to the player.
Step 205, when the player plays the video, the player plays the video sequentially according to the received TS segments.
Example 3:
as shown in fig. 3, the system for FLV format video online playing is provided on a client, and includes: a receiving module 301, a processing module 302 and a player 303.
The receiving module 301, coupled to the processing module 302, is configured to receive requested FLV format video data and corresponding description file information, where the requested FLV format video data and the corresponding description file information are returned after an online playing request of an FLV format video file is sent to a server,
when the FLV format video is stored in the server, the server acquires a file header of a FLV format video data packet;
generating corresponding description file information according to the acquired file header, and intensively placing all the description file information in front of the video file for storage;
the description file information includes: and the FLV format video file is converted into information required by the TS fragments.
The processing module 302 is coupled to the receiving module 301 and the player 303, and configured to generate corresponding TS index files according to the description file information, send the TS index files to the player of the client, and generate a TS index file list on the player;
and acquiring corresponding FLV format video data according to the TS fragment playing request, converting the video data into TS fragments and returning the TS fragments to the player.
The player 303 is coupled to the processing module 302, and configured to send a TS fragment playing request to a client according to the sequence of the TS index file list;
and receiving the TS fragments and playing the TS fragments in sequence.
In this embodiment, the receiving the requested FLV format video data and the corresponding description file information that are returned after sending the FLV format video file online playing request to the server further includes:
after receiving an FLV format video source file, dispersing a file header of the FLV format video source file into respective file header fragments according to a key frame of the FLV format video source file, and storing the file header fragments to respective corresponding positions in the FLV format video source file;
and generating corresponding FLV index files according to the file header fragments, and sequentially saving all the generated FLV index files in front of the FLV format video file with the file header fragments to form the description file information.
The description file information further comprises:
the description file information records key frame information required for generating the TS index file, wherein,
the TS index file is further an m3u8 file.
Further, the TS index file records the offset of each key frame in the current TS slice.
The player is further configured to:
and sending an HTTP request of TS slicing playing to the client according to the TS index file.
Compared with the prior art, the method and the system for online playing the FLV format video have the following advantages:
(1) the invention disperses the file header of the FLV format video file to each corresponding position according to the key frame on the server, adds the file header information on the FLV format video file according to the dispersed file header, and returns the file header information according to the online video playing request of the client, the client generates the index file of the TS fragment according to the dispersed file header, and converts the downloaded FLV video file into the video file of the TS fragment according to the generated index file and sends the video file of the TS fragment to the player for playing, thus, the file header information prepared in advance on the server only carries the information such as the video key frame position and the like required for converting the TS index file, and compared with downloading the file header with larger FLV in advance, the invention greatly reduces the first buffer time of the online playing of the FLV format video file.
(2) The invention processes the FLV format video file on the server and performs the format conversion of the FLV format video file on the client, thereby not only reducing the format conversion management on the server, but also reducing the management of storing a plurality of format video files on the server and reducing the server cost.
(3) The invention processes the FLV format video file on the server, and performs the format conversion of the FLV format video file on the client, the FLV format video file stored on the server is a complete video file comprising a file header and video data, the influence of transmission on the video file can be reduced by performing the transmission of the complete video file, and the client is ensured to receive the complete video file for conversion and play.
(4) According to the invention, the FLV format video file is processed on the server, and the format conversion of the FLV format video file is carried out on the client, so that the problem that the client is not smooth when receiving the video file for playing due to low network transmission performance efficiency between the streaming module and the format conversion module caused by the video format conversion on the server is avoided.
(5) The invention processes the FLV format video file on the server, and performs the format conversion of the FLV format video file on the client, and the single FLV file is transmitted on the network, and the P2P technology can be used for accelerating transmission.
The foregoing description shows and describes several preferred embodiments of the present application, but as aforementioned, it is to be understood that the application is not limited to the forms disclosed herein, but is not to be construed as excluding other embodiments and is capable of use in various other combinations, modifications, and environments and is capable of changes within the scope of the application as described herein, commensurate with the above teachings, or the skill or knowledge of the relevant art. And that modifications and variations may be effected by those skilled in the art without departing from the spirit and scope of the application, which is to be protected by the claims appended hereto.
Claims (6)
1. A method for playing FLV format video on line is characterized by comprising the following steps:
when the server stores the FLV format video, acquiring a file header of a FLV format video data packet;
generating corresponding description file information according to the acquired file header, and intensively placing all the description file information in front of the video file for storage;
the client receives the requested FLV format video data and the corresponding description file information which are returned after the FLV format video file online playing request is sent to the server, wherein,
after receiving an FLV format video source file, the server disperses a file header of the FLV format video source file into respective file header fragments according to a key frame of the FLV format video source file and stores the file header fragments in respective corresponding positions in the FLV format video source file;
generating corresponding FLV index files according to the file header fragments, and sequentially saving all the generated FLV index files in front of an FLV format video file with the file header fragments to form the description file information, wherein the description file information comprises: the FLV format video file is converted into information required by TS fragmentation;
the client generates corresponding TS index files according to the description file information and sends the TS index files to a player of the client, and a TS index file list is generated on the player, wherein the TS index files record the offset of each key frame in the current TS fragment;
the player sends a TS fragment playing request to a client according to the TS index file list sequence;
the client acquires corresponding FLV format video data according to the TS fragment playing request, converts the video data into TS fragments and returns the TS fragments to the player;
and the player receives the TS fragments and plays the TS fragments in sequence.
2. The method for playing FLV format video on line according to claim 1, wherein the description file information further includes:
the description file information records key frame information required for generating the TS index file, wherein,
the TS index file is further an m3u8 file.
3. The method for playing FLV format video on line according to claim 1, wherein the player sends a TS slice playing request to a client according to the TS index file list order, further comprising:
and the player sends an HTTP request for TS fragment playing to the client according to the TS index file.
4. A system for FLV format video online playing, the system being provided on a client, the system comprising: a receiving module, a processing module and a player,
the receiving module is used for receiving the requested FLV format video data and the corresponding description file information after the FLV format video file online playing request is sent to the server, wherein,
when the FLV format video is stored in the server, the server acquires a file header of a FLV format video data packet;
generating corresponding description file information according to the acquired file header, and intensively placing all the description file information in front of the video file for storage;
after the description file information is received by the server, the file headers of the FLV format video source files are dispersed into respective file header fragments according to the key frames of the FLV format video source files, and the respective file header fragments are stored in respective corresponding positions of the FLV format video source files; generating corresponding FLV index files according to the file header fragments, and sequentially saving all the generated FLV index files in front of the FLV format video file with the file header fragments to form the FLV index files, wherein the description file information comprises: the FLV format video file is converted into information required by TS fragmentation;
the processing module is used for respectively generating corresponding TS index files according to the description file information and sending the TS index files to a player of the client, and generating a TS index file list on the player, wherein the TS index files record the offset of each key frame in the current TS fragments;
acquiring corresponding FLV format video data according to the TS fragment playing request, converting the video data into TS fragments and returning the TS fragments to the player;
the player is used for sending a TS fragment playing request to a client according to the TS index file list sequence; and
and receiving the TS fragments and playing the TS fragments in sequence.
5. The system for on-line playing of FLV formatted video according to claim 4, wherein said description file information further comprises:
the description file information records key frame information required for generating the TS index file, wherein,
the TS index file is further an m3u8 file.
6. The system for on-line playing of FLV format video according to claim 4, wherein said player is further configured to:
and sending an HTTP request of TS slicing playing to the client according to the TS index file.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510624981.1A CN105228001B (en) | 2015-09-26 | 2015-09-26 | A kind of method and system that FLV format videos play online |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510624981.1A CN105228001B (en) | 2015-09-26 | 2015-09-26 | A kind of method and system that FLV format videos play online |
Publications (2)
Publication Number | Publication Date |
---|---|
CN105228001A CN105228001A (en) | 2016-01-06 |
CN105228001B true CN105228001B (en) | 2018-11-06 |
Family
ID=54996635
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201510624981.1A Active CN105228001B (en) | 2015-09-26 | 2015-09-26 | A kind of method and system that FLV format videos play online |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN105228001B (en) |
Families Citing this family (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107820124A (en) * | 2017-11-10 | 2018-03-20 | 暴风集团股份有限公司 | Format conversion method, device and server |
CN110113655B (en) * | 2019-05-05 | 2021-09-21 | 北京奇艺世纪科技有限公司 | Video playing method and device and user terminal |
CN111147947B (en) * | 2020-01-10 | 2021-12-10 | 深圳市同洲电子股份有限公司 | Websocket-based flv video transmission and webpage playing method |
CN111866603B (en) * | 2020-07-21 | 2022-04-26 | 广州市保伦电子有限公司 | Video file production method based on SRS, background server and system |
CN113038033B (en) * | 2021-03-02 | 2023-07-07 | 深圳市浩科电子有限公司 | Method for acquiring video |
CN113079386B (en) * | 2021-03-19 | 2023-01-17 | 北京百度网讯科技有限公司 | Video online playing method and device, electronic equipment and storage medium |
CN113242447B (en) * | 2021-05-10 | 2022-05-17 | 北京奇艺世纪科技有限公司 | Video data processing method and device |
CN113438505A (en) * | 2021-06-02 | 2021-09-24 | 曙光网络科技有限公司 | Video file restoration method and device, computer equipment and storage medium |
CN113395589B (en) * | 2021-06-11 | 2023-02-10 | 深圳万兴软件有限公司 | Video file playing method and device, computer equipment and storage medium |
CN114025201A (en) * | 2021-10-29 | 2022-02-08 | 恒安嘉新(北京)科技股份公司 | Video playing method, device, equipment and storage medium |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2011150644A1 (en) * | 2010-12-17 | 2011-12-08 | 华为技术有限公司 | Method and apparatus for acquiring and transmitting streaming media data in the process of initiation |
CN103763637A (en) * | 2014-01-21 | 2014-04-30 | 北京云视睿博传媒科技有限公司 | Stream media broadcasting method and system |
CN104349176A (en) * | 2013-07-30 | 2015-02-11 | 中国电信股份有限公司 | Self-adaptive stream media system, downloading method and stream media server, user terminal |
CN104661058A (en) * | 2013-11-20 | 2015-05-27 | 深圳市云帆世纪科技有限公司 | MP4 video on demand data stream transmission method, client side and video on demand system |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2014011622A2 (en) * | 2012-07-09 | 2014-01-16 | Vid Scale, Inc. | Power aware video decoding and streaming |
-
2015
- 2015-09-26 CN CN201510624981.1A patent/CN105228001B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2011150644A1 (en) * | 2010-12-17 | 2011-12-08 | 华为技术有限公司 | Method and apparatus for acquiring and transmitting streaming media data in the process of initiation |
CN104349176A (en) * | 2013-07-30 | 2015-02-11 | 中国电信股份有限公司 | Self-adaptive stream media system, downloading method and stream media server, user terminal |
CN104661058A (en) * | 2013-11-20 | 2015-05-27 | 深圳市云帆世纪科技有限公司 | MP4 video on demand data stream transmission method, client side and video on demand system |
CN103763637A (en) * | 2014-01-21 | 2014-04-30 | 北京云视睿博传媒科技有限公司 | Stream media broadcasting method and system |
Also Published As
Publication number | Publication date |
---|---|
CN105228001A (en) | 2016-01-06 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN105228001B (en) | A kind of method and system that FLV format videos play online | |
US10264093B2 (en) | Systems and methods for partial video caching | |
EP2391086B1 (en) | Method and apparatus for playing live content | |
CN105230024B (en) | A kind of media representation adaptive approach, device and computer storage medium | |
CN105208440B (en) | A kind of method and system that MP4 format video plays online | |
EP2490445B1 (en) | Method, terminal and server for implementing trickplay | |
US20130198335A1 (en) | Just In Time Construct HLS Stream from HDS Live Stream | |
US20140122738A1 (en) | Apparatus and method for providing streaming content | |
CN109587514B (en) | Video playing method, medium and related device | |
KR20120092622A (en) | Streaming with optional broadcast delivery of data segments | |
CA2783592A1 (en) | Apparatus and methods for describing and timing representations in streaming media files | |
CN102118428A (en) | Method and system for playing streaming media | |
US8817983B2 (en) | Streaming video to cellular phones | |
CN105611395B (en) | A kind of method and system that MP4 format video plays online | |
WO2015192683A1 (en) | Content distribution method, device and system based on adaptive streaming technology | |
US9467493B2 (en) | Apparatus and method for providing streaming content | |
CN104661058A (en) | MP4 video on demand data stream transmission method, client side and video on demand system | |
US10057624B2 (en) | Synchronization of content rendering | |
CN113923502B (en) | Live video playing method and device | |
CN106789976A (en) | The player method of media file, service end, client and system | |
CN108174284B (en) | Android system-based video decoding method | |
KR101397551B1 (en) | Dynamic and Adaptive Streaming System over HTTP | |
CN109151614B (en) | Method and device for reducing HLS live broadcast delay | |
CN105592369B (en) | A kind of video frequency abstract processing method and processing device | |
CN102594773B (en) | A kind of method and system for realizing data acquisition |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
CB02 | Change of applicant information |
Address after: 100191 Beijing, Xueyuan Road No. 51, the first to enjoy the science and technology building, floor 6, Applicant after: Storm group Limited by Share Ltd Address before: 100191 Beijing, Xueyuan Road No. 51, the first to enjoy the science and technology building, floor 6, Applicant before: Beijing Baofeng Technology Co., Ltd. |
|
COR | Change of bibliographic data | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
PP01 | Preservation of patent right | ||
PP01 | Preservation of patent right |
Effective date of registration: 20190705 Granted publication date: 20181106 |