Introduction
This is a plain text list of chapter start times and titles, in the form the OGM tools expect. mkvmerge calls it the simple chapter format and turns it into Matroska chapters. Subtitle Edit handles it as OGM Chapters, with the extension .txt.
Structure
Each chapter is a pair of numbered lines: its start time, then its name.
CHAPTER01=00:00:00.000
CHAPTER01NAME=Intro
- mkvmerge makes one Matroska chapter atom from each pair.
- If the file starts with a byte order mark, mkvmerge converts it to UTF-8 accordingly. Otherwise the character set can be given with
--chapter-charset. - Subtitle Edit reads times as hours, minutes, seconds and milliseconds, with a full stop or a comma before the milliseconds.
Not described
This page is a short summary, and there is no viewer for OGM chapter files.
Known, not yet covered
- Reference: how other programs treat numbering, spacing and unusual lines.
- Viewer: listing the chapters.
Also used for
- EBCDIC text – IBM mainframe text, not based on ASCII: a space at 40, letters at 81 and C1.
- GB18030 text – China’s national encoding: one, two or four bytes a character, covering all of Unicode.
- ISO-2022 and HZ text – 7-bit Japanese, Korean and Chinese text, with escape sequences that switch character sets.
- Legacy code page text – A pre-Unicode code page (Windows-1252, Mac OS Roman, DOS 437, Shift_JIS …), guessed.
- MPL2 subtitles – Plain text subtitles timed in tenths of a second.
- OpenAir Airspace – OpenAir airspace file under its older extension.
- Plain text – Characters and line endings, nothing more, in an encoding the file rarely names.
- TI-TXT hex file – Texas Instruments text format for memory images.
- TMPlayer subtitles – Plain text subtitles with one start time and its text per line.
- UTF-16BE text – Unicode in two or four bytes a character, high byte first.
- UTF-16LE text – Unicode in two or four bytes a character, low byte first; Windows’ “Unicode”.
- UTF-32BE text – Every character in four bytes, high byte first. Rare in files.
- UTF-32LE text – Every character in four bytes, low byte first. Rare in files.
- UTF-7 text – Unicode written as pure ASCII, with runs of Base64 holding UTF-16 units.
- UTF-8 text – Unicode in one to four bytes a character, with ASCII unchanged; the usual text today.
- UltraStar song – Karaoke game songs: header lines, then timed and pitched syllables.
Links
Software
- mkvmerge – Matroska multiplexer from MKVToolNix
- Subtitle Edit – subtitle editor
Reference
- mkvmerge manual – chapters in the simple format
- OgmChapters.cs – Subtitle Edit's reader and writer