CN102088449A - Playing method and device of network video file - Google Patents

Playing method and device of network video file Download PDF

Info

Publication number
CN102088449A
CN102088449A CN2009102520601A CN200910252060A CN102088449A CN 102088449 A CN102088449 A CN 102088449A CN 2009102520601 A CN2009102520601 A CN 2009102520601A CN 200910252060 A CN200910252060 A CN 200910252060A CN 102088449 A CN102088449 A CN 102088449A
Authority
CN
China
Prior art keywords
data
video
minimum
header
flv
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.)
Granted
Application number
CN2009102520601A
Other languages
Chinese (zh)
Other versions
CN102088449B (en
Inventor
陈良华
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN200910252060.1A priority Critical patent/CN102088449B/en
Publication of CN102088449A publication Critical patent/CN102088449A/en
Application granted granted Critical
Publication of CN102088449B publication Critical patent/CN102088449B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The embodiment of the invention provides a playing method and device of a network video file, which belong to the technical field of network communication. The method comprises the following steps of: receiving a video on demand command of a user, downloading at most 1 kilobyte of video data of a video file which corresponds to the video command and determining a format which corresponds to the video file according to the at most 1 kilobyte of video data; and searching a minimum datum which corresponds to the format from a pre-stored minimum data list according to the format, downloading the corresponding minimum datum and transmitting the minimum datum to a flash widget for starting playing a video. The method and the device provided by the invention have the advantages of short loading time and good user experience.

Description

The player method of network video file and device
Technical field
The present invention relates to network communication field, relate in particular to a kind of player method and device of network video file.
Background technology
Along with Internet development, video file in the network is also more and more, in order to allow the user better experience video file in the network, prior art provides a kind of player method of network video file, this method comprises: player downloads after the 2M data, is given the flash control with data and is begun displaying video at least.
In realizing process of the present invention, there are the following problems for the technical scheme that prior art provided:
At least the data that need in the scheme of prior art to download 2M just can be carried out the broadcast of video, and the time that causes the user to wait for is longer, and user experience is relatively poor.
Summary of the invention
Embodiment of the present invention provides a kind of player method and device of network video file, and this method and device can reduce the time of waiting for, the advantage of better user experience.
The specific embodiment of the present invention provides a kind of player method of network video file, and described method comprises:
After receiving user's order video order, download the video data of 1K at the most of the video file of this video commands correspondence, determine the form of this video file correspondence according to the video data of described 1K at the most;
From the minimum data tabulation of storage in advance, find out the minimum data of this form correspondence according to described form, downloaded this corresponding minimum data after, give the flash control with described minimum data and begin displaying video.
The present invention also provides a kind of playing device of network video file, and described device comprises:
Receive download unit, after being used to receive user's order video order, download the video data of 1K at the most of the video file of this video commands correspondence, determine the form of this video file correspondence according to the video data of described 1K at the most;
Search broadcast unit, be used for finding out the minimum data of this form correspondence from the minimum data tabulation of storage in advance according to described form, downloaded this corresponding minimum data after, give the flash control with described minimum data and begin displaying video.
By the above-mentioned technical scheme that provides as can be seen, the technical scheme of the embodiment of the invention can reduce the time of waiting for, has the advantage of better user experience.
Description of drawings
The flow chart of the player method of a kind of network video file that Fig. 1 provides for one embodiment of the invention;
The flow chart of the player method of a kind of network video file that Fig. 2 provides for another embodiment of the present invention;
The flow chart of the player method of a kind of network video file that Fig. 3 provides for further embodiment of this invention;
Fig. 4 is the structure chart of the playing device of a kind of network video file provided by the invention.
Embodiment
Embodiment of the present invention provides an embodiment, and present embodiment provides a kind of player method of network video file, and this method comprises as shown in Figure 1:
S11, receive user's order video order after, download the video data of the 1K at the most of the corresponding video file of this order; Promptly download the video data that is no more than 1K at most;
The scope suggestion of above-mentioned 1K at the most uses 100 bytes between the 1K, and the user also can freely set in actual conditions certainly.
S12, judge the form of the correspondence of this video file according to the video data of this 1K;
S13, from the minimum data tabulation of storage in advance, determine the minimum data of this corresponding form correspondence according to this corresponding form;
S14, downloaded the minimum data of this form correspondence after, give the flash control with this minimum data and begin displaying video.
After the method that present embodiment provides is judged the form of this video file correspondence by the video data that is downloaded to many 1K, from the tabulation of storage in advance, determine the minimum data of this form correspondence according to this form, after having downloaded this minimum data, give the flash control with minimum data and begin displaying video.Because this method only need have been downloaded minimum data and can carry out the broadcast of video file, the data downloaded amount is little, and the time of loading is shorter, the user experience height.
The present invention also provides another embodiment, and present embodiment provides a kind of player method of network video file, and the technology scene that present embodiment is realized is, video file is an example with FLV (flash video) form, and this method comprises as shown in Figure 2:
S21, receive user's order video order after, the video data of the 1K at the most of the video file of foradownloaded video order correspondence;
S22, the form of judging this video file according to the video data of this 1K are the FLV form;
S23, from the minimum data tabulation of storage in advance, determine the minimum played data of this FLV correspondence to be specifically as follows FLV Header (header)+first tag according to this FLV form; Wherein the FLV file format is as shown in table 1:
Table 1:
Figure B2009102520601D0000031
Header+ file attribute tag in the above-mentioned minimum played data correspondence table 1.
Above-mentioned first tag can be, metadata onMetaData.Optionally, after determining minimum played data, can detect, as detect this video file and do not have first tag, and determine that this first tag is 0, promptly need not to download first tag video file.
The manufacture method of above-mentioned minimum data tabulation can for, obtain the form of video file commonly used, respective standard according to concrete form correspondence is determined minimum data, for example, as the FLV form, then " the Video File Format Specification Version 9 " with reference to Adobe company determines that this minimum data is FLVHeader (header)+first tag; MP4 form and for example, then " the QuickTimeFile Format Specification " with reference to Adobe company determines that this minimum data is MP4 file header+moov atom.
The concrete form of above-mentioned MP4 can be referring to the description of Table 1 among the ISO/IEC 14496-12:2005 (E).
Ftyp (4.3) among the corresponding Table 1 of above-mentioned MP4 file header+moov atom need to prove wherein that to subs (8.42) data of band " * " are essential data among the Table 1, not with * " data be optional data; Among the above-mentioned ftyp (4.3) 4.3 is to the numbering of data ftyp among the Table 1; 8.42 of subs (8.42) is to the numbering of data subs among the Table 1.
The length that it should be noted that first tag of each video file correspondence is not definite value, is that first tag of the video file 1 of FLV can be 1K as form, and first tag of the video file 2 of form FLV can be 2K; In like manner, the length of the moov atom of each video file correspondence is not definite value.
S24, after having downloaded first tag data of FLV Header+, give the flash control with first tag data of FLV Header+ and begin displaying video.
After the method that present embodiment provides is judged this video file and is the FLV form by the video data that is downloaded to many 1K, the minimum data amount of determining this video file correspondence according to this FLV form from the tabulation of storage in advance is first tag of FLV Header+, after having downloaded first tag of FLV Header+, give the flash control with first tag data of FLVHeader+ and begin displaying video.Because this method only need have been downloaded first tag of FLV Header+ and can carry out the broadcast of video file, and first tag of FLV Header+ affirms less than the 2M data volume, so its data downloaded amount is little, so the time of its loading is shorter, and the user experience height.
The present invention also provides another embodiment, and the technology scene that present embodiment is realized is, the video file of present embodiment is an example with the MP4 form, and this MP4 is the broadcast format of video file; This method comprises as shown in Figure 3:
S31, receive user's order video order after, the video data of the 1K at the most of the video file of foradownloaded video order correspondence;
S32, the form of judging this video file according to the video data of this 1K are the MP4 form;
S23, from the minimum data tabulation of storage in advance, determine the minimum played data of this MP4 correspondence to be specifically as follows MP4 file header+moov atom according to this MP4 form;
Optionally, after determining minimum played data, can detect, as the video file that detects this MP4 form do not have moov atom, and determine that this moov atom is 0, promptly need not to download moovatom video file.
S34, after having downloaded MP4 file header+moov atom data, give the flash control with MP4 file header+moov atom data and begin displaying video.
After the method that present embodiment provides is judged this video file and is the MP4 form by the video data that is downloaded to many 1K, the minimum data amount of determining this video file correspondence according to this MP4 form from the tabulation of storage in advance is MP4 file header+moov atom, after having downloaded MP4 file header+moov atom, give the flash control with MP4 file header+moov atom data and begin displaying video.Because this method only need have been downloaded MP4 file header+moov atom and can carry out the broadcast of video file, and MP4 file header+moov atom affirms less than the 2M data volume, so its data downloaded amount is little, so the time of its loading is shorter, and the user experience height.
The present invention also provides a kind of playing device of network video file, and this device comprises as shown in Figure 4:
Receive download unit 41, after being used to receive user's order video order, download the video data of 1K at the most of the video file of this video commands correspondence, determine the form of this video file correspondence according to the video data of described 1K at the most;
Search broadcast unit 42, be used for finding out the minimum data of this form correspondence from the minimum data tabulation of storage in advance according to described form, downloaded this corresponding minimum data after, give the flash control with described minimum data and begin displaying video.
The preparation method of above-mentioned minimum data tabulation can be referring to the associated description among the method embodiment.
Optionally, the form of above-mentioned video file correspondence is FLV form or MP4 form.When the form of above-mentioned video file correspondence is FLV, then minimum data is the minimum played data of FLV, is specifically as follows: first tag of FLVHeader+.When the form of above-mentioned video file correspondence is MP4, then minimum data is the minimum played data of MP4, is specifically as follows: MP4 file header+moov atom.
Optionally, searching broadcast unit 42 comprises:
Detection module 421 after being used for determining that according to described FLV minimum played data is first tag of FLV Header+, detects described video file and whether comprises first tag data,
The first downloading and playing module 422 is used for detecting when comprising at described detection module, downloaded first tag of FLVHeader+ after, give the flash control with described first tag of FLV Header+ and begin displaying video;
The second downloading and playing module 423 is used for detecting when not comprising at described detection module, downloaded FLVHeader after, just described FLV Header gives the flash control and begins displaying video.
Can, search broadcast unit 42 and comprise:
Judge module 424 is used for judging when being at described judge module, determine that according to described MP4 minimum played data is MP4 file header+moov atom after, detect described video file and whether comprise moov atom data;
The 3rd downloading and playing module 425 is used for judging when being at judge module 424, downloaded MP4 file header+moov atom after, described MP4 file header+moov atom is given the flash control and begins displaying video;
The 4th downloading and playing module 426 is used for when judge module 424 is not judged not, downloaded the MP4 file header after, just described MP4 file header is given the flash control and is begun displaying video.
In actual conditions, above-mentioned judge module 424 and detection module 421 can be merged into a module, and first, second, third and fourth downloading and playing module also can be merged into a module.
After the device that present embodiment provides is judged the form of this video file correspondence by the video data that receives download unit 41 and be downloaded to many 1K, from the tabulation of storage in advance, determine the minimum data of this form correspondence according to this form by searching broadcast unit 42, after having downloaded this minimum data, give the flash control with minimum data and begin displaying video.Because this method only need have been downloaded minimum data and can carry out the broadcast of video file, the data downloaded amount is little, and the time of loading is shorter, the user experience height.
One of ordinary skill in the art will appreciate that all or part of step that realizes in the foregoing description method is to instruct relevant hardware to finish by program, described program can be stored in the computer read/write memory medium, this program is when carrying out, comprise the said method step, described storage medium comprises: ROM/RAM, disk, CD etc.
In sum, the technical scheme that the specific embodiment of the invention provides, the time with loading is shorter, the advantage that user experience is high.
The above; only be the preferable embodiment of the present invention; but protection scope of the present invention is not limited thereto; anyly be familiar with those skilled in the art in the technical scope that the embodiment of the invention discloses; the variation that can expect easily or replacement all should be encompassed within protection scope of the present invention.Therefore, protection scope of the present invention should be as the criterion with the protection range of claim.

Claims (12)

1. the player method of a network video file is characterized in that, described method comprises:
After receiving user's order video order, download the video data of 1K at the most of the video file of this video commands correspondence, determine the form of this video file correspondence according to the video data of described 1K at the most;
From the minimum data tabulation of storage in advance, find out the minimum data of this form correspondence according to described form, downloaded this corresponding minimum data after, give the flash control with described minimum data and begin displaying video.
2. method according to claim 1 is characterized in that, the form of described video file correspondence is FLV form or MP4 form.
3. method according to claim 1, it is characterized in that, the form of video file correspondence is FLV as described, and then described minimum data is the minimum played data of FLV form, and the minimum played data of described FLV form is: first tag of FLV header Header+.
4. method according to claim 1 is characterized in that, the form of video file correspondence is MP4 as described, and then described minimum data is the minimum played data of MP4 form, and the minimum played data of described MP4 form is: MP4 file header+moov atom.
5. method according to claim 3, it is characterized in that, the described minimum data that from the minimum data tabulation of storage in advance, finds out this form correspondence according to described form, after having downloaded this corresponding minimum data, give the step that the flash control begins displaying video with described minimum data and comprise:
After determining that according to described FLV minimum played data is first tag of FLV Header+, detect described video file and whether comprise first tag data, after then having downloaded first tag of FLV Header+ in this way, give the flash control with described first tag of FLV Header+ and begin displaying video; As otherwise after having downloaded FLVHeader, just described FLV Header gives the flash control and begins displaying video.
6. method according to claim 4, it is characterized in that, describedly from the minimum data tabulation of storage in advance, find out the minimum data of this form correspondence according to described form, downloaded this corresponding minimum data after, give the flash control with described minimum data and begin displaying video and comprise:
After determining that according to described MP4 minimum played data is MP4 file header+moov atom, detect described video file and whether comprise moov atom data, after then having downloaded MP4 file header+moov atom in this way, described MP4 file header+moov atom is given the flash control and begins displaying video; As otherwise after having downloaded the MP4 file header, just described MP4 file header is given the flash control and is begun displaying video.
7. the playing device of a network video file is characterized in that, described device comprises:
Receive download unit, after being used to receive user's order video order, download the video data of 1K at the most of the video file of this video commands correspondence, determine the form of this video file correspondence according to the video data of described 1K at the most;
Search broadcast unit, be used for finding out the minimum data of this form correspondence from the minimum data tabulation of storage in advance according to described form, downloaded this corresponding minimum data after, give the flash control with described minimum data and begin displaying video.
8. device according to claim 7 is characterized in that, the form of described video file correspondence is FLV form or MP4 form.
9. device according to claim 7, it is characterized in that, the form of video file correspondence is FLV as described, and then described minimum data is the minimum played data of FLV form, and the minimum played data of described FLV form is: first tag of FLV header Header+.
10. device according to claim 7 is characterized in that, the form of video file correspondence is MP4 as described, and then described minimum data is the minimum played data of MP4 form, and the minimum played data of described MP4 form is: MP4 file header+moov atom.
11. method according to claim 9 is characterized in that, the described broadcast unit of searching comprises:
Detection module after being used for determining that according to described FLV minimum played data is first tag of FLV Header+, detects described video file and whether comprises first tag data,
The first downloading and playing module is used for detecting when comprising at described detection module, downloaded first tag of FLVHeader+ after, give the flash control with described first tag of FLV Header+ and begin displaying video;
The second downloading and playing module is used for detecting when not comprising at described detection module, downloaded FLVHeader after, just described FLV Header gives the flash control and begins displaying video.
12. method according to claim 10 is characterized in that, the described broadcast unit of searching comprises:
Judge module is used for judging when being at described judge module, determine that according to described MP4 minimum played data is MP4 file header+moov atom after, detect described video file and whether comprise moov atom data;
The 3rd downloading and playing module is used for judging when being at described judge module, downloaded MP4 file header+moov atom after, described MP4 file header+moov atom is given the flash control and begins displaying video;
The 4th downloading and playing module is used for when described judge module is not judged not, downloaded the MP4 file header after, just described MP4 file header is given the flash control and is begun displaying video.
CN200910252060.1A 2009-12-08 2009-12-08 Playing method and device of network video file Active CN102088449B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN200910252060.1A CN102088449B (en) 2009-12-08 2009-12-08 Playing method and device of network video file

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN200910252060.1A CN102088449B (en) 2009-12-08 2009-12-08 Playing method and device of network video file

Publications (2)

Publication Number Publication Date
CN102088449A true CN102088449A (en) 2011-06-08
CN102088449B CN102088449B (en) 2014-02-26

Family

ID=44100064

Family Applications (1)

Application Number Title Priority Date Filing Date
CN200910252060.1A Active CN102088449B (en) 2009-12-08 2009-12-08 Playing method and device of network video file

Country Status (1)

Country Link
CN (1) CN102088449B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106254962A (en) * 2016-07-28 2016-12-21 武汉斗鱼网络科技有限公司 A kind of live client quickly starts the method and system of broadcasting
CN111885331A (en) * 2020-07-25 2020-11-03 徐州云创电子科技有限公司 Novel mp4 packaging method for automatic storage of video interruption
US11683557B2 (en) 2021-06-21 2023-06-20 Beijing Baidu Netcom Science Technology Co., Ltd. Method for playing MP4 online, device, and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1972193A (en) * 2005-11-22 2007-05-30 三星电子株式会社 Compatible-progressive download method and the system thereof
CN101114950A (en) * 2007-09-11 2008-01-30 武汉虹旭信息技术有限责任公司 Method for reverting SIP protocol based audio/video flow in IP network
CN101114949A (en) * 2007-09-11 2008-01-30 武汉虹旭信息技术有限责任公司 Method for reverting H.323 protocol based audio/video flow in IP network
CN101472156A (en) * 2007-12-25 2009-07-01 欧阳泳春 Method of household player for supporting 3GP media file playing function
CN101577627A (en) * 2009-06-17 2009-11-11 腾讯科技(深圳)有限公司 System and method for downloading and playing multimedia file

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1972193A (en) * 2005-11-22 2007-05-30 三星电子株式会社 Compatible-progressive download method and the system thereof
CN101114950A (en) * 2007-09-11 2008-01-30 武汉虹旭信息技术有限责任公司 Method for reverting SIP protocol based audio/video flow in IP network
CN101114949A (en) * 2007-09-11 2008-01-30 武汉虹旭信息技术有限责任公司 Method for reverting H.323 protocol based audio/video flow in IP network
CN101472156A (en) * 2007-12-25 2009-07-01 欧阳泳春 Method of household player for supporting 3GP media file playing function
CN101577627A (en) * 2009-06-17 2009-11-11 腾讯科技(深圳)有限公司 System and method for downloading and playing multimedia file

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106254962A (en) * 2016-07-28 2016-12-21 武汉斗鱼网络科技有限公司 A kind of live client quickly starts the method and system of broadcasting
CN111885331A (en) * 2020-07-25 2020-11-03 徐州云创电子科技有限公司 Novel mp4 packaging method for automatic storage of video interruption
US11683557B2 (en) 2021-06-21 2023-06-20 Beijing Baidu Netcom Science Technology Co., Ltd. Method for playing MP4 online, device, and storage medium

Also Published As

Publication number Publication date
CN102088449B (en) 2014-02-26

Similar Documents

Publication Publication Date Title
CN105025319A (en) Video pushing method and device
CN102779544B (en) A kind of method and apparatus of generated media information list
WO2011081729A1 (en) Storage device and method for resuming playback of content
CN103607461A (en) Information sharing method and cloud server
CN101355574A (en) Method for on-line playing stream media files by a mobile terminal
CN101452726A (en) Multimedia playing system and method capable of downloading and displaying lyric
US8170209B2 (en) Extensible disc player
CN103945259A (en) Online video playing method and device
CN103841464A (en) Video information pushing method and device
CN102881309B (en) Lyrics file generates method and device
CN104834738A (en) Record file storage method and device
CN102088449A (en) Playing method and device of network video file
CN103956175A (en) Playing method and equipment of multi-media files
JP4557922B2 (en) Digital video recording method using terminal and mobile terminal
CN103177737B (en) Audio player and sound effect method to set up thereof and audio frequency playing method
CN105721261A (en) Intelligent loudspeaker box-based music push method and device
CN105323654A (en) Method and device for displaying content data from network
CN103295611A (en) Music automatic optimization system and method
CN102905185A (en) Method for full-voice control over HTML5 (Hypertext Markup Language 5) video playing
CN105824820A (en) Media file buffer memory method and device
CN1842002A (en) System and method for realizing broadcast content downloading service
WO2015085862A1 (en) Method and apparatus for playing 3d film sources in smart tv
CN102819577B (en) The function control method associated with file attribute and device
EP3249936A1 (en) Audio debugging method and device for television
US20160127792A1 (en) Online video playing system and method

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant