CN102497554A - Dividing method of chapters accurate to frames - Google Patents

Dividing method of chapters accurate to frames Download PDF

Info

Publication number
CN102497554A
CN102497554A CN2011104259628A CN201110425962A CN102497554A CN 102497554 A CN102497554 A CN 102497554A CN 2011104259628 A CN2011104259628 A CN 2011104259628A CN 201110425962 A CN201110425962 A CN 201110425962A CN 102497554 A CN102497554 A CN 102497554A
Authority
CN
China
Prior art keywords
frame
image sets
chapters
present frame
sections
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
CN2011104259628A
Other languages
Chinese (zh)
Other versions
CN102497554B (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.)
Hangzhou Silan Microelectronics Co Ltd
Original Assignee
Hangzhou Silan Microelectronics 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 Hangzhou Silan Microelectronics Co Ltd filed Critical Hangzhou Silan Microelectronics Co Ltd
Priority to CN201110425962.8A priority Critical patent/CN102497554B/en
Publication of CN102497554A publication Critical patent/CN102497554A/en
Application granted granted Critical
Publication of CN102497554B publication Critical patent/CN102497554B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

The invention provides a dividing method of chapters accurate to frames. The method comprises the following steps: a user defining a plurality of chapter division points which form chapter intervals defined by the user; gradually judging whether the current frame is the division point of one chapter, or only the start point of one chapter, or only the end point of one chapter or both the start point of one chapter and the end point of another chapter; and when the current frame is only the start point of one chapter, judging whether the current frame is the key frame, when the current frame is only the end point of one chapter, judging whether B frame coding exists in a group of pictures (GOP) in which the current frame is located, when the current frame is both the start point of one chapter and the end point of another chapter, judging whether the current frame is the key frame and is in the chapter intervals defined by the user, and carrying out corresponding chapter division when the judgment results fall into the corresponding results. The method has the following beneficial effects: the chapter division points which are unnecessarily key frames are taken as subsets of a chapter set, thus preventing the GOP structure from being affected to the greatest extent during code output; and fine division of the chapters is completed by processing the GOP in which the chapter division points are located.

Description

