Extracting subtites

Step one is easy.
You will need the following programs:

  • transcode
  • mplayer
  • subtitleripper

Using with Linux just use the following script (originally taken from the Gentoo Wiki):

#!/bin/bash
lsdvd
echo “Please type in the stream number”
read DVDSTREAM;
mplayer -dvd-device /dev/dvd dvd://$DVDSTREAM -vo null -ao null -frames 0 -v 2>&1 | grep sid
# ask the user for sid…# the correct number is 0x20 + sid
echo “Please type in the subtitle SID, type in hexadecimal and add 0x20. Example: for sid 0, type 0x20”
read SID;

tccat -i /dev/dvd -T $DVDSTREAM -L | tcextract -x ps1 -t vob -a $SID > subs
subtitles2pgm -o subtitles-$DVDSTREAM -c 0,255,255,255
We will end up with a lot of pictures, each containing one piece of the final base64 encoded file. The next step will be to convert these pictures into text using an ocr-programm

Advertisements

4 Responses to Extracting subtites

  1. Michael Vant says:

    Just to clarify, the transcode program is for changining the dvd files into another format such a mpeg’s, and then using subtitle ripper to get the subtitle’s of the dvd, but what is mplayer? Microsoft media player?

    Also, where do we enter the code you have listed, and also is there a windows version?

  2. Sven says:

    Yes, Transcode is the actual ripper, subtitleripper does convert the subtitle images to text. MPlayer is only used to display the subtitle streams included in the selected track. MPlayer is my favourite media player. http://www.mplayerhq.hu

    The code is a bash script, something like a batch-file for linux.

    About Windows:
    It should be possible to convert this code to a batch-file. but I don’t know enough about that to do it, sorry.

  3. Michael Vant says:

    Ok, I’m looking for a reasonable version of a transcoder (I found one actually called transcoder, is that the one you mean? I had a look at the install, requires a lot of other programs to function correctly.), and as far as I can tell, the .vob files found under video_ts on the series 2 dvd that are neccesary ones to decode are the following:

    VTS_01_1.VOB
    VTS_02_1.VOB
    VTS_03_1.VOB
    VTS_04_1.VOB
    VTS_05_1.VOB
    VTS_06_1.VOB

  4. Sven says:

    I’m sorry, transcode http://www.transcoding.org is linux only. (Well, actually any Unix-like OS.)
    But yes, these .VOB files do contain the videos for each episode. See http://www.doom9.org/index.html?/subtitle_guides.htm for a guide, on how to extract these files with Windows.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: