You are invited to Log in or Register a free Frihost Account!

Linux XviD DVD Encoding Guide

This is one of many things people do not know how to do with Linux, and most revert to Windows or use virtualization software with reduced performance. There is alot of software to choose from, but finding the easiest/quickest is the aim here.

Please do NOT be frightened to use the tovid command-line over the GUI.

To begin, you'll need this tovid-0.30.tar.gz tarball, it contains everything you need to run tovid.
You may also want to install avimerge so you can merge 2CD XviD's into one file.

Assuming the saved item is located on the desktop you can install with the following commands:

cd Desktop/
tar -xzvf tovid-0.30.tar.gz
cd tovid-0.30
su -c "make install" (Ubuntu users use: sudo make install)

Now that we have tovid installed everything onwards is quite simple and user-specific.
The following explains the most popular tovid parameters, you can view all parameters by typing "man tovid" in the terminal.

Program functions:
-ffmpeg - Use ffmpeg for encoding, instead of mplayer/mpeg2enc. Quicker encoding than mpeg2enc.

TV Standards:
-ntsc - NTSC format video (USA, America) (default if not specified)

-ntscfilm - NTSC-film format video

-pal - PAL format video (Europe and others)

Output Formats:
-dvd (720x480 NTSC, 720x576 PAL) DVD-compatible output (default if not specified)

-svcd (480x480 NTSC, 480x576 PAL) Super VideoCD-compatible output

-vcd (352x240 NTSC, 352x288 PAL) VideoCD-compatible output

Aspect Ratio:
tovid automatically determines aspect ratio of the input video by playing it in mplayer.
You can force AR with this parameters:

-full - Same as -aspect 4:3

-wide - Same as -aspect 16:9

-panavision - Same as -aspect 235:100

-aspect WIDTH:HEIGHT - Custom aspect ratio.

Affects both output bitrate and quantization. Default is 8 (Personally I use 10)

-quality # - Output quality on a scale of 1 to 10, with 10 giving the best quality at the expense of a larger output file.

-vbitrate <amount> - Maximum bitrate to use for video in kbits/sec. Ignored for VCD. (Must be constant)

-abitrate <amount> - Encode audio at <amount> kbits/sec. Ignored for VCD. (must be 224)

-autosubs - Automatically include subtitle files with the same name as the input video.

-subtitles <file> - Hard-codes the subtitles into the video. (Subs cannot be disabled)

This is an example of basic DVD creation:

tovid -pal -ffmpeg -autosubs -vbitrate 6000 -abitrate 448 -quality 10 -dvd -in file1.avi -out dvd1.mpg

This will encode the file1.avi in the working directory (Desktop) and convert it to dvd-compliant video.

makexml ~/Desktop/dvd1.mpg -out "DVD1"

This creates an xml file to author the disc.

makedvd "DVD1"

This reads data from the XML file and creates the VIDEO_TS and AUDIO_TS folders, with IFO's BUP's, VOB's etc located in the VIDEO_TS folder. You can then burn this to disc!

For batch conversions:

tovid-batch -pal -ffmpeg -autosubs -vbitrate 6000 -abitrate 448 -quality 10 -dvd -infiles *.avi -out *.mpg

This will take any avi files in the working directory and convert them to mpeg video files.
You can then repeat the makexml & makedvd steps above for each video file.

Goodluck! Smile
Related topics
Nanotech to increase DVD capacity to 850 GB
All-In-One convert, author and burn AVI/DivX/Xvid/DV to DVD
Ordinary DVD-Drive in XBOX?
[Guide] DVD Recordable Format
Which is the best Xvid/Divx to DVD Converter ?
Windows does not recognize blank dvd
Linux AVI & DVD plugins
DVD player and decoder for SuSE Linux
What soft to replace a complete Windows by a complete Linux?
Linux system recommendations please
DivX or XviD DVD player
Windows setup not detecting full drive size
Linux distro comparison (Fedora vs. Mandriva vs. OpenSuse)
Linux distro comparison (Fedora vs. Mandriva vs. OpenSuse)
Reply to topic    Frihost Forum Index -> Computers -> Computer Problems and Support

© 2005-2011 Frihost, forums powered by phpBB.