home contents changes options help

by Christian Einfeldt April 30, 2006

How to use tovid under SuSE? 10. to make DVD-compatible video

Unfortunately, K3B is not able to ship ready to burn DVD, perhaps due to the legal noodle soup that is the law in the United States currently. You will need to do some work to enable DVD burning with K3B, but the good news is that once you do so, you will be able to be able to do quite a bit of video roasting. Of course, check the law in your jurisdiction to make sure that the work you are doing complies with your country's IP laws.

All of this documentation assumes that you have already installed tovid as described on the parent page.

Again, most of my work here is drawn from following Kyle Rankin's tips in "Linux Multimedia Hacks." It's a good book, and I recommend that you pick up a copy. These tips are only to document my work applying Kyle's tips to SuSE? Linux 10.0 on my ancient dual core processor AMD box, which was formerly a server for a law firm.

You are going to need to figure out whether to use PAL or NTSC format. Since I live in the US, and am going to be sharing these videos with the Internet Archive located right here in the San Francisco Presidio, I am going to use NTSC. Kyle recommends that you use idvid to show whether to use full-screen, wide-screen or theatrical wide-screen aspect ratios with tovid. It was my experience that tovid automagically determined this form me accurately, and so all I am going to say here is that the command looks like this:

linux:/video-store # idvid Larry_Augustin001.dv

In this case, the video that I chose happened by random luck of the draw to be an interview with Larry Augustin, so that's why his name appears here. Once you are comfy with your aspect ratios, the command to run tovid is as simple as specifying the input and output files. In this case, I just changed the name of the .dv a new name that was different enough for me to recognize and follow through the process. So I started with a file named Larry_Augustin001.dv and I selected as the output name output_Larry. The command looks like this:

linux:/video-store # tovid -in Larry_Augustin001.dv -out output_Larry

tovid produced a very long and informative output that was dirt simple to follow. It looks something like this:

Using config file /root/.tovid/tovid.config, containing the following options:
(none)
Changing to working directory: /video-store
--------------------------------
tovid
DVD and (S)VCD video conversion script
Version 0.26
with: core magick dvd vcd transcode
http://www.tovid.org
--------------------------------

=========================================================

Converting /video-store/Larry_Augustin001.dv to compliant NTSC DVD format
Storing log and temporary files in /video-store/tovid-temp.mr6528
Multiple CPUs? detected; mpeg2enc will use multithreading.

=========================================================

Probing video for information. This may take several minutes...
The encoding process is estimated to require 37 MB of disk space.
You currently have 156669 MB available in this directory.
Analysis of file /video-store/Larry_Augustin001.dv:
720 x 480 pixels, 29.970 fps
Duration (best guess): 00:00:53 (HH:MM:SS)
DVSD video with libdv audio
Target format:
720 x 480 pixels, 29.970 fps
m2v video with ac3 audio
7840 kbits/sec video, 224 kbits/sec audio
Using auto-detected aspect ratio of 150:100 (override with -aspect)
Letterboxing vertically
Input is already 29.970 fps. Framerate will not be altered.
Scaling picture to 720 x 416
Centering picture against a 720 x 480 black background



tovid will then create a WAV file of the audio, and will then encode the WAV file to ac3 format and will encode (by default) the video to a .mpg file, which so far has been fine for my needs. But bear in mind that if you are going to want something other than .mpg, you are going to have to do some digging, or buy Kyle's book for more tips. I just haven't even attempted anything other than the default performance yet. I ended up with a 2 MB audio file called output_Larry.ac3, and a 30 MB video filed called output_Larry.m2v, all mixed together in a .mpg file called output_Larry.mpg, as follows:

=========================================================

Multiplexing audio and video together with the following command:
mplex -V -f 8 -o "/video-store/output_Larry.mpg" "output_Larry.m2v" "output_Larry.ac3"
Multiplexing finished successfully
Output files:
ls: output_Larry.[0-9]?.mpg: No such file or directory
output_Larry.mpg
output_Larry.mpg (33M)

=========================================================

----------------------------------------
Final statistics
----------------
tovid 0.26
File: /video-store/output_Larry.mpg, 53 secs DVD NTSC
Final size: 32912 kilobytes
Target bitrate: 7840 kbits/sec
Average bitrate: 4723 kbits/sec
Peak bitrate: 5222 kbits/sec
Took 00:02:42 to encode on AMD Athlon(tm) Processor
AMD Athlon(tm) Processor 1194.754
1194.754 mhz
-----------------------------------------
Statistics written to /root/.tovid/stats.tovid
Cleaning up...

=========================================================

Done!

=========================================================

Your encoded video should be in the file(s) /video-store/output_Larry.mpg.
Thanks for using tovid!

=========================================================

If you want to use the tovid command to process a batch of files, then you can do so with relative ease. In my case, I wanted to run tovid with a bunch of files that Paul Donahue and I had shot in Scotland. To do so, I ran this command:

linux:/video-store # tovid-batch -dvd -infiles dv045_scotland_04_001.dv dv045_scotland_04_002.dv dv045_scotland_04_003.dv dv045_scotland_04_004.dv dv045_scotland_04_005.dv dv045_scotland_04_006.dv dv045_scotland_04_007.dv dv045_scotland_04_008.dv dv045_scotland_04_009.dv

Notice that this command is a little bit different from the single file command in that you use the option "-infiles" rather than the "-in" and "-out" options with the single file.

Now you will need to create a VOB file structure, because K3B expects the same. I'm not sure why. It just is so. At least for the time being, and at least in the US. To get the details for doing so, please go to the CreatingVOBandXML page.

If you would like to learn a few tips with using K3B after you have first finished reading the CreatingVOBandXML page, you can find such a description in the FossMovieSoftwareK3B page.

subtopics: