.\" This manpage has been automatically generated by docbook2man
.\" from a DocBook document. This tool can be found at:
.\"
.\" Please send any bug reports, improvements, comments, patches,
.\" etc. to Steve Cheng .
.TH "MPEGCAT" "1" "28 October 2006" "" ""
.SH NAME
mpegcat \- Extracts structural information and PES streams from an MPEG2 video file
.SH SYNOPSIS
\fBmpegcat\fR { \fB\fIoptions\fB\fR } { \fB\fIfile\fB\fR }
.SH "DESCRIPTION"
.PP
\fBmpegcat\fR dumps detailed textual information about
an MPEG2 file. It also has an option for writing out a particular
Packetized Elementary Stream (PES) given its id.
.PP
The original purpose of \fBmpegcat\fR was for debugging stream parsing issues
in the gopchop cuts-only MPEG2 video editor, but it has more general utility.
.SH "OPTIONS"
.SS "GENERAL OPTIONS"
.TP
\fB-d,--debug\fR
Report debug info
.TP
\fB-D,--dvd-format\fR
Enable DVD packet extensions
.TP
\fB-h,-?,--help\fR
Help
.TP
\fB-w,--write \fIFILE\fB,\fI0xID\fB[,\fI0xSID\fB]\fR
Write \fIPES\fR with id \fIID\fR
(and subid \fISID\fR) to \fIFILE\fR\&.
Sub Picture Unit (SPU) streams such
as overlays, subtitles and DVD menus extracted using this option
can be displayed using the companion
\fBgtkspu\fR utility.
To find SPU streams in a .VOB ripped from a DVD:
.nf
$ \fBmpegcat \-iDa VTS_01_0.VOB | grep SPU\fR
131086: 0xBD: DVD Audio 0x20 (SPU 0): 2028 bytes (next marker @ 133120)
133134: 0xBD: DVD Audio 0x20 (SPU 0): 2028 bytes (next marker @ 135168)
137230: 0xBD: DVD Audio 0x20 (SPU 0): 190 bytes (next marker @ 137426)
...
.fi
To save a given stream:
.nf
$ \fBmpegcat \-iDaw dump.spu,0xBD,0x20 VTS_01_0.VOB > /dev/null\fR
.fi
(And to view the stream)
.nf
$ \fBgtkspu dump.spu 1\fR
$ \fBgtkspu dump.spu 2\fR
$ \fBgtkspu dump.spu 3\fR
...
.fi
.SS "PROCESSING TOGGLES"
.TP
\fB-V,--enter-video\fR
Process video packets (forced by \-t option)
.SS "GENERAL DISPLAY TOGGLES"
.TP
\fB-p,--pack\fR
Toggle Pack packet start display
.TP
\fB-v,--video\fR
Toggle video ES packet start display
.TP
\fB-a,--audio\fR
Toggle audio ES packet start display
.TP
\fB-o,--other\fR
Toggle other stream display (only show video & audio)
.TP
\fB-y,--system\fR
Toggle system header display
.TP
\fB-e,--errors\fR
Toggle packet errors
.TP
\fB-i,--invert\fR
Invert all display toggles
.SS "VIDEO DISPLAY TOGGLES"
.TP
\fB-s,--slices\fR
Toggle slice starts (default off)
.TP
\fB-q,--sequence\fR
Toggle sequence header display
.TP
\fB-g,--GOPs\fR
Toggle GOP header display
.TP
\fB-f,--frames\fR
Toggle Picture header display
.SS "SHORT CUTS"
.TP
\fB-F,--just-frames\fR
Show only video frames (same as '\-Vepvaoyq')
.SS "FILE OFFSET OPTIONS"
.TP
\fB-b,--begin=\fINUM\fB\fR
Start reading at offset \fINUM\fR
.TP
\fB-n,--num=\fINUM\fB\fR
Stop after reading \fINUM\fR bytes
.TP
\fB-t,--scan-stream\fR
Scan every byte of the stream instead of using PES offsets
(this can show erroneous 'start code emulation' codes)
.SH "AUTHOR"
.PP
Kees Cook,
.SH "SEE ALSO"
.PP
gopchop(1), gtkspu(1)