Chapters and sections are to the division methods of frame
Technical field
The invention belongs to image information and write treatment system, relate in particular to the division methods that a kind of chapters and sections are accurate to frame.
Background technology
The generation of digital video compaction technique and development have the meaning in abyss, are that the storage and the transmission of huge video data possibly become, and make digital video service be able to develop widely.Wherein, minimum units of video generally is used for depositing chapters and sections (Chapter).Digital video disk (Digital Video Disc; DVD), Blu-ray Disc (Blu-ray Disc; BD) and high definition TV (High Definition Television; The function of the chapters and sections in the navigation standard HDTV) makes the program that player can convenient, fast accessing writes down, and need not search for whole program for specific some pictures.The system of writing of some DVD, BD allows user oneself according to the content of video the part of a certain section video for certain chapters and sections to be set.
At present, because the digital video bitstream flow transmission mainly all is to transmit with compress mode.In these compressed video technology; Usually the frame of three types of definition I, B, P, and in source code flow I, B, three kinds of frame types of P in video coding be with image sets (Group of Pictures, structure GOP) comes layout to carry out video output; Be that each GOP is made up of N frame; Wherein, comprise 1 I frame, several P frames are formed with several B frames that intert in the middle of I, P frame.Said I frame is the key frame among the GOP; Key frame is to need not to rely on the frame that any other frame just can be decoded; Said P frame, B frame have constituted the non-key frame among the GOP jointly, but not key frame has only been stored the otherness data with respect to other key frame, so can't independently decode.
Here it is why much the system of writing can only force to carry out cutting apart of chapters and sections at key frame or the frame place that can independently decode.Be easy to cause same scene to be split to the phenomenon of different chapters and sections like this, make incoherent situation when program has in by the chapters and sections playing process.When the user need carry out the division of chapters and sections by non-key frame; Much the system of writing has adopted dual mode to solve this problem: 1, system decodes to the whole video file earlier; Carry out the division of chapters and sections at said non-key frame place then; Then said non-key frame is set at key frame, again recompile.2, a last key frame of said non-key frame is located by system, carries out the division of chapters and sections at described previous keyframe place then.First kind of scheme increased complexity and the overhead handled, and when content is decoded again and encoded each time, and the similitude of it and original contents is just more and more lower, and this will cause the decline of video quality.Second kind of scheme do not done by user's division expectation, causes chapters and sections to divide inaccuracy.
Therefore, do not have key frame, non-key frame just can't be decoded, or only through non-key frame decoding, source code flow is affected with the gop structure output video time, and then the system of writing is difficult to accurate montage, thereby causes video quality to descend.
Summary of the invention
Technical problem to be solved by this invention provides the division methods of a kind of chapters and sections to frame; So that the zone that can in a title, to define a plurality of chapters and sections cut-points simultaneously be boundary; And these need not is the subclass of the chapters and sections cut-point of key frame as the chapters and sections set; Thereby gop structure is not affected when having kept coding output most possibly, and through the processing of chapters and sections cut-point place GOP being accomplished the fine division of chapters and sections
For addressing the above problem, a kind of chapters and sections that the present invention proposes comprise that to the division methods of frame step is following:
To present frame is whether a chapters and sections cut-point is that any of three kinds of situation of chapters and sections starting point, chapters and sections end point or a chapters and sections starting point, another chapters and sections end point judged;
When judging that present frame is a non-key frame and when being merely a chapters and sections starting point; Begin to the data between the image sets end frame at present frame place through the recompile present frame; Guarantee therebetween frame to decode and do not rely on the frame before the present frame, and present frame is the start frame of new image sets;
When judging when B frame coding being arranged and be merely a chapters and sections end point during present frame is for the place image sets,, guarantee that therebetween frame can decode and do not rely on the frame after the present frame through the data between image sets start frame to the present frame at recompile present frame place;
At present frame is non-key frame and when being a chapters and sections starting point, another chapters and sections end point; Through the data between image sets start frame to the present frame at recompile present frame place; Guarantee therebetween frame to decode and do not rely on the frame after the present frame; The recompile present frame begins to the data between the image sets end frame at present frame place, guarantees that therebetween frame can decode and do not rely on the frame before the present frame, and present frame is the start frame of new image sets.
Concrete chapters and sections can be judged according to following process to the division methods of frame:
Step 1: input file is defined a plurality of chapters and sections cut-points, and it is interval to constitute user-defined chapters and sections through a plurality of chapters and sections cut-points, said input file comprises M two field picture group data, and M is the positive integer more than or equal to 1, and the sequence number of setting present frame is 1;
Step 2: judge whether present frame is one of said a plurality of chapters and sections cut-points, when judged result for being that then execution in step 3; When judged result is that then execution in step 7;
Step 3: judge whether present frame is merely a chapters and sections starting point, when judged result for being that then execution in step 5; When judged result is that then execution in step 4;
Step 4: judge whether present frame is merely a chapters and sections end point, when judged result for being that then execution in step 6; When judged result is that then execution in step 7;
Step 5: when present frame is merely a chapters and sections starting point, judge whether present frame is key frame, when judged result for being that then execution in step 8; When judged result is not; Then present frame is begun to the data recompile between the image sets end frame at present frame place; And present frame is encoded to new key frame, as the start frame of a new image sets, carry out the output of a new image sets; The sequence number of upgrading frame is: the sequence number of said present frame and present frame begin to add 1 to the coding frame number sum between the image sets end frame, go to step 2;
Step 6: when present frame is merely a chapters and sections end point; Judge whether present frame has B frame coding in image sets, when judged result for being that then the image sets start frame to the present frame place begins to the data recompile between the present frame end; And with the image sets start frame at present frame place start frame as a new image sets; Carry out the output of a new image sets, the sequence number of upgrading frame is: the sequence number of said present frame adds 1, goes to step 2; When judged result is that then execution in step 8;
Step 7: when present frame is a chapters and sections starting point, another chapters and sections end point, judge whether present frame is key frame, when judged result for being that then execution in step 8; When judged result is not; Then the image sets start frame to present frame place begins to carry out recompile to the data between the present frame, and with the start frame of image sets start frame as a new image sets, carries out the output of a new image sets; And present frame is begun to carry out recompile to the data between the image sets end frame at present frame place; And present frame is encoded to key frame, as the start frame of another new image sets, carry out the output of another new image sets; The sequence number of upgrading frame is: the sequence number of said present frame and present frame begin to add 1 to the coding frame number sum between the image sets end frame, go to step 2;
Step 8: judge that present frame is whether interval at user-defined chapters and sections, when judged result for being, then in the image sets at present frame place, present frame is exported, the sequence number of upgrading frame is that the sequence number of present frame adds 1, and the judgement of entering step 9; When judged result is that then execution in step 9;
Step 9: judge whether present frame is the M frame of input file, when judged result for being, then chapters and sections are divided and are finished; When judged result is not, then point to next frame, go to step 2.
Further, said present frame is merely a chapters and sections starting point, and when being non-key frame, specifically comprises the steps:
In the image sets at present frame place, navigate to the image sets start frame;
In the image sets at present frame place, navigate to the image sets end frame;
Data to the image sets start frame begins between (not comprising the image sets start frame) to the image sets end frame (not comprising the image sets end frame) are decoded;
Present frame is encoded to key frame and as the start frame of a new output image group;
Present frame is begun between (not comprising present frame) to the image sets end frame (not comprising the image sets end frame) data with reference to present frame be encoded to the key frame output one new image sets of encoding, write down present frame simultaneously and begin to the coding frame number between the image sets end frame;
The sequence number of upgrading frame is: the sequence number of said present frame and present frame begin to add 1 to the coding frame number sum between the image sets end frame;
Go to step 2.
Further, said present frame is merely a chapters and sections end point, and when image sets has B frame coding, specifically comprises the steps:
In the image sets at present frame place, navigate to the image sets start frame;
Decoding begins the data between (not comprising the image sets start frame) to present frame (the comprising present frame) end from the image sets start frame;
The image sets start frame is begun the data of (not comprising the image sets start frame) to present frame (comprising present frame) between the finishing new image sets of output one of encoding, the coding frame number between document image group start frame begins to finish to present frame simultaneously;
The sequence number of upgrading frame is: the sequence number of said present frame adds 1;
Go to step 2.
Further, said present frame is a chapters and sections end point, another chapters and sections starting point simultaneously, and when being non-key frame, specifically comprises the steps:
In the image sets at present frame place, navigate to the image sets start frame;
In the image sets at present frame place, navigate to image sets frame end frame;
Data to the image sets start frame begins between (not comprising the image sets start frame) to the image sets frame end frame (not comprising the image sets end frame) are decoded;
The image sets start frame is begun data between (not comprising the image sets start frame) to the present frame (not comprising present frame) the new image sets of output one of encoding, document image group start frame begins to the coding frame number between the present frame simultaneously;
Present frame is encoded to key frame and as the start frame of another new output image group;
Present frame is begun between (not comprising present frame) to the image sets frame end frame (not comprising the image sets end frame) data with reference to present frame be encoded to key frame encode output another new image sets, write down present frame simultaneously and begin to the coding frame number between the image sets frame end frame;
The sequence number of upgrading frame is: the sequence number of said present frame and present frame begin to add 1 to the coding frame number sum between the image sets frame end frame;
Go to step 2.
Visible by technique scheme; Can only force to carry out at the key frame place that chapters and sections are cut apart or when not having key frame with the multiple system of writing of traditional common, only carry out the technical scheme that chapters and sections cut apart at non-key frame place and compare, a kind of chapters and sections disclosed by the invention are to the division methods of frame; Owing to earlier the input file that the M frame is arranged in the title is defined a plurality of chapters and sections cut-points simultaneously; It is key frame that these chapters and sections cut-points need not, even non-key frame also can be used as the chapters and sections cut-point, with the zone of defined a plurality of chapters and sections cut-points as boundary; Thus, constituted user-defined chapters and sections interval; Simultaneously, these chapters and sections cut-points also will be as the subclass of chapters and sections set.Since the 1st frame; Present frame is judged; Whether the chapters and sections cut-point, whether the chapters and sections cut-point starting point, whether end point, the starting point that whether is all a chapters and sections cut-point and another chapters and sections cut-point of chapters and sections cut-point end point, whether the chapters and sections cut-point key frame, not be key frame how to be converted into new key frame and will transform after the front and back content of the new key frame particular contents such as corresponding division that carry out the front and back chapters and sections judge; When judged result falls into that the user imports all chapters and sections cut-points of record and the chapters and sections that are made up of a plurality of chapters and sections cut-points when interval; Thereby kept gop structure not to be affected most possibly, and when coding is through accomplishing the fine division of chapters and sections to the processing of the GOP at chapters and sections cut-point place.
Description of drawings
Fig. 1 is the division methods schematic diagram of a kind of chapters and sections of the present invention to frame.
Fig. 2 is used to for Fig. 1's that to describe cut-point be chapters and sections starting point and to cut apart associated frame be that the chapters and sections of the situation of key frame are cut apart sketch map;
Fig. 3 is used to for Fig. 1's that to describe cut-point be chapters and sections starting point and to cut apart associated frame be that the chapters and sections of the situation of non-key frame are cut apart sketch map;
Fig. 4 is used to for Fig. 1's that to describe cut-point be that chapters and sections end point and image sets do not have the chapters and sections of the situation of B frame coding to cut apart sketch map;
Fig. 5 is used to for Fig. 1's that to describe cut-point be that chapters and sections end point and image sets have the chapters and sections of the situation of B frame coding to cut apart sketch map;
Fig. 6 for Fig. 1 be used to describe cut-point be a last chapters and sections end point simultaneously for next chapter section end point, and the cut-point associated frame is that the chapters and sections of the situation of key frame are cut apart sketch map;
Fig. 7 for Fig. 1 be used to describe cut-point be a last chapters and sections end point simultaneously for next chapter section end point, and the cut-point associated frame is that the chapters and sections of the situation of non-key frame are cut apart sketch map.
Embodiment
For make above-mentioned purpose of the present invention, feature and advantage can be more obviously understandable, does detailed explanation below in conjunction with the accompanying drawing specific embodiments of the invention.
A lot of details have been set forth in the following description so that make much of the present invention.But the present invention can implement much to be different from alternate manner described here, and those skilled in the art can do similar popularization under the situation of intension of the present invention, so the present invention does not receive the restriction of following disclosed practical implementation.
A kind of chapters and sections that propose according to the present invention are made a concrete analysis of as follows to the division methods of frame:
Step 1: input file is defined a plurality of chapters and sections cut-points, and constitute the chapters and sections set, and constitute user-defined chapters and sections interval 100 through a plurality of chapters and sections cut-points by the chapters and sections cut-point; Said chapters and sections cut-point is unit with the frame; Said input file comprises M two field picture group data, and M is the positive integer more than or equal to 1, and M is the positive integer more than or equal to 1; The sequence number of setting present frame is 1, judges since first frame.
Then, judge the situation of present frame one by one:
Step 2: judge whether present frame is said chapters and sections cut-point 102, when judged result for being, then initiatively skip to the judgement 200 that whether is merely a chapters and sections starting point; When judged result for not, whether then get into is the interval judgements 103 of user-defined chapters and sections.
Step 3: judge whether present frame is merely a chapters and sections starting point 200, when judged result for being, whether then get into is the judgement 201 of key frame; When judged result is not, then initiatively skip to the judgement 300 that whether is merely a chapters and sections end point.
Step 4: judge whether present frame is merely a chapters and sections end point 300, whether when judged result is, then getting into is the judgement 301 that B frame coding is arranged; When judged result for not, whether then initiatively skip to is the judgement 400 of a chapters and sections starting point, another chapters and sections end point.
Step 5: when being merely a chapters and sections starting point, judge whether present frame is key frame 201, when judged result for being, whether then get into is the interval judgements 103 of user-defined chapters and sections; When judged result is not; In the image sets at present frame place, navigate to image sets start frame 202; In the image sets at present frame place, navigate to image sets end frame 203; Data to the image sets start frame begins between (not comprising the image sets start frame) to the image sets end frame (not comprising the image sets end frame) decode 204; Present frame is encoded to key frame and as the start frame 205 of a new output image group; Present frame is begun data between (not comprising present frame) to the image sets end frame (not comprising the image sets end frame) and be encoded to the key frame output one new image sets of encoding with reference to present frame; Write down present frame simultaneously and begin to the coding frame number 206 between the image sets end frame, the sequence number of upgrading frame is that the sequence number and the present frame of said present frame begins to add 1 (referring to 207) to the coding frame number sum between the image sets end frame, and whether go to present frame is the judgement of said chapters and sections cut-point 102.
Therefore; At present frame is under non-key frame and the situation for the corresponding frame of the starting point of chapters and sections cut-point; The described image sets start frame of this step is a preceding k1 key frame of the image sets at present frame place; K1 is integer and k1 >=1, and described preceding k1 key frame is first frame of the image sets at present frame place, and the described image sets end frame of this step refers to the former frame of back k2 key frame of present frame; K2 is integer and k2 >=1; K2 the key frame in described back is first frame of next image sets that and then need export of the image sets at present frame place, begins to the data between the image sets end frame at present frame place through the recompile present frame, and assurance frame therebetween can be decoded and do not relied on the frame before the present frame.
Step 6: when being merely a chapters and sections end point; Judge whether present frame has B frame coding 301 in image sets; When judged result for being; In the image sets at present frame place, navigate to image sets start frame 302; Decoding begins (not comprising the image sets start frame) to present frame from the image sets start frame and finishes the data 303 between (comprising present frame), the image sets start frame is begun (not comprising the image sets start frame) to present frame and finishes data between (comprising present frame) the new image sets of output one of encoding, the coding frame number between document image group start frame begins to finish to present frame simultaneously; The sequence number of upgrading frame is that the sequence number of said present frame adds 1 (referring to 304), and whether go to present frame is the judgement of said chapters and sections cut-point 102; When judged result for not, whether then get into is the judgement of user-defined chapters and sections interval 103.
Therefore; In the image sets of present frame place, have under B frame coding and the situation for the corresponding frame of the end point of chapters and sections cut-point; The described image sets start frame of this step is a preceding k3 key frame of the image sets at present frame place, and k3 is integer and k3 >=1, and described preceding k3 key frame is first frame of the image sets at present frame place; Through the data between image sets start frame to the present frame at recompile present frame place, guarantee that therebetween frame can decode and do not rely on the frame after the present frame.
Step 7: when being a chapters and sections starting point, another chapters and sections end point, judge whether present frame is key frame 400, when judged result for being, whether then get into is the interval judgements 103 of user-defined chapters and sections; When judged result is not; In the image sets at present frame place, navigate to image sets start frame 401; In the image sets at present frame place, navigate to image sets frame end frame 402; Data to the image sets start frame begins between (not comprising the image sets start frame) to the image sets frame end frame (not comprising the image sets end frame) decode 403; The image sets start frame is begun data between (not comprising the image sets start frame) to the present frame (not comprising present frame) the new image sets of output one of encoding; Document image group start frame begins to the coding frame number 404 between the present frame simultaneously; In the output image group, present frame is encoded to key frame 405, present frame is begun between (not comprising present frame) to the image sets frame end frame (not comprising the image sets end frame) data with reference to present frame be encoded to key frame encode output another new image sets, write down present frame simultaneously and begin to the coding frame number 406 between the image sets frame end frame; The sequence number of upgrading frame is that the sequence number and the present frame of said present frame begins to add 1 (referring to 407) to the coding frame number sum between the image sets frame end frame, and whether go to present frame is the judgement of said chapters and sections cut-point 102.
Therefore; At present frame is non-key frame and both under the situation for the corresponding frame of the end point of the starting point of chapters and sections cut-point and chapters and sections cut-point; The described image sets start frame of this step is a preceding k4 key frame of the image sets at present frame place, and k4 is integer and k4 >=1, and is described original; Preceding k4 key frame of code stream is first frame of described image sets; Through the data between image sets start frame to the present frame at recompile present frame place, guarantee that therebetween frame can decode and do not rely on the frame after the present frame, the described image sets end frame of this step is the former frame of back k5 key frame of present frame; K5 is integer and k5 >=1; K4 the key frame in described back is first frame of next image sets that and then need export of the image sets at present frame place, and the recompile present frame begins to the data between the image sets end frame at present frame place, and assurance frame therebetween can be decoded and do not relied on the frame before the present frame.
Step 8: judge whether present frame is user-defined chapters and sections interval 103; When judged result for being; Then in the image sets at present frame place, present frame is exported 104, the sequence number of upgrading frame is that the sequence number of present frame adds 1, and gets into whether present frame is the judgement of the M frame of input file; When judged result is whether then getting into present frame is not the judgement 106 of the M frame of input file.
Step 9: judge whether present frame is the M frame 106 of input file, when judged result for being, then chapters and sections are divided and are finished 107; When judged result is not, then point to next frame, whether go to present frame is the judgement 102 of said chapters and sections cut-point.
The 8th step was carried out the whether interval analysis of user-defined chapters and sections with each result in the 2nd step, the 5th step, the 6th step or the 7th step, thereby exported the input file of corresponding chapters and sections.
Based on above-mentioned analytic process, the flow chart of a kind of chapters and sections to the division methods of frame proposed, referring to Fig. 1, concrete partition process comprises the steps:
The a plurality of chapters and sections cut-points of 100 user definitions carry out chapters and sections in advance and divide;
The sequence number of 101 setting present frames is 1;
Are 102 present frames user-defined a certain chapters and sections cut-point? If then go to step 200, if not then going to step 103;
Are 103 present frames in user-defined chapters and sections interval? If then go to step 104, if not then going to step 105;
104 export present frame in the image sets at present frame place;
The sequence number of 105 renewal frames is sequence number+1 of said present frame;
Are 106 present frames the M number of input file? If then go to step 107, if not then going to step 102;
107 chapters and sections are divided and are finished, and withdraw from;
Are 200 present frames merely a new chapters and sections starting point? If then go to step 201, if not then going to step 300;
Are 201 present frames key frame? If then go to step 103, if not then going to 202;
202 navigate to preceding k1 key frame of image sets in the image sets at present frame place;
203 navigate to back k2 key frame of image sets in the image sets at present frame place;
204 couples of k1 begin (not comprising the k1 frame) to k2 end (not comprising the k2 frame) and decode;
205 are encoded to key frame j_key and as the start frame of a new output image group with present frame;
206 begin present frame (not comprising present frame) finishes (not comprising the k2 frame) with reference to the j_key new image sets of output one of encoding to k2, writes down the coding frame number of present frame between beginning to finish to k2 simultaneously;
The sequence number of 207 renewal frames is sequence number+coding frame number+1 of said present frame;
208 go to step 102;
Are 300 present frames merely a chapters and sections end point? If then go to step 301, if not then going to step 400;
Is there there B frame coding in the image sets at 301 present frames place? If have then go to step 302, if not then go to step 103;
302 navigate to preceding k3 key frame of image sets in the image sets at present frame place;
303 decodings begin (not comprising k3) to present frame from k3 and finish the data between (comprising present frame);
304 begin k3 (not comprising the k3 frame) to present frame finishes decoded data between (comprising present frame) the new image sets of output one of encoding, and writes down the coding frame number of k3 between beginning to finish to present frame simultaneously;
305 go to step 207;
Are 400 present frames key frame? If then go to step 103, if not then going to step 401;
401 navigate to preceding k4 key frame of image sets in the image sets at present frame place;
402 navigate to back k5 key frame of image sets in the image sets at present frame place;
403 couples of k4 begin (not comprising the k4 frame) to the data that k5 finished between (not comprising the k5 frame) and decode;
404 begin k4 (not comprising the k4 frame) to present frame finishes decoded data between (not comprising present frame) the new image sets of output one of encoding, and writes down the coding frame number of k4 between beginning to finish to present frame simultaneously;
405 are encoded to key frame j_key and as the start frame of a new output image group with present frame;
406 begin present frame (not comprising present frame) finishes decoded data between (not comprising the k5 frame) with reference to j_key another the new image sets of output of encoding to k5, writes down the coding frame number of present frame between beginning to finish to k5 simultaneously;
The sequence number of 407 renewal frames is that the sequence number+present frame of present frame begins to coding frame number+1 between the one key frame end of back;
408 go to step 102.
Chapters and sections shown in Figure 1 are merely a specific embodiment to the flow chart of the division methods of frame; Whether the starting point of chapters and sections cut-point, the judgement order in no particular order of the end point of end point, the starting point that whether is all a chapters and sections cut-point and another chapters and sections cut-point of chapters and sections cut-point whether in the present invention; Also can judge to be the end point of chapters and sections cut-point earlier; Carry out other judgement then; Also can judge the end point of the starting point that whether is all a chapters and sections cut-point and another chapters and sections cut-point earlier, carry out other judgement then.
Be example with schematic diagram shown in Figure 1 below,, the division methods of a kind of chapters and sections to frame be described in detail in conjunction with accompanying drawing 2 to 7.
At first; User definition chapters and sections cut-point; And it is interval 100 to constitute chapters and sections set and chapters and sections by the chapters and sections cut-point, and the user analyzes the 1st frame of input file, and the image sets data of input file is carried out M return one by one and judge; Every frame all as present frame, carries out the detailed description of the different situations of Fig. 2 to Fig. 7 respectively according to the situation of every frame in the process of judging.
Referring to Fig. 2, when judging that present frame is a user-defined chapters and sections cut-point 102, continuing to analyze said present frame is the starting point 200 of chapters and sections 1, and present frame is a key frame 201.Suppose that 55 frames are cut-point, at this moment, judge that present frame is whether in user-defined chapters and sections interval 103; As not when user-defined chapters and sections are interval; At this moment, can not export 55 frames all the elements 105 before, and will comprise that the content that 55 frames begin is divided to chapters and sections 1; As when user-defined chapters and sections are interval, can in the image sets at present frame place, export 104 to present frame.
Referring to Fig. 3, when judging that present frame is a user-defined chapters and sections cut-point 102, continuing to analyze said is the starting point 200 of chapters and sections 1, and present frame is non-key frame 201.Suppose that 55 frames are cut-point; At this moment; Cut-point need at first be located preceding k1 key frame 52 frames 202 in the image sets at 55 frames places, and locatees back k2 key frame 61 frames 203 in the image sets that 55 frames belong to, and the data that 52 frames begin (not comprise 61 frames) between (not comprising 52 frames) to 61 frames are decoded 204; 55 frames are encoded to new key frame (j_key) and as a new image sets start frame 205; Data between 56 frame to 60 frames with reference to the 55 frame j_key output of encoding, are not exported 55 frames all the elements before, and will be comprised that the content that 55 frames begin is divided to chapters and sections 1 (referring to 206 to 208 partition process).
Referring to Fig. 4, when judging that present frame is a user-defined chapters and sections cut-point 102, continuing to analyze said present frame is the end point 300 of chapters and sections 1, and the image sets at present frame place does not have B frame coding 301.Suppose that 61 frames are cut-point; At this moment; Judge that cut-point is whether in user-defined chapters and sections interval 103, as not when user-defined chapters and sections are interval, at this moment; Can directly abandon the data of 61 frames to next chapters and sections between beginning, described chapters and sections are begun to be divided to chapters and sections 1 (referring to 103 to 107 partition process) to the data of 61 frames; As when user-defined chapters and sections are interval, directly in the image sets at present frame place, present frame is exported.
Referring to Fig. 5, when judging that present frame is a user-defined chapters and sections cut-point 102, continuing to analyze said present frame is the end point 300 of chapters and sections 1, and the image sets at present frame place has B frame coding 301.Suppose that 61 frames are cut-point; At this moment; Preceding k3 key frame 52 frames 302 in the image sets at 61 frames place, needs location; The data that then 52 frames begun (not comprising 52 frames) to 61 frames (comprising 61 frames) end decode 303, the data between chapters and sections 1 starting point to 61 frame are encoded with reference to 52 frame j_key, and the data of chapters and sections 1 starting point to 61 frame are divided to chapters and sections 1 (referring to 304 to 305 partition process).
Referring to Fig. 6, when judging that present frame is a user-defined chapters and sections cut-point 102, the end point that continues to analyze said present frame and be chapters and sections 1 is the starting point of chapters and sections 2 simultaneously, and present frame is a key frame.Suppose that 61 frames are cut-point, at this moment, only need the content before 61 frames be allocated to chapters and sections 1,61 frames and later content are allocated to chapters and sections 2 (referring to 103 to 107 partition process).
Referring to Fig. 7, when judging that present frame is a user-defined chapters and sections cut-point 102, the end point that continues to analyze said present frame and be chapters and sections 1 is the starting point of chapters and sections 2 simultaneously, and present frame is non-key frame.Suppose that 61 frames are cut-point.At this moment, cut-point need be located preceding k4 key frame 52 frames in the image sets at 61 frames places, and locatees back k5 key frame 72 frames in the image sets at 61 frames place.Data between 52 frames (not comprising 52 frames) to 61 frames (not comprising 61 frames) are decoded, and then the data between 53 frame to 60 frames are divided to chapters and sections 1; Data between 61 frames to 71 are decoded; 61 frames are encoded to new key frame and as the start frame of a new image sets; Then with 62 frames begin to 71 data that finish with reference to the 61 frame j_key output of encoding, the data with 61 frame to 71 frames are divided to chapters and sections 2 (referring to 401 to 408 partition process) at last.
Visible by technique scheme; Can only force to carry out at the key frame place that chapters and sections are cut apart or when not having key frame with the multiple system of writing of traditional common, only carry out the technical scheme that chapters and sections cut apart at non-key frame place and compare, a kind of chapters and sections disclosed by the invention are to the division methods of frame; Owing to earlier the input file that the M frame is arranged in the title is defined a plurality of chapters and sections cut-points simultaneously; It is key frame that these chapters and sections cut-points need not, even non-key frame also can be used as the chapters and sections cut-point, with the zone of defined a plurality of chapters and sections cut-points as boundary; Thus, constituted user-defined chapters and sections interval; Simultaneously, these chapters and sections cut-points also will be as the subclass of chapters and sections set.Since the 1st frame; Present frame to the needs analysis is judged; Whether the chapters and sections cut-point, whether the chapters and sections cut-point starting point, whether end point, the starting point that whether is all a chapters and sections cut-point and another chapters and sections cut-point of chapters and sections cut-point end point, whether the chapters and sections cut-point key frame, not be key frame how to be converted into new key frame and and will transform after the front and back content of the new key frame particular contents such as corresponding division that carry out the front and back chapters and sections judge; When judged result falls into that the user imports all chapters and sections cut-points of record and the chapters and sections that are made up of a plurality of chapters and sections cut-points when interval; Thereby kept gop structure not to be affected most possibly, and when coding is through accomplishing the fine division of chapters and sections to the processing of the GOP at chapters and sections cut-point place.
Though the present invention with preferred embodiment openly as above; But it is not to be used for limiting claim; Any those skilled in the art are not breaking away from the spirit and scope of the present invention; Can make possible change and modification, so protection scope of the present invention should be as the criterion with the scope that claim of the present invention was defined.

