view TOOLS/x2mpsub.sh @ 13694:acf4fbc26d05

Sync with 1.787: 1.787: lavc is faster than XviD and thus recommended for decoding and PP. 1.786: man page review part XII 1.785: consistent I/P/B-frame spelling 1.784: Spelling/wording/clarity improvements and bug fixes.
author gpoirier
date Tue, 19 Oct 2004 20:11:26 +0000
parents 2c6c21e1a1a1
children
line wrap: on
line source

#!/bin/sh
#
# This script converts the subtitles in the current directory into
# MPsub format (into ./converted-subtitles/*)
#
# Gabucino. No warranty. :)
#

TMP="x2mpsub-$RANDOM"
mkdir "$TMP"
touch "$TMP/$TMP"

for x in *; do
    echo "Converting $x"
    mplayer "$TMP/$TMP" -sub "$x" -dumpmpsub -quiet > /dev/null 2> /dev/null
    mv dump.mpsub "$TMP/$x"
done

rm "$TMP/$TMP"
mv "$TMP" converted-subtitles