View Full Version : Cropping .mpgs with Vdubmod

3rd April 2003, 23:46
I've been a lurker for a while now but came across something I haven't seen an answer to yet. I've been recording movies off tv usually setting a timer to start and stop when I'm not there using a Radeon 9700 All-in-wonder. I record in 720x480 in MPEG-2. I want to be able to crop the mpg file so I get just the movie portion. So far the only solution I've come up with works if I happen to start the movie when I'm there. And by that I mean I start it and set a timer for it to stop in 2 hours or so. I've been using Gknot to set the credits start area at the end of the movie instead of where the credits are, then just tell it to encode the movie only under the trim section.

This works great if I only need to crop one side but I have the portion at the beginning I need to get rid of. So far I've just been guessing at the file size and making it 745MB or something and hope that it will come down to 700MB when it's cropped. The file size is what's important because they need to fit on cds. I can't really get the optimal bitrate this way though.

I guess my question is how do I crop mpg files with Vdubmod using avisynth? When I delete the portions and go to save it again, it says the file size will be huge because it can't compress it in direct stream copy mode with avisynth. I tried direct stream because that was the method of splitting AVIs (select start and stop portion and hit F7 and save each section). I just don't see why it can't do this with mpgs. I can't save it uncompressed because I just don't have that kind of space on my hard drive.

Thanks for any help you can provide.

4th April 2003, 08:32
I don't understand everything in your post. Something important I don't think you mention is: What is your final format? DivX? SVCD? If SVCD then VirtualDub is not the correct tool...

4th April 2003, 10:49
DivX 5.02

Cropping the completed DivX is useless to me because I need Gordian Knot to size my file to 700MB to fit on the CD. If I crop beforehand then I can do this. If I do it after, then I can only guess what the final size would be.

What I'm trying to do is crop the movie portion only and get rid of the excess commericals and stuff at the beginning and end which I got because I used a timer to start recording and it recorded more than just the movie.

6th April 2003, 09:08

I used to have the same problem, here's what I do:

First extract the audio to a .wav file using MpegMediator.
Convert the .wav to the format you want.( probably mp3 cbr )
Load the video in vdub(mod) through avisynth. (create a project file with DVD2Avi)
In the (audio)menu you can add the .mp3 file.
Now cut out any parts you don't want in the file.
extract the .mp3 with "demux audio" just to know the file size
Select in the menu "compression" and select your codec.
I don't know how it is done in divx 5.02 (I use Xvid)
but now you can select 2 pass encoding and set a final (video) size.
(final size - audio size = video size)
Use "full processing mode" to add any filters you like
Save as .avi

Best regards


7th April 2003, 02:35
Thanks a bunch, I'll give that a try. Lately I've just been overburning CDs that come out over 700 megs and that's been working so far but this may be better.