[MEncoder-users] Generating Divx/MPEG4 files from ATSC .ts files
Philip Prindeville
philipp_subx at redfish-solutions.com
Tue Nov 22 05:32:06 CET 2005
I have some HD (1080i) streams that I captured using pchdtvr... And
I'm wondering how I can (a) crop the non-display 8 lines (not sure what
these are for... possibly closed captions), and (b) deinterlace the content.
Oh, and if there is line-21 old-fashioned NTSC style captions, I'd like
to strip them, convert them to DTV-style captions, and re-insert them
into the stream.
Any idea how to do all of this as a 2- or 3-pass script? I've tried the
following,
but it doesn't seem to work. No idea why. It still is de-interlaced,
for instance.
Thanks,
-Philip
#!/bin/sh
x() {
echo "$@"
$@
}
bitrate=20000000
for file in "$@"; do
dir=`dirname $file`
base=`basename $file .ts`
prog=`echo $base | sed 's/.*\.\([0-9]\)$/\1/'`
base=`echo $base | sed "s/\.$prog$//"`
base="$dir/$base"
for pass in 1 2; do
echo ""
echo "pass $pass..."
echo ""
x mencoder -quiet -sws 2 -oac copy -ovc lavc \
-lavcopts vcodec=mpeg4:vbitrate=$bitrate:vpass=$pass:autoaspect \
-vf crop=1920:1080,scale=1920:1080,pp=hb/vb/dr/al/lb \
-tsprog $prog \
-o "$base.avi" "$file"
done
done
More information about the MEncoder-users
mailing list