Skip to content

Muxer VOBsub

Phillippe Pelzer edited this page Nov 15, 2026 · 1 revision

vobsub: VOBsub muxer

vobsub writes DVD bitmap subtitles as a VOBsub pair: an .idx index and a .sub data file. It copies the bitmaps. It does not re-encode them.

Official FFmpeg can read VOBsub but cannot write it. This muxer is NoMercy-only.

Since: v1.0.30.

Quick example

# Extract the first subtitle stream of a DVD rip. Writes output.idx and output.sub.
ffmpeg -i movie.mkv -map 0:s:0 -c:s copy output.idx

Give the .idx name and the muxer is chosen from the extension. Give the .sub name and you must name the muxer:

ffmpeg -i movie.mkv -map 0:s:0 -c:s copy -f vobsub output.sub

Either way you get both files. The other file is opened next to the one you named.

Options

The muxer has no options. ffmpeg -h muxer=vobsub of v1.0.47 shows:

Property Value
Extensions idx, sub
MIME type application/x-vobsub
Default subtitle codec dvd_subtitle

What it writes

File Content
.idx The line # VobSub index file, v7 (do not modify this line!), the size: line, langidx: 0, id: <language>, index: 0, and one timestamp: line with a filepos: per subtitle.
.sub The subtitle packets in an MPEG-2 program stream (a pack and a PES packet for each).

How the header is filled:

  • If the stream carries extradata, it is copied into the .idx.
  • Without extradata, the size: line uses the stream's width and height, or 720x480 if they are unknown.
  • The language is the stream's language tag. It is und if there is none.

Limits

  • Map one subtitle stream per output pair. The header is built from the first stream.
  • The output name must end in .idx or .sub. Any other name is an error.
  • One packet must fit in one PES packet, under about 64 KB. A bigger packet is an error.

Next step

A VOBsub pair is the usual input for OCR. To turn the bitmaps into text inside FFmpeg, see Subtitles-OCR.

Platform notes

The muxer is in every platform archive. This page was checked against the source and -h muxer=vobsub. A VOBsub extraction was not run in this documentation pass, because no DVD subtitle sample was at hand.

Clone this wiki locally