I have some tv episodes in MPEG2 format that I want to convert to Xvid.
Their length is 42 mins + seconds (eg 42:14)
I've extracted the audio and converted to MP3, 128kbps, the size of which is 39,632 MB.
I want to put 2 of these episodes onto 1x700MB CD.
So, each of this files + audio should be about 350MB.
Thus the video needs to be about 300MB.
When I use these figures to calculate an average bitrate the calculator (in the Xvid encoder in VDmod) comes up with an average bitrate of 1016.
When I use this figure of 1016 with 2 pass encoding the filesize is 130,842 MB not 300MB (ish) as expected.
Can anyone explain this ? Thanks
![]()
+ Reply to Thread
Results 1 to 14 of 14
-
-
1016kbps should give you a video that's 312megs.
I never got 2-pass with divx or xvid to work, so gave up trying. 1016kbps should be ok even at 640x480. -
As you say, 1016 should produce a file of about the right size !
However it doesn't....
I've disabled GMC in the Xvid encoding since my DVD player (with Mediatek chip) doesn't support Xvid with GMC (apparently).
Could this be the problem for the unexpectedly small filesize ?
Are there any other settings I should check ?
Thanks -
BTW - my source is only 352x240 (4:3) and (oops) is only MPEG1 not MPEG2 as previously...
I'm thinking that the size (352x240) is the reason that my files are really small ? -
hmm. why convert at all? they're already valid framesize for DVD/VCD.
Have you tried just doing a CBR conversion? dont think 2pass will make much difference with that framesize/bitrate. -
Yes more than likely you are already saturating the bitrate with a file that small. Do the episodes already look ok? If so then use the file even though it is smaller than you want (hey, don't look a gift horse in the mouth). If it doesn't look acceptable, keep in mind you are starting with a 352x240 MPEG1 source, you can try a different quantization matrix (if you are currently using H263 try switching to the MPEG Custom HVS Best). You can also disable Bframes (B-VOPs) if you are using them, could result in a very small quality inprovement as well as a larger filesize.
-Suntan -
OK, the reason for re-encoding is that the MPEG1 files are 450MB each - only 1 episode per CD !
Re-encode to fit more episodes onto a CD
(I'm posting the CD's to a friend so size/weight is important)
The size of the converted file is very small and looks ok (at least as good as the MPEG1), so I'll use it (not wanting to look a gift horse in the mouth!)...
I was really wondering why the bitrate calculator was getting it wrong (or was it me getting it all wrong?)...
Do the bitrate calculators assume you're gonna be encoding to a 640x??? resolution ?
The MPEG1 file has the following properties (taken from AVIcodec):
video:247MB's, 1150 kbps, 29.97fps, 352x240 (4:3)
Is there anyway to calculate what would be the best bitrate given the info above ?
By best I mean, if you wanted an exact (or closest) copy in MPEG4 format...
I'll try the CBR conversion as well....
I can disable the B-VOP's - thanks for the tip.
where is this quantization matrix ? I was using H263 but the only options I have are MPEG or MPEG-custom (is this MPEG custom HVS best?)
Thanks for your (speedy) help so far.... -
The input bitrate really should only be thought of as a "Maximum" allowed. If the source does not require that much to encode then it will use less. The idea being that poeple don't mind if it uses less.
If you are consistently getting smaller files (and your minimum I,B and P quantizers are set at 2 where they should be, not at 1 which sounds counter intuative but trust me...) Either you understimate Xvids abilities, or you need to use a different quantization matrix. The rule of thumb is "think of H263 as a smoothing/softening matrix and MPEG as a sharpening matrix" further, Custom matrixes can be input by yourself (all the numbers in the two grids, but don't go changing things willy nilly or you will get some crazy results.) If you use Koepi's Xvid complies (I would sugegst upgrading to 1.01 if you haven't) there is a zip file with some custom Matrixes. Unzip them to a folder somewhere, then in the custom matrix dialog box within the codec setup there should be a "load" or "import" button. Use that, then browse to the folder you unzipped, there wil be a bunch of different ones with some somewhat weird sounding names, I suggest using HVS Best but feel free to experiment.
All that said, you should try the MPEG matrix as well as it is pretty good on its own, don't just jump to the conclusion that custom=better without trying them out.
Sorry, but there is no easy way to calculate the "best" bitrate. Just trial and error.
I wouldn't waist time with a CBR encode. If you want to try a 1 pass encode (just make sure your minimum I,B and P quantizers are set to 2 each, the maximum can be left at 31) the matrix that you have selected will affect 1 pass encodes as well.
-Suntan -
going from mpeg 1/2 to mpeg4 you can pretty much aim for half the bitrate to have the same final quality - IN MY OPINION! someone is bound to disagree
filesize should be independant of frame size if you're controlling the bitrate. it could simply be a case that it -can't- allocate any more bits, you're already getting the best quality you can from your mpeg1 source. or perhaps it's a bug, as you know Xvid is still under development - it's not as mature as MPEG1/2 or even Divx. -
@flaninacupboard
Yes Xvid is still being heavily developed, but I would have to say that as of 1.01 (I would suggest using Koepi's build as well) that it is very stable and quite bug free.
-Suntan -
Over the weekend I've been at it again....
I was using Xvid 1.0.1 and not getting any results I expected.
If I used 600kpbs as my av. bitrate the result would be about 450 kbps, 800 = 600 kbps, 2000 = 750 kbps.
All very hit-and-miss.
So I decided to try DivX (5.1.1) instead.
From my first attempt, the expected filesize was exactly as you'd expect using your chosen bitrate - Unlike when using Xvid, the DivX file was the size that was predicted by the bitrate calculators.
So, I've encoded everything in DivX and all is well now....
I'm not giving up on Xvid (it works fine usually) but in this case DivX worked and Xvid didn't (not acceptably in my opinion).
If in doubt, give DivX a try...Xvid is good but not 100% ! -
yes....
The DivX files looked like a better copy of the MPEG1 source than any of the Xvid conversions.
As above, the Xvid codec gave "random" results which did not bear much resemblence to the bitrate that I specified.
DivX was consistent. -
I find XviD to be MUCH more reliable thatn DivX, not to mention the fact i dont have to pay for it. Not to mention that there is a 10 kBit/s difference per 350 MB. So, my quality is higher...by a virtually nonexistant amount, but higher regardless.
Similar Threads
-
Should i put average bitrate or max bitrate in 2pass encoding mode?
By tendra in forum Video ConversionReplies: 28Last Post: 11th Nov 2011, 07:38 -
TMPGEnc Xpress bitrate calculations are off
By Taeran in forum Video ConversionReplies: 3Last Post: 24th Sep 2008, 17:17 -
MPEG2 to Xvid with Virtualdubmod
By Cazz in forum EditingReplies: 25Last Post: 26th Feb 2008, 13:49 -
Vegas, Xvid Encoding, Max Bitrate 56kbit only
By kidcash in forum AudioReplies: 3Last Post: 26th Dec 2007, 00:08 -
Problem with bitrate and file size when encoding with XviD
By megakoolkid in forum Video ConversionReplies: 13Last Post: 25th Jun 2007, 17:12