PDA

View Full Version : HDTV ---> XviD = file sizes are way off


Thasp
8th May 2006, 21:58
My filesizes are never right when I attempt to convert an HDTV transport stream to XviD. I plug my avisynth script straight into virtualdub, and set up xvid 1.1 according to the guide here. I unchecked trellis quantization and packed bitstream, but rechecking them did nothing for my rip. I've tried H.263 and MPEG quantization, I've tried turbo and no turbo, I've tried the yv12 and xvid versions of xvid, I've tried xvid 1.0.3 and 1.1, in several versions of virtualdubmod, but I can never get it within 10% of the video size I want it to be. I tried doing it by filesize and average bitrate. I tried with and without audio to see if that was screwing it up, but that made no difference either.

This is for a 16:9, 720p, 60 FPS(for simplicity's sake since I forgot the exact number) feed. I'm trying to make it standalone compatible with my Cowon A2, thus the neutering of the framerate and resolution.

LoadPlugin("C:\Program Files\GordianKnot\DGMPGDec\DGdecode.dll")
Loadplugin("C:\Program Files\GordianKnot\AviSynthPlugins\decomb.dll")
mpeg2source("pathtod2vhere")

Telecide(order=0)
Decimate(cycle=2)
bilinearresize(704,396)

Do any glaring errors stick out?

I've tried twopass and onepass also.

Any advice would be highly appreciated.

dohcmark8
9th May 2006, 02:15
XviD uses KB not MB... so if for example you want your vid to be 70MB you will need to put in '71680' for the file size. Use this http://www.egret.net/kb__mb.htm for an easy conversion.

Thasp
9th May 2006, 04:21
I understand that completely, but when I put in 700000 KB and I get a movie that is 834 MB, there is a problem.

Encoding a normal DVD using the gknot/vdub guide here gives me no issues, only when I am doing HDTV encodes and making my own avisynth scripts do I have trouble.

squid_80
9th May 2006, 13:22
Step 1: Forget one pass, two pass is the only way to accurately hit a target size.
Step 2: Hit "load defaults" before setting up the first pass settings. Change all minimum quantizers to 2. Make sure the stats file is set to something useful.
Step 3: Run the first pass.
Step 4: Go to the encoder configuration again, change encoding type to 2nd pass, make sure the same stats file is selected, and enter the target size. Don't change any other settings.
Step 5: Run the second pass.

If it still doesn't work, open the d2v file with gordian knot and do it that way. It will handle the xvid settings for you, and you can make your changes to the avisynth script by hitting edit after selecting save and encode from the preview window.

Thasp
10th May 2006, 03:15
gordianknot had the same issue.

I fixed it by changing some stuff in the second pass "more" settings tab from 5% to 10%.. overflow control or something like that. Instead of being 700 MB, the file wound up being 701 MB. Much better than it being 835 MB instead of 700 MB. That's accurate enough for me.

morph166955
14th May 2006, 17:31
just as a thought, try using x264 (see the MPEG-4 AVC section of this forum). Thus far i have found that its prediction is ALOT more dead on as well as i can get much smaller files out of it then with xvid just because of the nature of it (350mb xvid vs 250mb x264) AND in my book its a higher quality image. If you want to only do a one pass look at CRF, otherwise the twopass works great also. I suggest looking into mencoder or the x264cli or any of the gui's for this like MeGui as they all work really well.