Page 2 of 4: XviD Codec Options: Main

Main Settings:

XviD: Main Settings
XviD: Main Settings


Profile @ Level:
XviD profiles are actually MPEG-4 standards. Because MPEG-4 is designed to work across many different types of platforms, standards are required so that the XviD/MPEG-4 video you produce will work on these platforms (eg. something that works on your standalone player probably won't work on your mobile phone/cellular). Each profile will have different restrictions it places on the codec, and hence, which settings you are allowed to set.

XviD: Profiles
XviD: Profiles


The "Simple" profiles is best compared to VCDs, since it limits the resolution to 352x*** and the bit-rate to up to 384 Kbits/s. "Advanced Simple" allows more advanced features such as B-frames, Quarter Pixel and GMC. The "Portable", "Handheld" and "Home Theatre" profiles are all aimed at ensuring compatibility. For more information on compatibility with standalone XviD players, please refer to our Using VirtualDub - Re-encode AVI for standalone compatibility guide.

Each profile also has several different levels, with each level having a different resolution/bit-rate limit.

The best profile to choose for day to day DVD conversion is "Advanced Simple @ L5" - newer standalone players are compatible with this profile.

There is also an "unrestricted" profile option, which allows you to do anything you like, and is suitable for things like high definition recording.

Press the "More" button to configure the Profile level you selected...
XviD: Profile Settings
XviD: Profile Settings


Quantizer type: - H.263 is better for lower bit-rates, so choose this for making 1 CD movies. Choose MPEG for 2 CD movies, and MPEG-Custom to select a custom quantizer, which you should only do if you know what you're doing.

Adaptive Quantization: - Formerly known as "lumi-masking", this is similar to the psychovisual enhancement feature in DivX 5.x, and similar to how MP3 compresses audio by removing data the human ear can't pick up, here, data the human eye can't distinguish is removed.

Interlaced Encoding: - This option improves performance when encoding interlaced content as you won't need to convert it to progressive content. Only select this if your source is interlaced.

Quarter Pixel: - This is a more accurate motion estimation method, which can be useful for lower resolution videos. Note that not all standalones support Quarter Pixel (MediaTek based standalones do).

Global Motion Compensation: - This improves scenes where there is lots of motion, but at the time of writing, there is no support for this on standalones.

B-VOPs: - These are the B-Frame (Bidirectional frames, which improves quality) settings. For a brief overview of what I, B and P frames are, please refer to the "Frames Basics" section of this guide.

"Max consecutive BVOPs" defines the number of consecutive B-frames the encoder will be allowed to set. A setting of 0 turns off B-frames. A setting of 1 is standard (same as DivX 5.x), a setting of 2 will produce better results (but could cause compatibility issues), and a setting of 3 is used for maximum effect. It is not recommended to go above 3.

The "Quantizer ratio" setting determines how many more times the B-frames should be compressed compared to P-frames (the higher the value, the higher the quantizer setting and therefore the more compressed the frame is).

The "Quantizer offset" setting determines the quantizer value to be added to B-frames compared to surrounding P-frames (so a setting of "1.00" would add "1.00" to the quantizer value of the B-frame, again the higher the quantizer, the more compression used).

The "Packed bitstream" setting allows for bitstreams that can be decoded without delay. This option was added to solve problems with choppy playback.

In any case, the default settings seem to work fine, but if compatibility isn't an issue, you should try increasing Max B-frames to 2.

Going to the "Level" section shows the limitations of the current profile.

XviD: Profile Level
XviD: Profile Level


Now click on the "Aspect Ratio" tab.

XviD: Profile Aspect Ratio
XviD: Profile Aspect Ratio


This allows you to define a custom pixel aspect ratio. By default, square pixels are used, but you can also define 16:9 PAL/NTSC pixels, which is the way anamorphic content on DVD is recorded (ie. the picture appears tall). Note that your encoding software (eg. Gordian Knot) needs to support this (and most don't), the file container (AVI, MKV) need to support this (most don't) and finally, your playback filter also need to support this (only 3ivX supports this at the time of writing). The default setting (Square pixels) is recommended.

Press "OK" to exit the profile configuration window.
Encoding Type:
This is where you select what kind of encoding you want to use with the XviD codec.

XviD: Encoding Type
XviD: Encoding Type


The settings are:
  • Single Pass: encodes the movie at a constant bit-rate.
  • Twopass - 1st pass: step 1 for a two pass encoding. This step analyzes the source and records information needed for the subsequent pass.
  • Twopass - 2nd pass: the final step of a two pass encoding, where the information recorded in the previous pass is used to optimize encoding.
For this guide, we'll use 2-pass encoding, since it gives a more precise final file size, and will produce the best quality encoding (for that particular file size).

Twopass - 1st pass Additional Settings:
If you select Twopass - 1st pass and press the "More" button, this is the window you'll get:

XviD: Encoding Type - 1st Pass
XviD: Encoding Type - 1st Pass


Here, you can specify a filename of the stats file that will be generated in the first pass to record the necessary information. This filename must be the same as what you would specify for the second pass. The "Full quality first pass" option will generate a file that is encoded with all the normal encoding options (whereas a normal first pass will skip many things to improve encoding speed), so it's not that useful to select this option (it will slow down your encoding). The "Discard first pass" option should be selected as well to remove the video file encoded using the first pass (which is playable, but is not at the best quality/file size and probably not MPEG-4 compliant).
Twopass - 2nd pass Additional Settings:
If you select Twopass - 2nd pass and press the "More" button, this is the window you'll get:

XviD: Encoding Type - 2nd Pass
XviD: Encoding Type - 2nd Pass


Here, you have to specify the same stat file filename as you did for the first pass. The rest of the options should not be touched unless you know what you're doing, as they can affect both quality and the accuracy of the predicted file size.

Click "OK" to close this window. There should now be a new option available underneath the Encoding Type option called "Target size".

XviD: Target Size
XviD: Target Size


This is pretty straight forward - specify a value in KB (kilobytes) here and the codec will adjust it's internal settings automatically to try to generate the best looking video at this size. You can click on the "calc" button to open up XviD's built in bit-rate calculator.

 

 


  1   2   3   4   Next Page