CN102769715B - A kind of method and system of code stream editing - Google Patents

A kind of method and system of code stream editing Download PDF

Info

Publication number
CN102769715B
CN102769715B CN201210093688.3A CN201210093688A CN102769715B CN 102769715 B CN102769715 B CN 102769715B CN 201210093688 A CN201210093688 A CN 201210093688A CN 102769715 B CN102769715 B CN 102769715B
Authority
CN
China
Prior art keywords
audio
video
module
data
frame data
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.)
Expired - Fee Related
Application number
CN201210093688.3A
Other languages
Chinese (zh)
Other versions
CN102769715A (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.)
China Digital Video Beijing Ltd
Original Assignee
China Digital Video Beijing 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 China Digital Video Beijing Ltd filed Critical China Digital Video Beijing Ltd
Priority to CN201210093688.3A priority Critical patent/CN102769715B/en
Publication of CN102769715A publication Critical patent/CN102769715A/en
Application granted granted Critical
Publication of CN102769715B publication Critical patent/CN102769715B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Television Signal Processing For Recording (AREA)

Abstract

The invention discloses a kind of method and system of code stream editing, by reading video/audio, judge whether frame of video and audio unit need to reconstruct simultaneously, if desired for, then reconstructed accordingly respectively, after reconstruct, structure corresponding to voice data is attached in video data structure, realize the synchronization of video and audio, the data after synchronization are converted into object format again, realize only to shearing place video pictures group GOP and audio unit carry out the encoding and decoding that may need and audio reconstruction, and other most of video pictures group GOP and audio unit only need to replicate, substantially increase the efficiency of synthesis, reduce the loss of video and audio quality, maintain the quality of former video and audio.

Description

