(redirected from Vob2Srt)

[Home]Command Examples/Generating Subtitle Files

Vobsub -> srt

This almost works... Alas, subrip ALWAYS ends prematurely, you will never get the full set of subs.

Install [gocr-0.40]

Do NOT try to use the CVS version of gocr, it's usually broken.

And [subrip-0.3-4]

Subrip may also be found in the TOOLS subdirectory of the mplayer source.

Subrip calls gocr as an external process. It's easy to find the gocr invocation in the subrip.c file, and you may want to make an extra version of subrip that calls gocr with -s 9 instead of -s 7 for those times when gocr decides that there are spaces between every character in the substream ;^)

Decide which subtitle ID you need:

 mplayer -vo null -ao null -frames 0 -identify dvd://1

Extract the .idx and .sub files for that subtitle ID:

 mencoder -ovc copy \
          -o /dev/null \
          -nosound \
          -vobsubout subtitles \ <- the name of the output files
          -vobsuboutindex 1 \    <- the index used in the output
          -vobsuboutid en \      <- the code used in the output file
          -sid $N $basename      <- the i.d. of the stream to be extracted

Run subrip:

 rm -rf db
 mkdir db
 subrip $basename 1 $basename.srt You will be prompted to identify
                                  about 40 glyphs during this process.

Fix the errors in the .srt file by hand, and you're done!

If subrip seems to be asking you to identify the same character more than once, the subtitle file may be too difficult for subrip to process... This does happen.

Transcode Wiki | Command Examples | Recent Changes | Preferences
Password required to edit | View other revisions
Last edited May 24, 2006 12:21 am by tarazed.ligo.caltech.edu (diff)