There are several ways to edit mpg2 video; this is a brief overview of 4 methods that I hope will be useful for those just getting started. I try to focus on Easy Media Creator 9, but I also mention software that can be used right along side EMC9 – this software and information on the various applications can be found online at places like Videohelp.com.
1) The most accurate, what some consider the only proper method of editing mpg2 video, is to consider it the same as any other video file, performing destructive edits, re-encoding [re-compressing] the complete video when done. It’s certainly the most costly method, requiring additional time to re-encode the video, and losing some quality [every time video’s converted &/or encoded (compressed), you loose some data and with it, some quality].
It works best when you have some quality to spare, so acquiring (recording) your original source video at the highest bit rate possible pays off – i.e. 12 - 20 instead of common DVD rates of 5 - 9. This gives your encoder more to work with, and with the encoder inside video editing software often optimized for quality instead of speed (for capture), the results are very often worth it.
Cons: By re-encoding you’ll lose any embedded Closed Caption data. Not all capture devices allow high bit rate, mpg2 recording. Encoding takes time, and stresses your PC, sometimes revealing problems that you didn’t know you had.
Note: DGIndex used with VFAPI or Avisynth are popular. DGIndex optionally extracts video and/or audio tracks, while creating a project file that indexes the content of a mpg2 video file. This project file can be used with VFAPI or Avisynth to provide a proxy .avi file for editing, to be used in place of the original mpg2 video. By using this proxy, editing software will often be more responsive, particularly with problem or very large mpg2 files. During render data from the original mpg2 file is provided to the encoder. Videowave works with DGIndex and VFAPI.
2) Mpg2 video can have the start &/or end times trimmed while copying the file. Segments of video can also be extracted this way – video between commercials for example. Trimming a mpg2 file outside of MyDVD lets MyDVD use the video as is, without any re-encoding as it writes a video DVD. EMC9‘s Copy program (Video Compilation tab) can do this trimming for you. It also has the benefit of working directly with DVD files (from a DVDR for example), extracting an audio/video file ready for Videowave or MyDVD.
DVD Shrink (freeware) will copy & trim your video, and can optionally reduce the file size of a DVD pretty quickly without re-encoding [it's a well-known, almost a standard]. It can be used to reduce the size of video files recorded by a DVDR (for example to squeeze more episodes of a recorded TV show on a DVD), or as an alternative to re-encoding if the DVD you want to create in MyDVD won’t fit on a blank disc.
DVD Shrink Cons: You’re still left with a complete DVD on your hard drive, and depending on how far you “Shrink” the video, however you do it, some quality loss can be apparent.
3) Mpg2 video files can be split or joined at “I” frames; joining normally requires that the video files are encoded with the same settings. [i frames contain the entire video frame, while the B & P frames in between only record the changes from one I frame to the next.] Software might try to generate needed I frames whenever you cut video between existing I frames. Both Videowave and MyDVD do a great job with this kind of editing, allowing you to cut segments (commercials for example), and automatically joining the new, separate files on either side of the gap.
Benefits are mainly efficiency and maintaining quality, both because re-encoding is not necessary. Depending on the software used and the video source, embedded Closed Caption data can also be preserved – Videowave and MyDVD preserve CC from my Panasonic DVDR.
Cons: Particularly when the audio track is in a compressed format, it’s extremely difficult to exactly match cuts in both video and audio – video and audio use different timing and data is stored in different sized chunks. Use Videowave or MyDVD to avoid problems.
Videowave and MyDVD handle the audio end of cut editing &/or joining mpg2 video very accurately [match up before and after audio in multi-track audio software, then invert the phase of 1 of the tracks and play... they’ll cancel each other almost perfectly]. However there is a side effect: AC3 audio will be re-encoded. You’ll probably benefit from recording the original in .wav format if your capture device supports it, so that audio is only encoded once [caution: audio not recorded from your capture device will often not sync.]
As described in the original, pinned post, cutting segments in Videowave or MyDVD is done by setting markers on the timeline, clicking between them to select the segment, then clicking the cut button (between the + & - at the upper left of the timeline display – about a quarter of the way up from the bottom of the entire window). To join segments just place them on consecutive panels in story view.
Watch the size display in the status bar – a sudden increase can mean you’ve done something to cause re-encoding. It helps to set the audio bit rate to match your original if it’s AC3. In Videowave it works (using my Panasonic DVDR recorded SP source) to output an interlaced mpg2 file, creating a custom profile with mpg2 bit rate of 9, and matching AC3 bit rate of 384.
Not sure what your mpg2/AC3 source bit rate is? While your source is playing, turn on the OSD display: Power DVD & several other players will display current bit rate info. This is also handy for checking the variable bit rate on a scene by scene basis... Videowave and MyDVD can pass mpg2 video through without re-encoding, but once the encoding routine is activated – in this case to (re)encode AC3 audio – it will re-encode those video segments where the original has a VERY low mpg2 bit rate. If your source mpg2 bit rate is too low for too long it might not be worth it, and perhaps you should pursue other methods of editing. If/when you see your video (instead of the gray emblem) in the encoding message box, your video’s being (re)encoded.
4) Perhaps the sneakiest way to edit out something like commercials is found in some DVD authoring software, is used when editing with DVDRs, and can be mimicked by using a program called PgcEdit... All the content’s still there physically, but you instruct the player to simply skip over parts. To understand how it works you first need to know a little bit about cells in DVDs.
Simplified, everything a DVD displays on-screen is video, even still photographs. IFO files contain instructions for DVD players, and point to the media stored in VOB files. Cells can be thought of as the individual labels that IFO files point to. Consecutively numbered cells label the entire content of a video DVD, include the on-disc location – the boundaries where each cell starts and stops, the video’s duration within those boundaries, and the cell’s end time. A cell can be as brief as a single frame, or include every frame in a 3+ hour movie. Logically the more cells you have labeling a video, the more exact locations you can have mapped out, but it also becomes harder to manage and do things like editing.
When you set a chapter in DVD authoring software, it creates a cell at that point in the video file; this new cell lasts until the start of the next cell. That doesn’t mean that every cell has to have a chapter associated with it – that’s just the common way to create them manually.
Because of the way cells label a DVD, a *Title* isn’t necessarily one video file, but rather a sequential list of the cells to be played. Open a DVD [in a folder on your hard drive] in PgcEdit, select a title on the left, and click Edit PGC to open a window that lists all of the cells that title plays. In that window you can delete chapters, change the cell that a chapter is associated with, remove cells from the list to be played and so on; to skip a commercial you just remove those cells containing the commercial.
Cons: Because the skipped video is still there, your video can take up more room on a DVD than if you actually edited out things like commercials. MyDVD creates an unusually high number of cells – 1 per minute – so editing can be a bit more work. Chapters and cells work with mpg2 I frames – setting a chapter creates a cell starting at the closest I frame. While MyDVD’s chapter editor jumps to I frames to limit guesswork, it’s still possible that you’ll occasionally need to slightly re-position a chapter (cell) or two.
Question
mikiem
There are several ways to edit mpg2 video; this is a brief overview of 4 methods that I hope will be useful for those just getting started. I try to focus on Easy Media Creator 9, but I also mention software that can be used right along side EMC9 – this software and information on the various applications can be found online at places like Videohelp.com.
-------------------------------------------------------------
1) The most accurate, what some consider the only proper method of editing mpg2 video, is to consider it the same as any other video file, performing destructive edits, re-encoding [re-compressing] the complete video when done. It’s certainly the most costly method, requiring additional time to re-encode the video, and losing some quality [every time video’s converted &/or encoded (compressed), you loose some data and with it, some quality].
It works best when you have some quality to spare, so acquiring (recording) your original source video at the highest bit rate possible pays off – i.e. 12 - 20 instead of common DVD rates of 5 - 9. This gives your encoder more to work with, and with the encoder inside video editing software often optimized for quality instead of speed (for capture), the results are very often worth it.
Cons: By re-encoding you’ll lose any embedded Closed Caption data. Not all capture devices allow high bit rate, mpg2 recording. Encoding takes time, and stresses your PC, sometimes revealing problems that you didn’t know you had.
Note: DGIndex used with VFAPI or Avisynth are popular. DGIndex optionally extracts video and/or audio tracks, while creating a project file that indexes the content of a mpg2 video file. This project file can be used with VFAPI or Avisynth to provide a proxy .avi file for editing, to be used in place of the original mpg2 video. By using this proxy, editing software will often be more responsive, particularly with problem or very large mpg2 files. During render data from the original mpg2 file is provided to the encoder. Videowave works with DGIndex and VFAPI.
---------------------------------------------------------------------
2) Mpg2 video can have the start &/or end times trimmed while copying the file. Segments of video can also be extracted this way – video between commercials for example. Trimming a mpg2 file outside of MyDVD lets MyDVD use the video as is, without any re-encoding as it writes a video DVD. EMC9‘s Copy program (Video Compilation tab) can do this trimming for you. It also has the benefit of working directly with DVD files (from a DVDR for example), extracting an audio/video file ready for Videowave or MyDVD.
DVD Shrink (freeware) will copy & trim your video, and can optionally reduce the file size of a DVD pretty quickly without re-encoding [it's a well-known, almost a standard]. It can be used to reduce the size of video files recorded by a DVDR (for example to squeeze more episodes of a recorded TV show on a DVD), or as an alternative to re-encoding if the DVD you want to create in MyDVD won’t fit on a blank disc.
DVD Shrink Cons: You’re still left with a complete DVD on your hard drive, and depending on how far you “Shrink” the video, however you do it, some quality loss can be apparent.
-------------------------------------------------------------------------
3) Mpg2 video files can be split or joined at “I” frames; joining normally requires that the video files are encoded with the same settings. [i frames contain the entire video frame, while the B & P frames in between only record the changes from one I frame to the next.] Software might try to generate needed I frames whenever you cut video between existing I frames. Both Videowave and MyDVD do a great job with this kind of editing, allowing you to cut segments (commercials for example), and automatically joining the new, separate files on either side of the gap.
Benefits are mainly efficiency and maintaining quality, both because re-encoding is not necessary. Depending on the software used and the video source, embedded Closed Caption data can also be preserved – Videowave and MyDVD preserve CC from my Panasonic DVDR.
Cons: Particularly when the audio track is in a compressed format, it’s extremely difficult to exactly match cuts in both video and audio – video and audio use different timing and data is stored in different sized chunks. Use Videowave or MyDVD to avoid problems.
Videowave and MyDVD handle the audio end of cut editing &/or joining mpg2 video very accurately [match up before and after audio in multi-track audio software, then invert the phase of 1 of the tracks and play... they’ll cancel each other almost perfectly]. However there is a side effect: AC3 audio will be re-encoded. You’ll probably benefit from recording the original in .wav format if your capture device supports it, so that audio is only encoded once [caution: audio not recorded from your capture device will often not sync.]
As described in the original, pinned post, cutting segments in Videowave or MyDVD is done by setting markers on the timeline, clicking between them to select the segment, then clicking the cut button (between the + & - at the upper left of the timeline display – about a quarter of the way up from the bottom of the entire window). To join segments just place them on consecutive panels in story view.
Watch the size display in the status bar – a sudden increase can mean you’ve done something to cause re-encoding. It helps to set the audio bit rate to match your original if it’s AC3. In Videowave it works (using my Panasonic DVDR recorded SP source) to output an interlaced mpg2 file, creating a custom profile with mpg2 bit rate of 9, and matching AC3 bit rate of 384.
Not sure what your mpg2/AC3 source bit rate is? While your source is playing, turn on the OSD display: Power DVD & several other players will display current bit rate info. This is also handy for checking the variable bit rate on a scene by scene basis... Videowave and MyDVD can pass mpg2 video through without re-encoding, but once the encoding routine is activated – in this case to (re)encode AC3 audio – it will re-encode those video segments where the original has a VERY low mpg2 bit rate. If your source mpg2 bit rate is too low for too long it might not be worth it, and perhaps you should pursue other methods of editing. If/when you see your video (instead of the gray emblem) in the encoding message box, your video’s being (re)encoded.
---------------------------------------------------
4) Perhaps the sneakiest way to edit out something like commercials is found in some DVD authoring software, is used when editing with DVDRs, and can be mimicked by using a program called PgcEdit... All the content’s still there physically, but you instruct the player to simply skip over parts. To understand how it works you first need to know a little bit about cells in DVDs.
Simplified, everything a DVD displays on-screen is video, even still photographs. IFO files contain instructions for DVD players, and point to the media stored in VOB files. Cells can be thought of as the individual labels that IFO files point to. Consecutively numbered cells label the entire content of a video DVD, include the on-disc location – the boundaries where each cell starts and stops, the video’s duration within those boundaries, and the cell’s end time. A cell can be as brief as a single frame, or include every frame in a 3+ hour movie. Logically the more cells you have labeling a video, the more exact locations you can have mapped out, but it also becomes harder to manage and do things like editing.
When you set a chapter in DVD authoring software, it creates a cell at that point in the video file; this new cell lasts until the start of the next cell. That doesn’t mean that every cell has to have a chapter associated with it – that’s just the common way to create them manually.
Because of the way cells label a DVD, a *Title* isn’t necessarily one video file, but rather a sequential list of the cells to be played. Open a DVD [in a folder on your hard drive] in PgcEdit, select a title on the left, and click Edit PGC to open a window that lists all of the cells that title plays. In that window you can delete chapters, change the cell that a chapter is associated with, remove cells from the list to be played and so on; to skip a commercial you just remove those cells containing the commercial.
Cons: Because the skipped video is still there, your video can take up more room on a DVD than if you actually edited out things like commercials. MyDVD creates an unusually high number of cells – 1 per minute – so editing can be a bit more work. Chapters and cells work with mpg2 I frames – setting a chapter creates a cell starting at the closest I frame. While MyDVD’s chapter editor jumps to I frames to limit guesswork, it’s still possible that you’ll occasionally need to slightly re-position a chapter (cell) or two.
Link to comment
Share on other sites
6 answers to this question
Recommended Posts
Archived
This topic is now archived and is closed to further replies.