A kind of method and system of code stream editing
Technical field
The present invention relates to video and audio editing field, more particularly to a kind of method and system of code stream editing.
Background technology
With the enhancing of computer process ability, video and audio treatment technology there has also been significant progress.Video and audio processing During, video and audio editing is most commonly used technology.
The video and audio editing of prior art is generally based on frame of video and audio frame, is first decoded, after carrying out editing, Coding is being re-started, is being exported again afterwards.The process of encoding and decoding is a very complicated process, thus the efficiency of editing is very low.
The minimum unit of video is frame, and the minimum unit of audio is sampled point Sample, in the demand to higher efficiency, With regard to needing a kind of code stream editing system.
The content of the invention
To solve the above problems, the invention provides a kind of method and system of code stream editing, only to shearing place The encoding and decoding and audio reconstruction that video pictures group GOP and audio unit progress may need, and other most of video pictures Group GOP and audio unit only need to replicate, and substantially increase the efficiency of synthesis, reduce the loss of video and audio quality, maintain original The quality of video and audio.
One aspect of the present invention provides a kind of method of code stream editing, comprises the following steps:
Step 101, video/audio is read, while enters step 102 and step 105;
Step 102, judge whether the video pictures group GOP in the video/audio where n frame data needs code stream Reconstruct, if so, into step 103, if not into step 104;
Step 103, code stream reconstruct is carried out to the video pictures group GOP, afterwards into step 109;
Step 104, judge n frame data whether the last frame for being video pictures group GOP, if into step 109, if It is no to enter step 101;
Step 105, judge whether the audio of n frame data in the video/audio module needs to abandon, if so, into Step 106, if it is not, into step 107;
Step 106, the audio for abandoning the n frame data forms sky data, into step 109;
Step 107, judge whether the audio of the n frame data needs to reconstruct, if into step 108, if it is not, into Step 109;
Step 108, the audio of the n frame data is reconstructed;
Step 109, video and audio synchrodata is obtained;
Step 110, the video and audio synchrodata is converted into object format.
Another aspect of the present invention provides a kind of system of code stream editing, including with lower module:
Video/audio read module 201, for reading video/audio, it is connected with module 202 and module 205;
Video data reconstructs judge module 202, for judging the picture group in the video/audio where n frame data Whether GOP needs code stream to reconstruct;
Video data reconstructed module 203, code stream reconstruct is carried out to the picture group GOP;
Last frame determination module 204, judge n frame data whether the last frame for being picture group GOP;
Voice data abandons determination module 205, and whether judge the audio of n frame data in the video/audio module needs Abandon;
Empty audio generation module 206, the audio for abandoning the n frame data form sky data;
Voice data reconstructs judge module 207, and whether the audio for judging the n frame data needs to reconstruct;
Voice data reconstructed module 208, for the audio of the n frame data to be reconstructed;
Video/audio synchronization module 209, for video data and voice data is synchronous, obtain the same step number of video and audio According to;
Format converting module 210, for the video and audio synchrodata to be converted into object format.
What the technical scheme of the embodiment of the present invention was brought has the beneficial effect that:By reading video/audio, judge simultaneously Whether frame of video and audio frame need to reconstruct, if desired, then being reconstructed accordingly respectively, after reconstruct, by voice data pair The structure answered is attached in video data structure, realizes the synchronization of video and audio, then the data after synchronization are converted into object format, real Showed only to shearing place video pictures group GOP and audio unit carry out the encoding and decoding that may need and audio reconstruction, and Other most of video pictures group GOP and audio unit only need to replicate, and substantially increase the efficiency of synthesis, reduce video and audio The loss of quality, maintain the quality of former video and audio.
Brief description of the drawings
In order to illustrate more clearly about the embodiment of the present invention or technical scheme of the prior art, below will be to embodiment or existing There is the required accompanying drawing used in technology description to be briefly described, it should be apparent that, drawings in the following description are only this Some embodiments of invention, for those of ordinary skill in the art, without having to pay creative labor, may be used also To obtain other accompanying drawings according to these accompanying drawings.
Fig. 1 is the embodiment of the present invention one, a kind of flow chart of the method for code stream editing;
Fig. 2 is the embodiment of the present invention two, a kind of structure chart of the system of code stream editing.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is carried out clear, complete Site preparation describes, it is clear that described embodiment is part of the embodiment of the present invention, rather than whole embodiments.Based on this hair Embodiment in bright, the every other implementation that those of ordinary skill in the art are obtained under the premise of creative work is not made Example, belongs to the scope of protection of the invention.
Embodiment one
The embodiments of the invention provide a kind of method of code stream editing, such as Fig. 1, comprise the following steps:
Step 101, video/audio is read, while enters step 102 and step 105;
Wherein, video/audio is read sequentially to read the video/audio from files in stream media, and can not be repeated Read video/audio.
Step 102, judge whether the video pictures group GOP in the video/audio where n frame data needs code stream Reconstruct, if so, into step 103, if not into step 104;
Step 103, code stream reconstruct is carried out to the picture group GOP, into step 109;
Step 104, judge n frame data whether the last frame for being picture group GOP, if into step 109, enter if not Enter step 101;
Step 105, judge whether the audio of n frame data in the video/audio module needs to abandon, if so, into Step 106, if it is not, into step 107;
Step 106, the audio for abandoning the n frame data forms sky data, into step 109;
Step 107, judge whether the audio of the n frame data needs to reconstruct, if into step 108, if it is not, into Step 109;
Step 108, the audio of the n frame data is reconstructed, into step 109;
Step 109, it is video data and voice data is synchronous;
It is specially synchronously by video data and voice data:
The data structure for the picture group GOP structure of the audio of the n frame data being attached to where the n frame data In.
Step 110, the video and audio synchrodata is converted into object format.
Wherein, object format includes:TS forms, MP4 forms and FLV forms.
What the technical scheme of the embodiment of the present invention was brought has the beneficial effect that:By reading video/audio, judge simultaneously Whether frame of video and audio frame need to reconstruct, if desired, then being reconstructed accordingly respectively, after reconstruct, by voice data pair The structure answered is attached in video data structure, realizes the synchronization of video and audio, then the data after synchronization are converted into object format, real Showed only to shearing place video pictures group GOP and audio unit carry out the encoding and decoding that may need and audio reconstruction, and Other most of video pictures group GOP and audio unit only need to replicate, and substantially increase the efficiency of synthesis, reduce video and audio The loss of quality, maintain the quality of former video and audio.
Embodiment two:
A kind of system of code stream editing of offer of the embodiment of the present invention, such as Fig. 2, including with lower module:
Video/audio read module 201, for reading video/audio, it is connected with module 202 and module 205;
Wherein, video/audio is read sequentially to read the video/audio from files in stream media, and can not be repeated Read video/audio.
Video data reconstructs judge module 202, for judging the picture group in the video/audio where n frame data Whether GOP needs code stream to reconstruct;
Video data reconstructed module 203, code stream reconstruct is carried out to the picture group GOP;
Last frame determination module 204, judge n frame data whether the last frame for being picture group GOP;
Voice data abandons determination module 205, and whether judge the audio of n frame data in the video/audio module needs Abandon;
Empty audio generation module 206, the audio for abandoning the n frame data form sky data;
Voice data reconstructs judge module 207, and whether the audio for judging the n frame data needs to reconstruct;
Voice data reconstructed module 208, for the audio of the n frame data to be reconstructed;
Video/audio synchronization module 209, for video data and voice data is synchronous, obtain the same step number of video and audio According to;
It is specially synchronously by video data and voice data:
The data structure for the picture group GOP structure of the audio of the n frame data being attached to where the n frame data In.
Format converting module 210, for the video and audio synchrodata to be converted into object format.
Including:
TS video and audios are multiplexed submodule;
MP4 video and audios synthesize submodule;
FLV video and audios synthesize submodule.
What the technical scheme of the embodiment of the present invention was brought has the beneficial effect that:By reading video/audio, judge simultaneously Whether frame of video and audio frame need to reconstruct, if desired, then being reconstructed accordingly respectively, after reconstruct, by voice data pair The structure answered is attached in video data structure, realizes the synchronization of video and audio, then the data after synchronization are converted into object format, real Showed only to shearing place video pictures group GOP and audio unit carry out the encoding and decoding that may need and audio reconstruction, and Other most of video pictures group GOP and audio unit only need to replicate, and substantially increase the efficiency of synthesis, reduce video and audio The loss of quality, maintain the quality of former video and audio.
Through the above description of the embodiments, those skilled in the art can be understood that the present invention can lead to Hardware realization is crossed, the mode of necessary general hardware platform can also can be added by software to realize, based on such understanding, this The technical scheme of invention can be embodied in the form of software product, and the software product can be stored in one and non-volatile deposit In storage media (can be CD-ROM, USB flash disk, mobile hard disk etc.), including some instructions are causing a computer equipment (can be with It is personal computer, server, or network equipment etc.) perform method described in each embodiment of the present invention.
In a word, the foregoing is merely illustrative of the preferred embodiments of the present invention, is not intended to limit the scope of the present invention. Within the spirit and principles of the invention, any modification, equivalent substitution and improvements made etc., it should be included in the present invention's Within protection domain.

