[mythtv-users] External subtitles in xine

Sasha Z kleptophobiac at gmail.com
Fri May 26 12:56:55 UTC 2006


One of the mythtv-users members posted up this handy little script for
capturing the subtitle file for a movie when played from mythvideo:

#!/bin/bash
FILE="$@"
DIR=`dirname "$FILE"`
SUB=`basename "$FILE" ".${FILE##*.}"`
SUB1="$SUB*.sub"
SUB2="$SUB*.srt"
SUB3="$SUB*.txt"
SUBT=`find "$DIR" -maxdepth 1 -type f -and \( -name "$SUB1" -or -name
"$SUB2" -or -name "$SUB3" \) | head -n 1`
if [ -n "$SUBT" ]
then
       FILE="$FILE#subtitle:$SUBT"
fi
xine -pfhq --no-logo --no-splash -V xv "$FILE"

I'd like to know how to toggle subtitles on and off with the remote
control. It seems like that should be a really basic feature, but I
don't see it anywhere in the xine keymap. Any ideas?


More information about the mythtv-users mailing list