Claims (5)

1. chapters and sections is characterized in that: comprise that step is following to the division methods of frame:
To present frame is whether a chapters and sections cut-point is that any of three kinds of situation of chapters and sections starting point, chapters and sections end point or a chapters and sections starting point, another chapters and sections end point judged;
When judging that present frame is a non-key frame and when being merely a chapters and sections starting point; Begin to the data between the image sets end frame at present frame place through the recompile present frame; Guarantee therebetween frame to decode and do not rely on the frame before the present frame, and present frame is the start frame of new image sets;
When judging when B frame coding being arranged and be merely a chapters and sections end point during present frame is for the place image sets,, guarantee that therebetween frame can decode and do not rely on the frame after the present frame through the data between image sets start frame to the present frame at recompile present frame place;
At present frame is non-key frame and when being a chapters and sections starting point, another chapters and sections end point; Through the data between image sets start frame to the present frame at recompile present frame place; Guarantee therebetween frame to decode and do not rely on the frame after the present frame; The recompile present frame begins to the data between the image sets end frame at present frame place, guarantees that therebetween frame can decode and do not rely on the frame before the present frame, and present frame is the start frame of new image sets.
2. chapters and sections according to claim 1 is characterized in that to the division methods of frame:
Step 1: input file is defined a plurality of chapters and sections cut-points, and it is interval to constitute user-defined chapters and sections through a plurality of chapters and sections cut-points, said input file comprises M two field picture group data, and M is the positive integer more than or equal to 1, and the sequence number of setting present frame is 1;
Step 2: judge whether present frame is one of said a plurality of chapters and sections cut-points, when judged result for being that then execution in step 3; When judged result is that then execution in step 7;
Step 3: judge whether present frame is merely a chapters and sections starting point, when judged result for being that then execution in step 5; When judged result is that then execution in step 4;
Step 4: judge whether present frame is merely a chapters and sections end point, when judged result for being that then execution in step 6; When judged result is that then execution in step 7;
Step 5: when present frame is merely a chapters and sections starting point, judge whether present frame is key frame, when judged result for being that then execution in step 8; When judged result is not; Then present frame is begun to the data recompile between the image sets end frame at present frame place; And present frame is encoded to new key frame, as the start frame of a new image sets, carry out the output of a new image sets; The sequence number of upgrading frame is: the sequence number of said present frame and present frame begin to add 1 to the coding frame number sum between the image sets end frame, go to step 2;
Step 6: when present frame is merely a chapters and sections end point; Judge whether present frame has B frame coding in image sets, when judged result for being, the data recompile between image sets start frame to the present frame that then present frame is belonged to; And with the image sets start frame at present frame place start frame as a new image sets; Carry out the output of a new image sets, the sequence number of upgrading frame is: the sequence number of said present frame adds 1, goes to step 2; When judged result is that then execution in step 8;
Step 7: when present frame is a chapters and sections starting point, another chapters and sections end point, judge whether present frame is key frame, when judged result for being that then execution in step 8; When judged result is not; Then the data between image sets start frame to the present frame at present frame place are carried out recompile, and with the start frame of image sets start frame, carry out the output of a new image sets as a new image sets; And present frame is begun to carry out recompile to the data between the image sets end frame at present frame place; And present frame is encoded to key frame, as the start frame of another new image sets, carry out the output of another new image sets; The sequence number of upgrading frame is: the sequence number of said present frame and present frame begin to add 1 to the coding frame number sum between the image sets end frame, go to step 2;
Step 8: judge that present frame is whether interval at user-defined chapters and sections, when judged result for being, then in the image sets at present frame place, present frame is exported, the sequence number of upgrading frame is: the sequence number of present frame adds 1, and the judgement of entering step 9; When judged result is that then execution in step 9;
Step 9: judge whether present frame is the M frame of input file, when judged result for being, then chapters and sections are divided and are finished; When judged result is not, then point to next frame, go to step 2.
3. chapters and sections according to claim 2 is characterized in that to the division methods of frame: said present frame is merely a chapters and sections starting point, and when being non-key frame, specifically comprises the steps:
In the image sets at present frame place, navigate to the image sets start frame;
In the image sets at present frame place, navigate to the image sets end frame;
The image sets start frame is begun to decode to the data between the image sets end frame;
Present frame is encoded to key frame and as the start frame of a new output image group;
With present frame begin to the data between the image sets end frame with reference to present frame be encoded to the key frame output one new image sets of encoding, write down present frame simultaneously and begin to the coding frame number between the image sets end frame;
The sequence number of upgrading frame is: the sequence number of said present frame and present frame begin to add 1 to the coding frame number sum between the image sets end frame;
Go to step 2.
4. chapters and sections according to claim 2 is characterized in that to the division methods of frame: said present frame is merely a chapters and sections end point, and when image sets has B frame coding, specifically comprises the steps:
In the image sets at present frame place, navigate to the image sets start frame;
Decoding begins to the data between the present frame end from the image sets start frame;
Data between the image sets start frame begun to finish to the present frame new image sets of output one of encoding, the coding frame number between document image group start frame begins to finish to present frame simultaneously;
The sequence number of upgrading frame is: the sequence number of said present frame adds 1;
Go to step 2.
5. chapters and sections according to claim 2 is characterized in that to the division methods of frame: said present frame is a chapters and sections end point, another chapters and sections starting point simultaneously, and when being non-key frame, specifically comprises the steps:
In the image sets at present frame place, navigate to the image sets start frame;
In the image sets at present frame place, navigate to image sets frame end frame;
The image sets start frame is begun to decode to the data between the image sets frame end frame;
The image sets start frame is begun to the output one new image sets of encoding of the data between the present frame, and document image group start frame begins to the coding frame number between the present frame simultaneously;
Present frame is encoded to key frame and as the start frame of another new output image group;
With present frame begin to the data between the image sets frame end frame with reference to present frame be encoded to key frame encode output another new image sets, write down present frame simultaneously and begin to the coding frame number between the image sets frame end frame;
The sequence number of upgrading frame is: the sequence number of said present frame and present frame begin to add 1 to the coding frame number sum between the image sets frame end frame;
Go to step 2.
CN201110425962.8A 2011-12-16 2011-12-16 Dividing method of chapters accurate to frames Active CN102497554B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201110425962.8A CN102497554B (en) 2011-12-16 2011-12-16 Dividing method of chapters accurate to frames

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201110425962.8A CN102497554B (en) 2011-12-16 2011-12-16 Dividing method of chapters accurate to frames