Claims (10)

  1. A kind of 1. method of code stream editing, it is characterised in that comprise the following steps:
    Step 101, video/audio is read, while enters step 102 and step 105;
    Step 102, judge whether the video pictures group GOP in the video/audio where n frame data needs code stream to reconstruct, If so, into step 103, if not into step 104;
    Step 103, code stream reconstruct is carried out to the video pictures group GOP, afterwards into step 109;
    Step 104, judge the n frame data whether the last frame for being the video pictures group GOP, if into step 109, if not into step 101;
    Step 105, judge whether the audio of n frame data in the video/audio module needs to abandon, if so, into step 106, if it is not, into step 107;
    Step 106, the audio for abandoning the n frame data forms sky data, into step 109;
    Step 107, judge whether the audio of the n frame data needs to reconstruct, if into step 108, if it is not, into step 109;
    Step 108, the audio of the n frame data is reconstructed;
    Step 109, video and audio synchrodata is obtained;
    Step 110, the video and audio synchrodata is converted into object format.
  2. 2. method as claimed in claim 1, it is characterised in that video/audio is read described in step 101 is specially:From Streaming Media The video/audio is sequentially read in file.
  3. 3. method as claimed in claim 2, it is characterised in that described that the video and audio number is sequentially read from files in stream media According to, it is impossible to repeat to read video/audio.
  4. 4. method as claimed in claim 1, it is characterised in that video and audio synchrodata is obtained described in step 109 is specially:
    The data structure for the video pictures group GOP structure of the audio of the n frame data being attached to where the n frame data In.
  5. 5. method as claimed in claim 1, it is characterised in that object format includes described in step 110:TS forms, MP4 forms with And FLV forms.
  6. 6. a kind of system of code stream editing, it is characterised in that including with lower module:
    Video/audio read module 201, for reading video/audio, it is connected with module 202 and module 205;
    Video data reconstructs judge module 202, for judging the picture group GOP in the video/audio where n frame data Whether code stream is needed to reconstruct;
    Video data reconstructed module 203, code stream reconstruct is carried out to the picture group GOP;
    Last frame determination module 204, judge the n frame data whether the last frame for being the video pictures group GOP;
    Voice data abandons determination module 205, judges whether the audio of n frame data in the video/audio module needs to lose Abandon;
    Empty audio generation module 206, the audio for abandoning the n frame data form sky data;
    Voice data reconstructs judge module 207, and whether the audio for judging the n frame data needs to reconstruct;
    Voice data reconstructed module 208, for the audio of the n frame data to be reconstructed;
    Video/audio synchronization module 209, for video data and voice data is synchronous, obtain video and audio synchrodata;
    Format converting module 210, for the video and audio synchrodata to be converted into object format.
  7. 7. system as claimed in claim 6, it is characterised in that video/audio is read described in module 201 is specially:From Streaming Media The video/audio is sequentially read in file.
  8. 8. system as claimed in claim 7, it is characterised in that described that the video and audio number is sequentially read from files in stream media According to, it is impossible to repeat to read video/audio.
  9. 9. system as claimed in claim 6, it is characterised in that described in module 209 that video data and voice data is synchronously specific For:
    In the data structure for the picture group GOP structure of the audio of the n frame data being attached to where the n frame data.
  10. 10. system as claimed in claim 6, it is characterised in that the format converting module 210 includes:
    TS video and audios are multiplexed submodule;
    MP4 video and audios synthesize submodule;
    FLV video and audios synthesize submodule.
