The method and system of online quick editor's video based on web terminal
Technical field
The present invention relates to video technique field more particularly to a kind of methods of online quick editor's video based on web terminal
And system.
Background technique
" internet+" and " cloud storage " technology is increasingly mature at present, and all conglomeraties begin setting up video resource platform, will be straight
It broadcasts video and is indexed to cloud server, provide the video of multiple format for user, in the prior art, if compiled to video
When collecting, first foradownloaded video is needed, new file, technology of this mode to user are then generated by the Video editing software of profession
It is more demanding, it generally requires with skilled software using ability, meanwhile, the video if necessary to production is multiple video files
Splicing, then need to download multiple video files, if an only small fragment of a video, downloads a complete video,
Many storage resource and flow are thus wasted, biggish waste is caused.
Therefore, the prior art needs to improve.
Summary of the invention
The method of the invention discloses a kind of online quick editor's video based on web terminal, is deposited to solve the prior art
The problem of.
Based on one aspect of the present invention, the present invention provides a kind of method of online quick editor's video based on web terminal,
Include:
Video material library is established, the video material in the video material library includes the order video and live streaming that user uploads
The video included in the process;
HLS video protocols agency service is configured, video is played with HLS format, when there are other video formats, accesses transcoding
Module changes extended formatting video into HLS format;
It is embedded in page video player in front end page, and HLS format video is passed to page video player;
The one or more videos to be edited, the input time on page video player are selected out of video material library
Point is directly dragged to editor's queue as the start time point and end time point of video shearing, edits according to editing in queue
The time point of video will edit the list of videos in queue and serialize, and then sends list of videos to fast and compiles module;
Fast module of compiling receives the list of videos information edited in queue, in line coding by list of videos information, from material
Source file address is found in library, and source file is sheared according to video time point, is in order new by each shearing video-splicing
File, and save to material database.
In another embodiment of the method based on above-mentioned online quick editor's video based on web terminal, the HLS view
Frequency agreement is the video protocols based on http streaming broadcasting, including video file cut into multistage video segment, when broadcasting according to
Secondary request video segment file, the HLS video protocols are not limited when operating video by key frame, can accurate edits video position
It sets.
In another embodiment of the method based on above-mentioned online quick editor's video based on web terminal, the page
Video player is Flash player, and the Flash player has the function of to customize, by between Java Script
Interactive operation is realized in communication.
In another embodiment of the method based on above-mentioned online quick editor's video based on web terminal, the video
List includes:
Video sart point in time, video end time point, video file, video editing serial number;
The video sart point in time and video end time point are in video material library when the original broadcasting of video file
Between point be starting point;
The video file is the file after video clipping;
When video editing serial number editor's video generates new video file, this section of video is suitable in video file
Serial number.
It is described to compile in another embodiment of the method based on above-mentioned online quick editor's video based on web terminal
It collects the list of videos in queue and serializes and include:
Time point is arranged in video file, and is dragged to editor's queue, the time point includes sart point in time and end
Time point;
Edit the number of queue record video file, filename, setting time point;
The editor for completing all video files, to video file according to generate new video video file in sequence into
Row number serializes list of videos;
It is lined up according to list of videos serial number.
Based on another aspect of the present invention, what the present invention provided a kind of online quick editor's video based on web terminal is
System, comprising: web terminal, HLS proxy server, transcoding module, video material library;
The web terminal is the fast volume display unit and fast volume display interface for carrying out video editing, for keeping user intuitive
To video file preview, editing, setting time point and the operation for being dragged in editor's queue, the list of videos sequence in queue will be edited
Change, the web terminal includes video player;
The HLS proxy server is the video playing proxy server based on http, and the HLS proxy server will regard
Frequency file cuts into multistage video segment, and when broadcasting successively requests video segment file, limits vision operation by key frame,
It is accurately positioned editor position;
The transcoding module is used to being converted to the non-HLS format video file in the video material library into HLS format view
Frequency file, and the HLS format video file generated after HLS proxy server editor is converted into suitable video material library storage
The video file of format;
For storing video file, the video file includes the order video that user uploads and straight in the video material library
The video included during broadcasting;
The web terminal is connect with HLS proxy server, and the HLS proxy server passes through transcoding module and video material
Library connection.
In another embodiment of the system based on above-mentioned online quick editor's video based on web terminal, the video
Player is Flash player, and the Flash player has the function of to customize, by logical between Java Script
News realize interactive operation.
In another embodiment of the system based on above-mentioned online quick editor's video based on web terminal, the setting
Time point includes sart point in time and end time point, and the sart point in time is that setting starts editing on the video of editing
Time point mark, and the flag information of sart point in time is recorded, the end time point is to be arranged to terminate on the video of editing
The time point of editing indicates, and the flag information at record end time point.
In another embodiment of the system based on above-mentioned online quick editor's video based on web terminal, the video
List includes: video number, setting time point, video files names;
The list of videos serializing is numbered by video to be arranged.
Compared with prior art, the invention has the following advantages that
The present invention directly acquires video file from video material library using web terminal, by multiple format video file by turning
Code module is converted into HLS file, and by configuring HLS agency service, in the fast volume display interface of web terminal, is played using Flash
Device will edit the list of videos sequence in queue to video file preview, editing, setting time point and the operation for being dragged in editor's queue
Columnization are spliced according to the time point of reference number of a document and setting, complete the editor of video file, and the present invention is not necessarily to client branch
It holds, plays the advantage of cloud storage, read video online, reduce the frequency of user's upload, foradownloaded video, reach primary upload, it is more
The effect of secondary editor, the video processing based on HLS protocol, better precise video position is played best edit effect, is promoted
User experience.
Below by drawings and examples, technical scheme of the present invention will be described in further detail.
Detailed description of the invention
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, to embodiment or will show below
There is attached drawing used in technical description to do one simply to introduce.
Fig. 1 is a kind of process of one embodiment of the method for online quick editor's video based on web terminal of the invention
Figure.
Fig. 2 is a kind of stream of another embodiment of the method for online quick editor's video based on web terminal of the invention
Cheng Tu.
Fig. 3 is a kind of structure of one embodiment of the system of online quick editor's video based on web terminal of the invention
Schematic diagram.
In figure: 1 web terminal, 2 HLS proxy servers, 3 transcoding modules, 4 video material libraries.
Specific embodiment
In order to make the object, technical scheme and advantages of the embodiment of the invention clearer, below in conjunction with the embodiment of the present invention
In attached drawing, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that described embodiment is only
It is only a part of the embodiment of the present invention, instead of all the embodiments.
Based on the embodiments of the present invention, those of ordinary skill in the art are obtained without making creative work
The every other embodiment obtained, shall fall within the protection scope of the present invention.
Fig. 1 is a kind of process of one embodiment of the method for online quick editor's video based on web terminal of the invention
Figure, as shown in Figure 1, the method for online quick editor's video based on web terminal includes:
10, video material library 4 is established, the video material in the video material library 4 includes the order video that user uploads
With the video included during live streaming, the video material library 4 can be the video image data library based on cloud storage, video
Image is provided by cloud server;
20, HLS video protocols agency service is configured, video is played with HLS format, when there is other video formats, access
Transcoding module 3 changes extended formatting video into HLS format, and the online player of the prior art is all based on broadcasting for http agreement
Device is put, needs just to start to play after the completion of video download, such as MP4, FLV format player, these players load slower, nothing
Method obtains the duration information of video at the first time, seek function existing defects, can only seek to key frame and the number buffered
According to position, it can not be accurately positioned video location, error is larger when causing to edit video, the HLS association of the streaming broadcasting based on http
View, principle are that video is cut into multistage slice, and request slice file, this mode are played fast, grasped in order when broadcasting
Make not limited by key frame when video, energy accurate edits position reaches better shear effect;
30, it is embedded in page video player in front end page, and HLS format video is passed to page video player, institute
State page video player be Flash player, the Flash player have the function of customization, by with Java Script
Between communication, realize interactive operation, be embedded in Flash player, the editting function of video is realized that Flash broadcasts playing end
The access point record for putting device setting editor's video, as the start time point and end time point of video shearing, and provides interface
Transmission start time point and end time point are to editor's queue;
40, the one or more videos to be edited are selected out of video material library 4, when inputting on page video player
Between point, as video shearing start time point and end time point, be directly dragged to editor's queue, according to editor queue in compile
The time point of video is collected, the list of videos in queue will be edited and serialized, then sends list of videos to fast volume module;
50, fast module of compiling receives the list of videos information edited in queue, in line coding by list of videos information, from element
Source file address is found in material library, and source file is sheared according to video time point, is by each shearing video-splicing in order
New file, and save to material database.
The list of videos includes: video sart point in time, video end time point, video file, video editing serial number;
The video sart point in time and video end time point are in video material library when the original broadcasting of video file
Between point be starting point can accurately position by video sart point in time and video end time point and need editing video
Starting position and end position, the starting position of positioning video and end position are simultaneously sheared, and the video file of shearing is spelled
It closes to setting position, that is, realizes the editor of video file
The video file is the file after video clipping, and the when a length of video end time point of the video file subtracts
Video sart point in time;
When video editing serial number editor's video generates new video file, this section of video is suitable in video file
Serial number, when the video editing serial number jointing video, the location of video file number.
Fig. 2 is a kind of stream of another embodiment of the method for online quick editor's video based on web terminal of the invention
Cheng Tu, as shown in Fig. 2, described include: by the list of videos serializing edited in queue
41, time point is arranged in video file, and be dragged to editor's queue, the time point includes sart point in time and knot
Beam time point;
42, edit the number of queue record video file, filename, setting time point;
43, the editor of all video files is completed, to video file according to suitable in the video file for generating new video
Sequence is numbered, and list of videos is serialized;
44, it is lined up according to list of videos serial number.
Fig. 3 is a kind of structure of one embodiment of the system of online quick editor's video based on web terminal of the invention
Schematic diagram, as shown in figure 3, the system of online quick editor's video based on web terminal includes:
Web terminal 1, HLS proxy server 2, transcoding module 3, video material library 4;
The web terminal 1 is the fast volume display unit and fast volume display interface for carrying out video editing, for keeping user intuitive
To video file preview, editing, setting time point and the operation for being dragged in editor's queue, the list of videos sequence in queue will be edited
Change, the web terminal 1 includes video player;
The video player be Flash player, the Flash player have the function of customization, by with Java
Interactive operation is realized in communication between Script.
The video player of common web terminal 1 mainly has HTML5 and Flash at present, and the video label of HTML5 is many clear
Lan Qi manufacturer has all supported, but function is thin, can only optimized integration vision operation, new method, Flash can not be customized
Player can customize, and by the communication between JavaScript, realize multiple functional interactive operation, be embedded in Flash
Player, by the editting function of video play end realize, Flash player can input video access point record, as view
The start time point of frequency shearing, and interface transmission start time point is provided to editor's queue.
The HLS proxy server 2 is the video playing proxy server based on http, and the HLS proxy server 2 will
Video file cuts into multistage video segment, and when broadcasting successively requests video segment file, limits vision operation by key frame
System is accurately positioned editor position;
The transcoding module 3 is used to being converted to the non-HLS format video file in the video material library into HLS format view
Frequency file, and the HLS format video file generated after HLS proxy server editor is converted into suitable video material library storage
The video file of format;
The player plays network video of the prior art is all based on http agreement, and mode of operation is first will be under video
It carries, starts to play after the completion of downloading, such as MP4, FLV video player, not only result of broadcast is poor for these players, Er Qiebo
It is slower to put device loading velocity, video length information can not be obtained at the first time, the function of seek is mostly defective, can only seek arrive
Key frame and the Data Position buffered, can not be accurately positioned video location, and error is larger when causing to edit video.Using being based on
Video is cut into multistage slice by the streaming broadcasting HLS protocol of http, and successively request slice file, this mode are broadcast when broadcasting
Put quick, do not limited by key frame when operating video, can accurate edits position, reach better shear effect, when there is other views
When frequency format, transcoding module 3 is accessed, turns it and changes HLS format into, be passed to player editor.
The video material library 4 for storing video file, the video file include the order video that user uploads and
The video included during live streaming;
The web terminal 1 is connect with HLS proxy server 2, and the HLS proxy server 2 passes through transcoding module 3 and video
Material database 4 connects.
Setting time point includes sart point in time and end time point on the video file for compiling display interface fastly, described to open
Time point begin as the time point mark for starting editing is arranged on the video of editing, and records the flag information of sart point in time,
The end time point indicates for the time point that setting terminates editing on the video of editing, and the mark at record end time point
Information.
List of videos in video queue includes: video number, setting time point, video files names, the video
Listing sequenceization is numbered by video and is arranged.
Detailed Jie has been carried out to a kind of method of online quick editor's video based on web terminal provided by the present invention above
It continues, used herein a specific example illustrates the principle and implementation of the invention, and the explanation of above embodiments is only
It is to be used to help understand method and its core concept of the invention;At the same time, for those skilled in the art, according to this hair
Bright thought, there will be changes in the specific implementation manner and application range, in conclusion the content of the present specification should not manage
Solution is limitation of the present invention.
Finally, it should be noted that the foregoing is only a preferred embodiment of the present invention, it is not intended to restrict the invention,
Although the present invention is described in detail referring to the foregoing embodiments, for those skilled in the art, still may be used
To modify the technical solutions described in the foregoing embodiments or equivalent replacement of some of the technical features,
All within the spirits and principles of the present invention, any modification, equivalent replacement, improvement and so on should be included in of the invention
Within protection scope.