Publications (2)

Publication Number Publication Date
CN102497554A true CN102497554A (en) 2012-06-13
CN102497554B CN102497554B (en) 2014-04-16

Family

ID=46189336

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201110425962.8A Active CN102497554B (en) 2011-12-16 2011-12-16 Dividing method of chapters accurate to frames

Country Status (1)

Country Link
CN (1) CN102497554B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103024394A (en) * 2012-12-31 2013-04-03 传聚互动(北京)科技有限公司 Video file editing method and device
CN104065966A (en) * 2013-03-20 2014-09-24 三星电子(中国)研发中心 Method and device for extracting thumbnail in H.264 video file
CN105592356A (en) * 2014-10-22 2016-05-18 北京拓尔思信息技术股份有限公司 Audio-video online virtual editing method and system

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101026757A (en) * 2007-04-06 2007-08-29 清华大学 Multi-view video compressed coding-decoding method based on distributed source coding
CN101098483A (en) * 2007-07-19 2008-01-02 上海交通大学 Video cluster transcoding system using image group structure as parallel processing element
US20080056383A1 (en) * 2006-09-05 2008-03-06 Eiji Ueki Information processing apparatus and method
CN101459848A (en) * 2008-12-26 2009-06-17 西安交通大学 Distributed multi-format digital video transcoding construction design method

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080056383A1 (en) * 2006-09-05 2008-03-06 Eiji Ueki Information processing apparatus and method
CN101026757A (en) * 2007-04-06 2007-08-29 清华大学 Multi-view video compressed coding-decoding method based on distributed source coding
CN101098483A (en) * 2007-07-19 2008-01-02 上海交通大学 Video cluster transcoding system using image group structure as parallel processing element
CN101459848A (en) * 2008-12-26 2009-06-17 西安交通大学 Distributed multi-format digital video transcoding construction design method

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103024394A (en) * 2012-12-31 2013-04-03 传聚互动(北京)科技有限公司 Video file editing method and device
CN104065966A (en) * 2013-03-20 2014-09-24 三星电子(中国)研发中心 Method and device for extracting thumbnail in H.264 video file
CN104065966B (en) * 2013-03-20 2017-09-29 三星电子(中国)研发中心 The method and apparatus that thumbnail is extracted in H.264 video file
CN105592356A (en) * 2014-10-22 2016-05-18 北京拓尔思信息技术股份有限公司 Audio-video online virtual editing method and system

