ErMaC's Guide to All Things Video - Part 5
DVDs: What They Are and How To Use Them
Continued from the first page.
How is working with VOB files in Premiere possible? Well, it's a very complicated process which has taken me MONTHS to get working correctly (I first tried doing it back in Summer of 2000, but the software wasn't then available to make it possible). I needed to get it to do this because in order to convert to my DV500's DV format, I have to be able to open the file in Premiere since the only way to create the AVI files correctly is using the Premiere Export plugin that comes with my DV500 software (which doesn't work attached to FlasKMPEG, BTW).
Note: The following will be very heavy on technical details, so follow very closely.
I. Installing Necessary Software
Go to Doom9's great site and download the following software:
II. Ripping the VOB files
This step is pretty easy. Just follow the instructions for your ripping program.
Both ripping programs will allow you to do somethign called "Stream Processing" which essentially will rip out all the parts of the VOB you don't need. When I rip footage, I rip out only the video stream and leave the audio, subtitles, and anything else out of the files I rip to save space. I recommend you do the same. These programs should have help files, and if you still can't figure them out check out Doom9's site for guides on how to rip DVDs.
III. Creating the DVD2AVI project file
Now that you've ripped the VOB files, open up DVD2AVI version 1.76 and select Open from the File menu. Select the first VOB file in whatever series you'll be converting/editing with (i.e. the VOB that ends with 1). It should the automatically add all the rest of the VOBs in the series.
After you select all the video files, click OK. Then open the Audio menu and under the Track submenu, select "None".
Set the Field Options in the Video menu to "Swap Fields". I find this fixes problems with some capture cards (namely the DV500) outputting swapped fields later.
Once you've got all these settings right, select "Save Project" from the File Menu, or just hit f4. Save your project somewhere and then let it go for a while.
IV. Opening VOB files with Frame-Accuracy in Premiere
First create a file with any name, as long as it ends in the extension AVS. This is an AVISynth Scripting file with which we will read the DVD2AVI project file. For those who don't understand this part, what I do is in explorer I say "Next Text Document". This should create a file called "New Text Document.txt". If you do not see the TXT at the end, then you need to go to Tools->Folder Options in Explorer and turn off "Hide File Extensions for Known Types" under the View tab. Then rename this blank file to blahblah.avs, then open it in notepad.
Put the following 2 lines in it:
LoadPlugin("ABOSLUTE PATH TO MPEG2DEC.DLL\MPEG2DEC.DLL")
Note that you of course must replace the all caps sentences with the
proper strings. For instance, an example file for me would be:
Do NOT have any spaces in the directory paths! For some reason AVISynth with barf and fail to work if there are spaces in the path or filenames!
If you want to edit in Progressive frames, you can use the Decomb Plugin for AVISynth. This is a fantastic plugin for AVISynth that will do what TMPGEnc takes a huge amount of time to do on the fly! However it will significantly slow down your editing, but you will get progressive frames. To utilize Decomb, add the following lines to the AVS file:
LoadPlugin("ABSOLUTE PATH TO DECOMB.DLL")
Then in Premiere, open up the AVS file (you did install the AVISynth plugins, right?) and do whatever you want with it. Feel free to create as many AVS files as you want - since we're using a Plugin built directly into AVISynth so it won't get confused.
Please note that for this method to work you need to be working in Premiere at 720x480 or you'll end up with a black video stream (this is a limitation of the AVISynth Premiere Import Plugin). If you want to resize the video, you must do so in the AVS file by adding a line at the very end like this:
If you wanted to resize the video to half the pixels in the horizontal direction. Note you'd have to do deinterlacing if you wanted to resize to any other resolution, and I highly recommend against that so don't do it. =) If you feel that you must you can figure it out yourself by reading the AVISynth documentation.
One thing to be careful about, editing this way take a lot of RAM! Make sure that you have a very very large swap file if you plan on doing this a lot. I'm currently editing a project that has 26 AVS files (one for each episode of the series) and just opening them all causes Premiere to take up 500MB of Virtual Memory (note this is not Physical memory...)! I had to increase my swap space by another Gigabyte, and even then, I periodically save and close Premiere, then reopen it and continue working (as this flushes the cache which is created for the decoding of every single frame that you seek to in the AVS file)!
A word of warning to Premiere 6.0 users!
If you are getting a black screen when you open AVISynth files even when you've maximized the window, it's probably because Premiere 6 thinks you want to work with it in its proper aspect ratio. Since the resolution's 720x480 it automatically applies a 0.900 ratio modifier, making it square again. However, since we cannot resize AVISynth video, this is bad. In the forums, rhoda_b came up with the following solution:
Frequently Asked Questions
Q: When I try to open the AVISynth file in Premiere, it tells me it can't find a driver for the codec. What's wrong?
A: If you can successfully open the AVISynth file in Windows Media Player or VirtualDub, then you need to install HuffYUV. If none of them will open it, then you have installed AVISynth incorrectly. If you install HuffYUV and it still doesn't work, reinstall Premiere.
Q: When I try to open the file the video stream is this text saying "I don't know what LoadPlugin means" or something.
A: You've installed the wrong version of AVISynth. Go download the latest from VideoTools.
Q: I get a black screen when I'm in Premiere.
A: Make sure the Clip is set to Square Pixel Aspect Ratio if you're in Premiere 6. Also make sure the Project settings themselves are set to Square Pixels. Then make sure the Project's settings are 720x480 resolution. Finally, make sure your Monitor/clip window is enlarged completely to 720x480.
Q: I'm getting some weird discoloration on certain scenes. What's wrong?
A: See this forum thread.
Q: When I try to make the AVI in DVD2AVI it takes forever or doesn't work!
A: That's because you're not supposed to make the AVI file in DVD2AVI, you make a Project File.
Q: I'm getting these weird horizontal lines in my video. What's wrong?
A: That's called interlacing. Read my earlier guides for an explanation of what it is and how do deal with it.
Q: AVISynth says there's an unrecognized exception on Line something or other. What's wrong?
A: You either have the path to your D2V file wrong, there are spaces in the path to the D2V file, or your D2V file is corrupt.
Q: When I try working with the video in Premiere it's all choppy and slow.
A: That's normal. You should preview all of your clips in a different codec like DV or MJPEG. You will not be able to play back AVISynth files in real time.