License Public Domain
Lines 13
Keywords
DVD (1) MPEG (1) mplex (1) transcode (1)
Permissions
Owner: Stou S.
Viewable by Everyone
Editable by All Siafoo Users
Hide
Siafoo is here to make coding less frustrating and to save you time. Join Siafoo Now or Learn More

Script for transcoding a set of files to MPEG (S)VCD / DVD format Atom Feed 0

In Brief Given a directory as an argument, the script will call transcode and mplex on each file and save the resulting MPEGs to the current directory. This script is useful for batch transcoding a large number of files that you can then manually "arrange" on a DVD.... more
# 's
 1#!/bin/bash
2
3in_dir=$1
4out_dir='./'
5let "dir_len = ${#1}"
6
7for file in $(find $in_dir -iname '*.AVI' ); do
8 in_file=${file:dir_len}
9 out_file=${in_file:0:(${#in_file}-4)}
10 echo "Running against ${in_file} output ${out_file}"
11
12# tovid -quality 10 -noask -parallel -in ${in_dir}${in_file} -out ${out_dir}${out_file}
13 transcode -i $1/${in_file} -y ffmpeg --export_prof dvd-ntsc --export_asr 3 -o ${out_file} -D0 -s2 -m ${out_file}.ac3 -J modfps --export_fps 29.97
14 mplex -f8 ${out_file}.ac3 ${out_file}.m2v -o ${out_file}.mpg
15# rm ${out_file}.ac3 ${out_file}.m2v
16done

Given a directory as an argument, the script will call transcode and mplex on each file and save the resulting MPEGs to the current directory. This script is useful for batch transcoding a large number of files that you can then manually "arrange" on a DVD.

At one point this script called tovid but since that program never actually worked for me, I used the directions found here: http://www.mepis.org/docs/en/index.php/AVI_to_DVD_MPEG_Conversion and changed the script to use transcode and mplex.

Look at any2dvd for a fairly powerful script for automagically transcoding and burning DVDs.