CN201210093688.3A 2012-03-31 2012-03-31 A kind of method and system of code stream editing Expired - Fee Related CN102769715B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201210093688.3A CN102769715B (en) 2012-03-31 2012-03-31 A kind of method and system of code stream editing

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201210093688.3A CN102769715B (en) 2012-03-31 2012-03-31 A kind of method and system of code stream editing

Publications (2)

Publication Number Publication Date
CN102769715A CN102769715A (en) 2012-11-07
CN102769715B true CN102769715B (en) 2017-12-29

Family

ID=47096960

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201210093688.3A Expired - Fee Related CN102769715B (en) 2012-03-31 2012-03-31 A kind of method and system of code stream editing

Country Status (1)

Country Link
CN (1) CN102769715B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104768025B (en) * 2015-04-02 2018-05-08 无锡天脉聚源传媒科技有限公司 A kind of video bad frame restorative procedure and device
CN114143601A (en) * 2021-12-06 2022-03-04 北京达佳互联信息技术有限公司 Method, device, electronic equipment, storage medium and program product for cutting video

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101287122A (en) * 2008-05-23 2008-10-15 清华大学 Video decoding method with active buffer management and complexity control function
CN101345790A (en) * 2007-07-09 2009-01-14 上海基信通讯技术有限公司 Method for editing audio files in mobile phone
CN101867692A (en) * 2009-02-03 2010-10-20 美国博通公司 A kind of communication means and communication system
CN101873498A (en) * 2010-06-22 2010-10-27 深圳市融创天下科技发展有限公司 Video decoding method, video decoding device and video/audio play system
CN102075528A (en) * 2010-12-27 2011-05-25 上海聚欣网络科技有限公司 Method and equipment for playing network multimedia files of multiple encapsulation formats

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8606848B2 (en) * 2009-09-10 2013-12-10 Opentv, Inc. Method and system for sharing digital media content

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101345790A (en) * 2007-07-09 2009-01-14 上海基信通讯技术有限公司 Method for editing audio files in mobile phone
CN101287122A (en) * 2008-05-23 2008-10-15 清华大学 Video decoding method with active buffer management and complexity control function
CN101867692A (en) * 2009-02-03 2010-10-20 美国博通公司 A kind of communication means and communication system
CN101873498A (en) * 2010-06-22 2010-10-27 深圳市融创天下科技发展有限公司 Video decoding method, video decoding device and video/audio play system
CN102075528A (en) * 2010-12-27 2011-05-25 上海聚欣网络科技有限公司 Method and equipment for playing network multimedia files of multiple encapsulation formats

Also Published As

Publication number Publication date
CN102769715A (en) 2012-11-07

Similar Documents

Publication Publication Date Title
KR101387212B1 (en) System and method for generating and playing three dimensional image files based on two dimensional image media standards
CN108235052A (en) Multi-audio-frequency channel hardware audio mixing, acquisition and the method for broadcasting may be selected based on IOS
CA2578190C (en) Device and method for generating a coded multi-channel signal and device and method for decoding a coded multi-channel signal
RU2014105187A (en) METHODS, DEVICES AND SYSTEMS FOR PARALLEL CODING AND DECODING OF VIDEO INFORMATION
EP2544451A3 (en) Method and system for digital decoding 3D stereoscopic video images
CN106254867A (en) Based on picture group, video file is carried out the method and system of transcoding
CN106131550A (en) Play the method and device of multimedia file
BR112018007547B1 (en) DEVICE AND METHOD FOR RENDERING A HIGHER ORDER AMBISONIC AUDIO SIGNAL
CN103929655A (en) Method and device for transcoding audio and video file
CN102819851B (en) Method for implementing sound pictures by using computer
CN104768025B (en) A kind of video bad frame restorative procedure and device
CN100461845C (en) Recording apparatus, recording method, reproducing apparatus, reproducing method, and program
CN110290290A (en) Implementation method, device, computer equipment and the storage medium of the studio cloud VR
CN102769715B (en) A kind of method and system of code stream editing
CN110505523A (en) A kind of video code conversion priority orders control method and processing terminal
CN109873961A (en) Court's trial data acquisition and processing system
CN104023245B (en) A kind of net cast stream based on B/S frameworks compiles acceptance system and implementation method soon
CN108550369A (en) A kind of panorama acoustical signal decoding method of variable-length
CN102768844B (en) A kind of method of audio code stream splicing
CN110493604A (en) A method of 8K HEVC real-time coding is realized based on GPU cluster
CN107277457A (en) A kind of multi-channel video capturing for being used to impart knowledge to students and processing equipment and method
CN109801639B (en) Coding and decoding method of panoramic sound signal conforming to AC-3 format
US9113150B2 (en) System and method for recording collaborative information
CN102802002A (en) Method for mobile phone to play back 3-dimensional television videos
CN114710629A (en) Device for realizing ultrahigh-definition video format conversion and image-text superposition

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20171229

Termination date: 20180331