Also Published As

Publication number Publication date
CN102497554B (en) 2014-04-16

Similar Documents

Publication Publication Date Title
CN1305065C (en) Data reproducing method and data reproducing device
CN101164055B (en) Media timeline sorting
US11704328B2 (en) Columnar storage and query method and system for time series data
WO2017092340A1 (en) Method and device for compressing and playing video
CN1253879C (en) Additive information prodn. method, recording medium, and recording, edit and producing device
CN107370726B (en) Virtual slicing method and system for distributed media file transcoding system
US20080033978A1 (en) Program, data processing method, and system of same
CN1595994A (en) Method and device for sharing dynamic video compression buffer
CN101521782A (en) Method for fast-forward and fast-backward browsing video, system and multimedia equipment
CN104185088A (en) Video processing method and device
CN102497554A (en) Dividing method of chapters accurate to frames
CN103391467A (en) Method for achieving synchronization of decoding and displaying of audio and video of network set-top box
CN103841451A (en) Multimedia playing method, device and terminal
CN109511008B (en) Method for supporting video and audio file content addition based on object storage
CN103037211A (en) Decoding processing method, device and playing equipment of streaming media files
CN1273672A (en) Editing of digital video information signals
CN103165157A (en) Method and device for locating playing position of no-indexing audio video interleaved (AVI) file and player
CN104506390A (en) Log storage method and device of road test system
CN102387177B (en) Method and device for downloading audio-visual files
CN102047662A (en) Encoder
CN101090489B (en) Information processing apparatus and information processing method
US7664373B2 (en) Program, data processing method, and system of same
CN1567381A (en) Multimedia material synchronous editing device
CN116939291B (en) Video quick stripping method and related device
CN100433159C (en) Multisystem type information recording medium, information recording and playing method and device

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