Movatterモバイル変換


[0]ホーム

URL:


RFC 9559Matroska FormatOctober 2024
Lhomme, et al.Standards Track[Page]
Stream:
Internet Engineering Task Force (IETF)
RFC:
9559
Updates:
8794
Category:
Standards Track
Published:
ISSN:
2070-1721
Authors:
S. Lhomme
M. Bunkus
D. Rice

RFC 9559

Matroska Media Container Format Specification

Abstract

This document defines the Matroska audiovisual data container structure,including definitions of its structural elements, terminology,vocabulary, and application.

This document updates RFC 8794 to permit the use of a previously reserved Extensible Binary Meta Language (EBML) Element ID.

Status of This Memo

This is an Internet Standards Track document.

This document is a product of the Internet Engineering Task Force (IETF). It represents the consensus of the IETF community. It has received public review and has been approved for publication by the Internet Engineering Steering Group (IESG). Further information on Internet Standards is available in Section 2 of RFC 7841.

Information about the current status of this document, any errata, and how to provide feedback on it may be obtained athttps://www.rfc-editor.org/info/rfc9559.

Copyright Notice

Copyright (c) 2024 IETF Trust and the persons identified as the document authors. All rights reserved.

This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (https://trustee.ietf.org/license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Revised BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Revised BSD License.

Table of Contents

1.Introduction

Matroska is an audiovisual data container format. It was derived from aproject called[MCF] but diverges from itsignificantly because it is based on EBML (Extensible Binary Meta Language)[RFC8794], a binary derivative of XML. EBMLprovides significant advantages in terms of future format extensibility,without breaking file support in parsers reading the previous versions.

To avoid any misunderstandings, it is essential to clarify exactlywhat an audio/video container is:

Matroska is designed with the future in mind. It incorporates features such as:

2.Status of This Document

This document covers Matroska versions 1, 2, 3, and 4. Matroska version 4 is the current version.Matroska versions 1 to 3 are no longer maintained. No new elements are expected in files with version numbers 1, 2, or 3.

3.Notation and Conventions

The key words "MUST", "MUST NOT","REQUIRED", "SHALL", "SHALL NOT","SHOULD", "SHOULD NOT","RECOMMENDED", "NOT RECOMMENDED","MAY", and "OPTIONAL" in this document areto be interpreted as described in BCP 14[RFC2119][RFC8174] when, and only when, they appear in all capitals,as shown here.

This document defines the following terms in order todefine the format and application of Matroska:

Matroska:

A multimedia container format based on EBML (Extensible Binary Meta Language).

Matroska Reader:

A data parser that interprets the semantics of a Matroska document and creates a way for programs to use Matroska.

Matroska Player:

AMatroska Reader with the primary purpose of playing audiovisual files, including Matroska documents.

Matroska Writer:

A data writer that creates Matroska documents.

4.Matroska Overview

4.1.Principles

Matroska is a Document Type of EBML.This specification is dependent on the EBML specification[RFC8794].For an understanding of Matroska's EBML Schema, see in particular the sections of the EBML specification that coverEBML Element Types (Section7),EBML Schema (Section11.1),and EBML Structure (Section3).

4.2.Updates to RFC 8794

Because of an oversight,[RFC8794] reserved EBML ID 0x80, which is used by deployed Matroska implementations.For this reason, this specification updates[RFC8794] to make 0x80 a legal EBML ID. Additionally, this specification makes the following updates:

OLD:

One-octet Element IDsMUST be between 0x81 and0xFE. These items are valuable because they are short, and they need to beused for commonly repeated elements. Element IDs are to be allocated withinthis range according to the "RFC Required" policy[RFC8126].

The following one-octet Element IDs are RESERVED: 0xFF and 0x80.

NEW:

One-octet Element IDsMUST be between 0x80 and0xFE. These items are valuable because they are short, and they need to beused for commonly repeated elements. Element IDs are to be allocated withinthis range according to the "RFC Required" policy[RFC8126].

The following one-octet Element ID is RESERVED: 0xFF.

OLD:

  +=========================+================+=================+  | Element ID Octet Length | Range of Valid | Number of Valid |  |                         |  Element IDs   |     Element IDs |  +=========================+================+=================+  |            1            |  0x81 - 0xFE   |             126 |  +-------------------------+----------------+-----------------+

NEW:

  +=========================+================+=================+  | Element ID Octet Length | Range of Valid | Number of Valid |  |                         |  Element IDs   |     Element IDs |  +=========================+================+=================+  |            1            |  0x80 - 0xFE   |             127 |  +-------------------------+----------------+-----------------+

4.3.Added EBML Constraints

As an EBML Document Type, Matroska adds the following constraints to the EBML specification[RFC8794]:

  • ThedocType of theEBML HeaderMUST be "matroska".

  • TheEBMLMaxIDLength of theEBML HeaderMUST be 4.

  • TheEBMLMaxSizeLength of theEBML HeaderMUST be between 1 and 8, inclusive.

4.4.Design Rules

TheRoot Element and allTop-Level ElementsMUST use 4 octets for their EBML Element ID -- i.e.,Segment and direct children ofSegment.

Legacy EBML/Matroska parsers did not handle Empty Elements properly; elements were present in the file but had a length of 0.They always assumed the value was 0 for integers/dates or 0x0p+0, the textual expression of floats using the format in[ISO9899], no matter the default value of the element that should have been used instead.Therefore,Matroska WritersMUST NOT use EBML Empty Elements if the element has a default value that is not 0 for integers/dates and 0x0p+0 for floats.

When adding new elements to Matroska, these rules apply:

  • A non-mandatory integer/date ElementMUST NOT have a default value other than 0.

  • A non-mandatory float ElementMUST NOT have a default value other than 0x0p+0.

  • A non-mandatory string ElementMUST NOT have a default value, as empty strings cannot be defined in the XML Schema.

4.5.Data Layout

A Matroska fileMUST be composed of at least oneEBML Document using theMatroska Document Type.EachEBML DocumentMUST start with anEBML Header andMUST be followed by theEBML Root Element, defined asSegment in Matroska. Matroska defines severalTop-Level Elementsthat may occur within theSegment.

As an example, a simple Matroska file consisting of a singleEBML Document could be represented like this:

  • EBML Header
  • Segment

A more complex Matroska file consisting of anEBML Stream (consisting of twoEBML Documents) could be represented like this:

  • EBML Header
  • Segment
  • EBML Header
  • Segment

The following diagram represents a simple Matroska file, comprised of anEBML Documentwith anEBML Header, aSegment element (theRoot Element), and all eight MatroskaTop-Level Elements. In the diagrams in this section, horizontal spacing expressesa parent-child relationship between Matroska elements (e.g., theInfo element is contained withintheSegment element), whereas vertical alignment represents the storage order within the file.

+-------------+| EBML Header |+---------------------------+| Segment     | SeekHead    ||             |-------------||             | Info        ||             |-------------||             | Tracks      ||             |-------------||             | Chapters    ||             |-------------||             | Cluster     ||             |-------------||             | Cues        ||             |-------------||             | Attachments ||             |-------------||             | Tags        |+---------------------------+
Figure 1:Basic Layout of a Matroska File

The MatroskaEBML Schema defines eightTop-Level Elements:

TheSeekHead element (also known asMetaSeek) contains anindex ofTop-Level Elements locations within theSegment. Use of theSeekHead element isRECOMMENDED. Without aSeekHead element, a Matroskaparser would have to search the entire file to find all of the otherTop-Level Elements. This is due to Matroska's flexible orderingrequirements; for instance, it is acceptable for theChapters elementto be stored after theCluster element(s).

+--------------------------------+| SeekHead | Seek | SeekID       ||          |      |--------------||          |      | SeekPosition |+--------------------------------+
Figure 2:Representation of aSeekHead Element

TheInfo element contains vital information for identifying the wholeSegment.This includes the title for theSegment, a randomly generated unique identifier (UID),and the UID(s) of any linkedSegment elements.

+-------------------------+| Info | SegmentUUID      ||      |------------------||      | SegmentFilename  ||      |------------------||      | PrevUUID         ||      |------------------||      | PrevFilename     ||      |------------------||      | NextUUID         ||      |------------------||      | NextFilename     ||      |------------------||      | SegmentFamily    ||      |------------------||      | ChapterTranslate ||      |------------------||      | TimestampScale   ||      |------------------||      | Duration         ||      |------------------||      | DateUTC          ||      |------------------||      | Title            ||      |------------------||      | MuxingApp        ||      |------------------||      | WritingApp       ||-------------------------|
Figure 3:Representation of anInfo Element and ItsChild Elements

TheTracks element defines the technical details for each track and can store the name,number, UID, language, and type (audio, video, subtitles, etc.) of each track.For example, theTracks elementMAY store information about the resolution of a video trackor sample rate of an audio track.

TheTracks elementMUST identify all the data needed by the codec to decode the data of thespecified track. However, the data required is contingent on the codec used for the track.For example, aTrack element for uncompressed audio only requires the audio bit rate to be present.A codec such as AC-3 would require that theCodecID element be present for all tracks,as it is the primary way to identify which codec to use to decode the track.

+------------------------------------+| Tracks | TrackEntry | TrackNumber  ||        |            |--------------||        |            | TrackUID     ||        |            |--------------||        |            | TrackType    ||        |            |--------------||        |            | Name         ||        |            |--------------||        |            | Language     ||        |            |--------------||        |            | CodecID      ||        |            |--------------||        |            | CodecPrivate ||        |            |--------------||        |            | CodecName    ||        |            |----------------------------------+|        |            | Video        | FlagInterlaced    ||        |            |              |-------------------||        |            |              | FieldOrder        ||        |            |              |-------------------||        |            |              | StereoMode        ||        |            |              |-------------------||        |            |              | AlphaMode         ||        |            |              |-------------------||        |            |              | PixelWidth        ||        |            |              |-------------------||        |            |              | PixelHeight       ||        |            |              |-------------------||        |            |              | DisplayWidth      ||        |            |              |-------------------||        |            |              | DisplayHeight     ||        |            |              |-------------------||        |            |              | AspectRatioType   ||        |            |              |-------------------||        |            |              | Colour            ||        |            |----------------------------------||        |            | Audio        | SamplingFrequency ||        |            |              |-------------------||        |            |              | Channels          ||        |            |              |-------------------||        |            |              | BitDepth          ||--------------------------------------------------------|
Figure 4:Representation of theTracks Element and a Selection of ItsDescendant Elements

TheChapters element lists all of the chapters.Chapters are a way to set predefinedpoints to jump to in video or audio.

+-----------------------------------------+| Chapters | Edition | EditionUID         ||          | Entry   |--------------------||          |         | EditionFlagDefault ||          |         |--------------------||          |         | EditionFlagOrdered ||          |         |---------------------------------+|          |         | ChapterAtom | ChapterUID        ||          |         |             |-------------------||          |         |             | ChapterStringUID  ||          |         |             |-------------------||          |         |             | ChapterTimeStart  ||          |         |             |-------------------||          |         |             | ChapterTimeEnd    ||          |         |             |-------------------||          |         |             | ChapterFlagHidden ||          |         |             |-------------------------------+|          |         |             | ChapterDisplay | ChapString   ||          |         |             |                |--------------||          |         |             |                | ChapLanguage |+------------------------------------------------------------------+
Figure 5:Representation of theChapters Element and a Selection of ItsDescendant Elements

Cluster elements contain the content for each track, e.g., video frames. A Matroska fileSHOULD contain at least oneCluster element.In the rare case it doesn't, there should be a method forSegments to linktogether, possibly usingChapters; seeSection 17.

TheCluster element helps to break upSimpleBlock orBlockGroup elements and helps with seeking and error protection.EveryCluster elementMUST contain aTimestamp element.ThisSHOULD be theTimestamp element used to play the firstBlock in theCluster element,unless a different value is needed to accommodate for moreBlocks; seeSection 11.2.

Cluster elements contain one or moreBlock element, such asBlockGroup orSimpleBlock elements.In some situations, aCluster elementMAY contain noBlock element, for example, in a live recordingwhen no data has been collected.

ABlockGroup elementMAY contain aBlock of data and any information relating directly to thatBlock.

+--------------------------+| Cluster | Timestamp      ||         |----------------||         | Position       ||         |----------------||         | PrevSize       ||         |----------------||         | SimpleBlock    ||         |----------------||         | BlockGroup     |+--------------------------+
Figure 6:Representation of aCluster Element and Its ImmediateChild Elements
+----------------------------------+| Block | Portion of | Data Type   ||       | a Block    |  - Bit Flag ||       |--------------------------+|       | Header     | TrackNumber ||       |            |-------------||       |            | Timestamp   ||       |            |-------------||       |            | Flags       ||       |            |  - Gap      ||       |            |  - Lacing   ||       |            |  - Reserved ||       |--------------------------||       | Optional   | FrameSize   ||       |--------------------------||       | Data       | Frame       |+----------------------------------+
Figure 7:Representation of theBlock Element Structure

EachClusterMUST contain exactly oneTimestamp element. TheTimestamp element valueMUSTbe stored once perCluster. TheTimestamp element in theCluster is relative to the entireSegment.TheTimestamp elementSHOULD be the first element in theCluster it belongs to or the second element if thatCluster contains aCRC-32 element (Section 6.2).

Additionally, theBlock contains an offset that, when added to theCluster'sTimestamp element value,yields theBlock's effective timestamp. Therefore, the timestamp in theBlock itself is relative totheTimestamp element in theCluster. For example, if theTimestamp element in theClusteris set to 10 seconds and aBlock in thatCluster is supposed to be played 12 seconds into the clip,the timestamp in theBlock would be set to 2 seconds.

TheReferenceBlock in theBlockGroup is used instead of the basic "P-frame"/"B-frame" description.Instead of simply saying that thisBlock depends on theBlock directly before or directly after,theTimestamp of the necessaryBlock is used. Because there can be as manyReferenceBlock elementsas necessary for aBlock, it allows for some extremely complex referencing.

TheCues element is used to seek when playing back a file by providing a temporal indexfor some of theTracks. It is similar to theSeekHead element but is used for seeking to a specific time when playing back the file. It is possible to seek without this element,but it is much more difficult because aMatroska Reader would have to "hunt and peck"through the file to look for the correct timestamp.

TheCues elementSHOULD contain at least oneCuePoint element. EachCuePoint elementstores the position of theCluster that contains theBlockGroup orSimpleBlock element.The timestamp is stored in theCueTime element, and the location is stored in theCueTrackPositions element.

TheCues element is flexible. For instance, theCues element can be used to index everysingle timestamp of everyBlock or they can be indexed selectively.

+-------------------------------------+| Cues | CuePoint | CueTime           ||      |          |-------------------||      |          | CueTrackPositions ||      |------------------------------||      | CuePoint | CueTime           ||      |          |-------------------||      |          | CueTrackPositions |+-------------------------------------+
Figure 8:Representation of aCues Element and Two Levels of ItsDescendant Elements

TheAttachments element is for attaching files to a Matroska file, such as pictures,fonts, web pages, etc.

+------------------------------------------------+| Attachments | AttachedFile | FileDescription   ||             |              |-------------------||             |              | FileName          ||             |              |-------------------||             |              | FileMediaType     ||             |              |-------------------||             |              | FileData          ||             |              |-------------------||             |              | FileUID           |+------------------------------------------------+
Figure 9:Representation of anAttachments Element

TheTags element contains metadata that describes theSegment and potentiallyitsTracks,Chapters, andAttachments. EachTrack orChapter that those tagsapplies to has its UID listed in theTags. TheTags contain all extra information aboutthe file: scriptwriters, singers, actors, directors, titles, edition, price, dates, genre, comments,etc.Tags can contain their values in multiple languages.For example, a movie's "TITLE" tag value might contain both the originalEnglish title as well as the German title.

+-------------------------------------------+| Tags | Tag | Targets   | TargetTypeValue  ||      |     |           |------------------||      |     |           | TargetType       ||      |     |           |------------------||      |     |           | TagTrackUID      ||      |     |           |------------------||      |     |           | TagEditionUID    ||      |     |           |------------------||      |     |           | TagChapterUID    ||      |     |           |------------------||      |     |           | TagAttachmentUID ||      |     |------------------------------||      |     | SimpleTag | TagName          ||      |     |           |------------------||      |     |           | TagLanguage      ||      |     |           |------------------||      |     |           | TagDefault       ||      |     |           |------------------||      |     |           | TagString        ||      |     |           |------------------||      |     |           | TagBinary        ||      |     |           |------------------||      |     |           | SimpleTag        |+-------------------------------------------+
Figure 10:Representation of aTags Element and Three Levels of ItsChildren Elements

5.Matroska Schema

This specification includes anEBML Schema that defines the elements and structureof Matroska using the EBML Schema elements and attributes defined inSection 11.1 of [RFC8794].

Attributes using their default value (likeminOccurs,minver, etc.) or attributes with undefined values (likelength,maxver, etc.) are omitted.

The definitions for each Matroska element are provided below.

5.1.Segment Element

id / type:
0x18538067 / master
unknownsizeallowed:
True
path:
\Segment
minOccurs / maxOccurs:
1 / 1
definition:
TheRoot Element that contains all otherTop-Level Elements; seeSection 4.5.

5.1.1.SeekHead Element

id / type:
0x114D9B74 / master
path:
\Segment\SeekHead
maxOccurs:
2
definition:
Contains seeking information ofTop-Level Elements; seeSection 4.5.
5.1.1.1.Seek Element
id / type:
0x4DBB / master
path:
\Segment\SeekHead\Seek
minOccurs:
1
definition:
Contains a single seek entry to an EBML Element.
5.1.1.1.1.SeekID Element
id / type:
0x53AB / binary
length:
4
path:
\Segment\SeekHead\Seek\SeekID
minOccurs / maxOccurs:
1 / 1
definition:
The binary EBML ID of aTop-Level Element.
5.1.1.1.2.SeekPosition Element
id / type:
0x53AC / uinteger
path:
\Segment\SeekHead\Seek\SeekPosition
minOccurs / maxOccurs:
1 / 1
definition:
TheSegment Position (Section 16) of aTop-Level Element.

5.1.2.Info Element

id / type:
0x1549A966 / master
path:
\Segment\Info
minOccurs / maxOccurs:
1 / 1
recurring:
True
definition:
Contains general information about theSegment.
5.1.2.1.SegmentUUID Element
id / type:
0x73A4 / binary
length:
16
path:
\Segment\Info\SegmentUUID
maxOccurs:
1
definition:
A randomly generated UID that identifies theSegment amongst many others (128 bits). It is equivalent to a Universally Unique Identifier (UUID) v4[RFC9562] with all bits randomly (or pseudorandomly) chosen. An actual UUID v4 value, where some bits are not random,MAY also be used.
usage notes:
If theSegment is a part of aLinked Segment, then this element isREQUIRED.The value of the UIDMUST contain at least one bit set to 1.
5.1.2.2.SegmentFilename Element
id / type:
0x7384 / utf-8
path:
\Segment\Info\SegmentFilename
maxOccurs:
1
definition:
A filename corresponding to thisSegment.
5.1.2.3.PrevUUID Element
id / type:
0x3CB923 / binary
length:
16
path:
\Segment\Info\PrevUUID
maxOccurs:
1
definition:
An ID that identifies the previousSegment of aLinked Segment.
usage notes:
If theSegment is a part of aLinked Segment that usesHard Linking (Section 17.1), then either thePrevUUID or theNextUUID element isREQUIRED. If aSegment contains aPrevUUIDbut not aNextUUID, then itMAY be considered as thelastSegment of theLinked Segment. ThePrevUUIDMUST NOT be equal to theSegmentUUID.
5.1.2.4.PrevFilename Element
id / type:
0x3C83AB / utf-8
path:
\Segment\Info\PrevFilename
maxOccurs:
1
definition:
A filename corresponding to the file of the previousLinked Segment.
usage notes:
Provision of the previous filename is for display convenience,butPrevUUIDSHOULD be considered authoritative for identifying the previousSegment in aLinked Segment.
5.1.2.5.NextUUID Element
id / type:
0x3EB923 / binary
length:
16
path:
\Segment\Info\NextUUID
maxOccurs:
1
definition:
An ID that identifies the nextSegment of aLinked Segment.
usage notes:
If theSegment is a part of aLinked Segment that uses Hard Linking (Section 17.1),then either thePrevUUID or theNextUUID element isREQUIRED. If aSegment contains aNextUUID but not aPrevUUID, then itMAY be considered as the firstSegment of theLinked Segment. TheNextUUIDMUST NOT be equal to theSegmentUUID.
5.1.2.6.NextFilename Element
id / type:
0x3E83BB / utf-8
path:
\Segment\Info\NextFilename
maxOccurs:
1
definition:
A filename corresponding to the file of the nextLinked Segment.
usage notes:
Provision of the next filename is for display convenience,butNextUUIDSHOULD be considered authoritative for identifying the NextSegment.
5.1.2.7.SegmentFamily Element
id / type:
0x4444 / binary
length:
16
path:
\Segment\Info\SegmentFamily
definition:
A UID that allSegments of aLinked SegmentMUST share (128 bits). It is equivalent to a UUID v4[RFC9562] with all bits randomly (or pseudorandomly) chosen. An actual UUID v4 value, where some bits are not random,MAY also be used.
usage notes:
If theSegmentInfo contains aChapterTranslate element, this element isREQUIRED.
5.1.2.8.ChapterTranslate Element
id / type:
0x6924 / master
path:
\Segment\Info\ChapterTranslate
definition:
The mapping between thisSegment and asegment value in the given Chapter Codec.
rationale:
Chapter Codecs may need to address different segments, but they may not know of the way to identify such segments when stored in Matroska.This element and its child elements add a way to map the internal segments known to the Chapter Codec to theSegmentUUIDs in Matroska.This allows remuxing a file with Chapter Codec without changing the content of the codec data, just theSegment mapping.
5.1.2.8.1.ChapterTranslateID Element
id / type:
0x69A5 / binary
path:
\Segment\Info\ChapterTranslate\ChapterTranslateID
minOccurs / maxOccurs:
1 / 1
definition:
The binary value used to represent thisSegment in the chapter codec data.The format depends on theChapProcessCodecID used; seeSection 5.1.7.1.4.15.
5.1.2.8.2.ChapterTranslateCodec Element
id / type:
0x69BF / uinteger
path:
\Segment\Info\ChapterTranslate\ChapterTranslateCodec
minOccurs / maxOccurs:
1 / 1
definition:
Applies to the chapter codec of the given chapter edition(s); seeSection 5.1.7.1.4.15.
defined values:
SeeTable 31. Additional values can be registered in the "Matroska Chapter Codec IDs" registry defined inSection 27.14.
5.1.2.8.3.ChapterTranslateEditionUID Element
id / type:
0x69FC / uinteger
path:
\Segment\Info\ChapterTranslate\ChapterTranslateEditionUID
definition:
Specifies a chapter edition UID to which thisChapterTranslate applies.
usage notes:
When noChapterTranslateEditionUID is specified in theChapterTranslate, theChapterTranslate applies to all chapter editions found in theSegment using the givenChapterTranslateCodec.
5.1.2.9.TimestampScale Element
id / type / default:
0x2AD7B1 / uinteger / 1000000
range:
not 0 (1-18446744073709551615)
path:
\Segment\Info\TimestampScale
minOccurs / maxOccurs:
1 / 1
definition:
Base unit for Segment Ticks and Track Ticks, in nanoseconds. ATimestampScale value of 1000000 means scaled timestamps in theSegment are expressed in milliseconds; seeSection 11 on how to interpret timestamps.
5.1.2.10.Duration Element
id / type:
0x4489 / float
range:
> 0x0p+0
path:
\Segment\Info\Duration
maxOccurs:
1
definition:
Duration of theSegment, expressed inSegment Ticks, which are based onTimestampScale; seeSection 11.1.
5.1.2.11.DateUTC Element
id / type:
0x4461 / date
path:
\Segment\Info\DateUTC
maxOccurs:
1
definition:
The date and time that theSegment was created by the muxing application or library.
5.1.2.12.Title Element
id / type:
0x7BA9 / utf-8
path:
\Segment\Info\Title
maxOccurs:
1
definition:
General name of theSegment.
5.1.2.13.MuxingApp Element
id / type:
0x4D80 / utf-8
path:
\Segment\Info\MuxingApp
minOccurs / maxOccurs:
1 / 1
definition:
Muxing application or library (example: "libmatroska-0.4.3").
usage notes:
Include the full name of the application or library followed by the version number.
5.1.2.14.WritingApp Element
id / type:
0x5741 / utf-8
path:
\Segment\Info\WritingApp
minOccurs / maxOccurs:
1 / 1
definition:
Writing application (example: "mkvmerge-0.3.3").
usage notes:
Include the full name of the application followed by the version number.

5.1.3.Cluster Element

id / type:
0x1F43B675 / master
unknownsizeallowed:
True
path:
\Segment\Cluster
definition:
TheTop-Level Element containing the (monolithic)Block structure.
5.1.3.1.Timestamp Element
id / type:
0xE7 / uinteger
path:
\Segment\Cluster\Timestamp
minOccurs / maxOccurs:
1 / 1
definition:
Absolute timestamp of the cluster, expressed in Segment Ticks, which are based onTimestampScale; seeSection 11.1.
usage notes:
This elementSHOULD be the first child element of theCluster it belongs toor the second if thatCluster contains aCRC-32 element (Section 6.2).
5.1.3.2.Position Element
id / type:
0xA7 / uinteger
path:
\Segment\Cluster\Position
maxOccurs:
1
maxver:
4
definition:
TheSegment Position of theCluster in theSegment (0 in live streams).It might help to resynchronize the offset on damaged streams.
5.1.3.3.PrevSize Element
id / type:
0xAB / uinteger
path:
\Segment\Cluster\PrevSize
maxOccurs:
1
definition:
Size of the previousCluster, in octets. Can be useful for backward playing.
5.1.3.4.SimpleBlock Element
id / type:
0xA3 / binary
path:
\Segment\Cluster\SimpleBlock
minver:
2
definition:
Similar toBlock (seeSection 10.1) but without all the extra information.Mostly used to reduce overhead when no extra feature is needed; seeSection 10.2 onSimpleBlock Structure.
5.1.3.5.BlockGroup Element
id / type:
0xA0 / master
path:
\Segment\Cluster\BlockGroup
definition:
Basic container of information containing a singleBlock and information specific to thatBlock.
5.1.3.5.1.Block Element
id / type:
0xA1 / binary
path:
\Segment\Cluster\BlockGroup\Block
minOccurs / maxOccurs:
1 / 1
definition:
Block containing the actual data to be rendered and a timestamp relative to theCluster Timestamp;seeSection 10.1 onBlock Structure.
5.1.3.5.2.BlockAdditions Element
id / type:
0x75A1 / master
path:
\Segment\Cluster\BlockGroup\BlockAdditions
maxOccurs:
1
definition:
Contains additional binary data to complete theBlock element; seeSection 4.1.5 of [MatroskaCodec] for more information.An EBML parser that has no knowledge of theBlock structure could still see and use/skip these data.
5.1.3.5.2.1.BlockMore Element
id / type:
0xA6 / master
path:
\Segment\Cluster\BlockGroup\BlockAdditions\BlockMore
minOccurs:
1
definition:
Contains theBlockAdditional and some parameters.
5.1.3.5.2.2.BlockAdditional Element
id / type:
0xA5 / binary
path:
\Segment\Cluster\BlockGroup\BlockAdditions\BlockMore\BlockAdditional
minOccurs / maxOccurs:
1 / 1
definition:
Interpreted by the codec as it wishes (using theBlockAddID).
5.1.3.5.2.3.BlockAddID Element
id / type / default:
0xEE / uinteger / 1
range:
not 0 (1-18446744073709551615)
path:
\Segment\Cluster\BlockGroup\BlockAdditions\BlockMore\BlockAddID
minOccurs / maxOccurs:
1 / 1
definition:
An ID that identifies how to interpret theBlockAdditional data; seeSection 4.1.5 of [MatroskaCodec] formore information. A value of 1 indicates that theBlockAdditional data isdefined by the codec. Any other value indicates that theBlockAdditional datashould be handled according to theBlockAddIDType that is located in theTrackEntry.
usage notes:
EachBlockAddID valueMUST be unique between allBlockMore elements found in aBlockAdditions element. To keepMaxBlockAdditionID as low as possible, small valuesSHOULD be used.
5.1.3.5.3.BlockDuration Element
id / type:
0x9B / uinteger
path:
\Segment\Cluster\BlockGroup\BlockDuration
minOccurs / maxOccurs:
SeeTable 1 / 1
definition:
The duration of theBlock, expressed in Track Ticks; seeSection 11.1. TheBlockDuration element can be usefulat the end of aTrack to define the duration of the last frame (asthere is no subsequentBlock available) or when there is a break in atrack like for subtitle tracks.
notes:
SeeTable 1.
Table 1:BlockDuration Implementation Notes
attributenote
minOccursBlockDurationMUST be set (minOccurs=1) if the associatedTrackEntry stores aDefaultDuration value.
defaultIf a value is not present and noDefaultDuration is defined, the value is assumed to be the difference between the timestamp of thisBlock and the timestamp of the nextBlock in "display" order (not coding order).
5.1.3.5.4.ReferencePriority Element
id / type / default:
0xFA / uinteger / 0
path:
\Segment\Cluster\BlockGroup\ReferencePriority
minOccurs / maxOccurs:
1 / 1
definition:
This frame is referenced and has the specified cache priority.In the cache, only a frame of the same or higher priority can replace this frame. A value of 0 means the frame is not referenced.
5.1.3.5.5.ReferenceBlock Element
id / type:
0xFB / integer
path:
\Segment\Cluster\BlockGroup\ReferenceBlock
definition:
A timestamp value, relative to the timestamp of theBlock in thisBlockGroup, expressed in Track Ticks; seeSection 11.1.This is used to reference other frames necessary to decode this frame.The relative valueSHOULD correspond to a validBlock that thisBlock depends on.Historically,Matroska Writers didn't write the actualBlock(s) that thisBlock depends on, but they did writesomeBlock(s) in the past.

The value "0"MAY also be used to signify that thisBlock cannot be decoded on its own, but the necessary referenceBlock(s) is unknown. In this case, otherReferenceBlock elementsMUST NOT be found in the sameBlockGroup. If theBlockGroup doesn't have aReferenceBlock element, then theBlock it contains can be decoded without using any otherBlock data.

5.1.3.5.6.CodecState Element
id / type:
0xA4 / binary
path:
\Segment\Cluster\BlockGroup\CodecState
maxOccurs:
1
minver:
2
definition:
The new codec state to use. Data interpretation is private to the codec.This informationSHOULD always be referenced by a seek entry.
5.1.3.5.7.DiscardPadding Element
id / type:
0x75A2 / integer
path:
\Segment\Cluster\BlockGroup\DiscardPadding
maxOccurs:
1
minver:
4
definition:
Duration of the silent data added to theBlock, expressed inMatroska Ticks -- i.e., in nanoseconds; seeSection 11.1(padding at the end of theBlock for positive values and at thebeginning of theBlock for negative values). The duration ofDiscardPadding is not calculated in the duration of theTrackEntry andSHOULD be discarded duringplayback.

5.1.4.Tracks Element

id / type:
0x1654AE6B / master
path:
\Segment\Tracks
maxOccurs:
1
recurring:
True
definition:
ATop-Level Element of information with many tracks described.
5.1.4.1.TrackEntry Element
id / type:
0xAE / master
path:
\Segment\Tracks\TrackEntry
minOccurs:
1
definition:
Describes a track with all elements.
5.1.4.1.1.TrackNumber Element
id / type:
0xD7 / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Tracks\TrackEntry\TrackNumber
minOccurs / maxOccurs:
1 / 1
definition:
The track number as used in theBlock Header.
5.1.4.1.2.TrackUID Element
id / type:
0x73C5 / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Tracks\TrackEntry\TrackUID
minOccurs / maxOccurs:
1 / 1
definition:
A UID that identifies theTrack.
stream copy:
True (Section 8)
5.1.4.1.3.TrackType Element
id / type:
0x83 / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Tracks\TrackEntry\TrackType
minOccurs / maxOccurs:
1 / 1
definition:
TheTrackType defines the type of each frame found in theTrack.The valueSHOULD be stored on 1 octet.
defined values:
SeeTable 2. Additional values can be registered in the "Matroska Track Types" registry defined inSection 27.16.
stream copy:
True (Section 8)
Table 2:TrackType Values
valuelabelcontents of each frame
1videoAn image.
2audioAudio samples.
3complexA mix of different otherTrackType. The codec needs to define how theMatroska Player should interpret such data.
16logoAn image to be rendered over the video track(s).
17subtitleSubtitle or closed caption data to be rendered over the video track(s).
18buttonsInteractive button(s) to be rendered over the video track(s).
32controlMetadata used to control the player of theMatroska Player.
33metadataTimed metadata that can be passed on to theMatroska Player.
5.1.4.1.4.FlagEnabled Element
id / type / default:
0xB9 / uinteger / 1
range:
0-1
path:
\Segment\Tracks\TrackEntry\FlagEnabled
minOccurs / maxOccurs:
1 / 1
minver:
2
definition:
Set to 1 if the track is usable. It is possible to turn a track that is not usable into a usable track using chapter codecs or control tracks.
5.1.4.1.5.FlagDefault Element
id / type / default:
0x88 / uinteger / 1
range:
0-1
path:
\Segment\Tracks\TrackEntry\FlagDefault
minOccurs / maxOccurs:
1 / 1
definition:
Set to 1 if the track (audio, video, or subtitles) is eligible for automatic selection by the player; seeSection 19 for more details.
5.1.4.1.6.FlagForced Element
id / type / default:
0x55AA / uinteger / 0
range:
0-1
path:
\Segment\Tracks\TrackEntry\FlagForced
minOccurs / maxOccurs:
1 / 1
definition:
Applies only to subtitles. Set to 1 if the track is eligible for automatic selection by the player if it matches the user's language preference,even if the user's preferences would not normally enable subtitles with the selected audio track;this can be used for tracks containing only translations of audio in foreign languages or on-screen text.SeeSection 19 for more details.
5.1.4.1.7.FlagHearingImpaired Element
id / type:
0x55AB / uinteger
range:
0-1
path:
\Segment\Tracks\TrackEntry\FlagHearingImpaired
maxOccurs:
1
minver:
4
definition:
Set to 1 if and only if the track is suitable for users with hearing impairments.
5.1.4.1.8.FlagVisualImpaired Element
id / type:
0x55AC / uinteger
range:
0-1
path:
\Segment\Tracks\TrackEntry\FlagVisualImpaired
maxOccurs:
1
minver:
4
definition:
Set to 1 if and only if the track is suitable for users with visual impairments.
5.1.4.1.9.FlagTextDescriptions Element
id / type:
0x55AD / uinteger
range:
0-1
path:
\Segment\Tracks\TrackEntry\FlagTextDescriptions
maxOccurs:
1
minver:
4
definition:
Set to 1 if and only if the track contains textual descriptions of video content.
5.1.4.1.10.FlagOriginal Element
id / type:
0x55AE / uinteger
range:
0-1
path:
\Segment\Tracks\TrackEntry\FlagOriginal
maxOccurs:
1
minver:
4
definition:
Set to 1 if and only if the track is in the content's original language.
5.1.4.1.11.FlagCommentary Element
id / type:
0x55AF / uinteger
range:
0-1
path:
\Segment\Tracks\TrackEntry\FlagCommentary
maxOccurs:
1
minver:
4
definition:
Set to 1 if and only if the track contains commentary.
5.1.4.1.12.FlagLacing Element
id / type / default:
0x9C / uinteger / 1
range:
0-1
path:
\Segment\Tracks\TrackEntry\FlagLacing
minOccurs / maxOccurs:
1 / 1
definition:
Set to 1 if the trackMAY contain blocks that use lacing.When set to 0, all blocksMUST have their lacing flags set to "no lacing"; seeSection 10.3 on 'Block' Lacing.
5.1.4.1.13.DefaultDuration Element
id / type:
0x23E383 / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Tracks\TrackEntry\DefaultDuration
maxOccurs:
1
definition:
Number of nanoseconds per frame, expressed in Matroska Ticks -- i.e., in nanoseconds; seeSection 11.1("frame" in the Matroska sense -- one element put into a (Simple)Block).
stream copy:
True (Section 8)
5.1.4.1.14.DefaultDecodedFieldDuration Element
id / type:
0x234E7A / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Tracks\TrackEntry\DefaultDecodedFieldDuration
maxOccurs:
1
minver:
4
definition:
The period between two successive fields at the output of the decoding process, expressed in Matroska Ticks -- i.e., in nanoseconds; seeSection 11.1.SeeSection 9 for more information.
stream copy:
True (Section 8)
5.1.4.1.15.TrackTimestampScale Element
id / type / default:
0x23314F / float / 0x1p+0
range:
> 0x0p+0
path:
\Segment\Tracks\TrackEntry\TrackTimestampScale
minOccurs / maxOccurs:
1 / 1
maxver:
3
definition:
The scale to apply on this track to work at normal speed in relation with other tracks(mostly used to adjust video speed when the audio length differs).
stream copy:
True (Section 8)
5.1.4.1.16.MaxBlockAdditionID Element
id / type / default:
0x55EE / uinteger / 0
path:
\Segment\Tracks\TrackEntry\MaxBlockAdditionID
minOccurs / maxOccurs:
1 / 1
definition:
The maximum value ofBlockAddID (Section 5.1.3.5.2.3).A value of 0 means there is noBlockAdditions (Section 5.1.3.5.2) for this track.
5.1.4.1.17.BlockAdditionMapping Element
id / type:
0x41E4 / master
path:
\Segment\Tracks\TrackEntry\BlockAdditionMapping
minver:
4
definition:
Contains elements that extend the track format by adding content either to each frame,withBlockAddID (Section 5.1.3.5.2.3), or to the track as a wholewithBlockAddIDExtraData.
5.1.4.1.17.1.BlockAddIDValue Element
id / type:
0x41F0 / uinteger
range:
>=2
path:
\Segment\Tracks\TrackEntry\BlockAdditionMapping\BlockAddIDValue
maxOccurs:
1
minver:
4
definition:
If the track format extension needs content beside frames,the value refers to theBlockAddID (Section 5.1.3.5.2.3) value being described.
usage notes:
To keepMaxBlockAdditionID as low as possible, small valuesSHOULD be used.
5.1.4.1.17.2.BlockAddIDName Element
id / type:
0x41A4 / string
path:
\Segment\Tracks\TrackEntry\BlockAdditionMapping\BlockAddIDName
maxOccurs:
1
minver:
4
definition:
A human-friendly name describing the type ofBlockAdditional data,as defined by the associatedBlock Additional Mapping.
5.1.4.1.17.3.BlockAddIDType Element
id / type / default:
0x41E7 / uinteger / 0
path:
\Segment\Tracks\TrackEntry\BlockAdditionMapping\BlockAddIDType
minOccurs / maxOccurs:
1 / 1
minver:
4
definition:
Stores the registered identifier of theBlock Additional Mappingto define how theBlockAdditional data should be handled.
usage notes:
IfBlockAddIDType is 0, theBlockAddIDValue and correspondingBlockAddID valuesMUST be 1.
5.1.4.1.17.4.BlockAddIDExtraData Element
id / type:
0x41ED / binary
path:
\Segment\Tracks\TrackEntry\BlockAdditionMapping\BlockAddIDExtraData
maxOccurs:
1
minver:
4
definition:
Extra binary data that theBlockAddIDType can use to interpret theBlockAdditional data.The interpretation of the binary data depends on theBlockAddIDType value and the correspondingBlock Additional Mapping.
5.1.4.1.18.Name Element
id / type:
0x536E / utf-8
path:
\Segment\Tracks\TrackEntry\Name
maxOccurs:
1
definition:
A human-readable track name.
5.1.4.1.19.Language Element
id / type / default:
0x22B59C / string / eng
path:
\Segment\Tracks\TrackEntry\Language
minOccurs / maxOccurs:
1 / 1
definition:
The language of the track,in the Matroska languages form; seeSection 12 on language codes.This elementMUST be ignored if theLanguageBCP47 element is used in the sameTrackEntry.
5.1.4.1.20.LanguageBCP47 Element
id / type:
0x22B59D / string
path:
\Segment\Tracks\TrackEntry\LanguageBCP47
maxOccurs:
1
minver:
4
definition:
The language of the track,in the form defined in[RFC5646]; seeSection 12 on language codes.If this element is used, then anyLanguage elements used in the sameTrackEntryMUST be ignored.
5.1.4.1.21.CodecID Element
id / type:
0x86 / string
path:
\Segment\Tracks\TrackEntry\CodecID
minOccurs / maxOccurs:
1 / 1
definition:
An ID corresponding to the codec;see[MatroskaCodec] for more info.
stream copy:
True (Section 8)
5.1.4.1.22.CodecPrivate Element
id / type:
0x63A2 / binary
path:
\Segment\Tracks\TrackEntry\CodecPrivate
maxOccurs:
1
definition:
Private data only known to the codec.
stream copy:
True (Section 8)
5.1.4.1.23.CodecName Element
id / type:
0x258688 / utf-8
path:
\Segment\Tracks\TrackEntry\CodecName
maxOccurs:
1
definition:
A human-readable string specifying the codec.
5.1.4.1.24.AttachmentLink Element
id / type:
0x7446 / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Tracks\TrackEntry\AttachmentLink
maxOccurs:
1
maxver:
3
definition:
The UID of an attachment that is used by this codec.
usage notes:
The valueMUST match theFileUID value of an attachment found in thisSegment.
5.1.4.1.25.CodecDelay Element
id / type / default:
0x56AA / uinteger / 0
path:
\Segment\Tracks\TrackEntry\CodecDelay
minOccurs / maxOccurs:
1 / 1
minver:
4
definition:
The built-in delay for the codec, expressed in Matroska Ticks -- i.e., in nanoseconds; seeSection 11.1.It represents the number of codec samples that will be discarded by the decoder during playback.This timestamp valueMUST be subtracted from each frame timestamp in order to get the timestamp that will be actually played.The valueSHOULD be small so the muxing of tracks with the same actual timestamp are in the sameCluster.
stream copy:
True (Section 8)
5.1.4.1.26.SeekPreRoll Element
id / type / default:
0x56BB / uinteger / 0
path:
\Segment\Tracks\TrackEntry\SeekPreRoll
minOccurs / maxOccurs:
1 / 1
minver:
4
definition:
After a discontinuity, the duration of the datathat the decoderMUST decode before the decoded data is valid, expressed in Matroska Ticks -- i.e., in nanoseconds; seeSection 11.1.
stream copy:
True (Section 8)
5.1.4.1.27.TrackTranslate Element
id / type:
0x6624 / master
path:
\Segment\Tracks\TrackEntry\TrackTranslate
definition:
The mapping between thisTrackEntry and a track value in the given Chapter Codec.
rationale:
Chapter Codecs may need to address content in a specific track, but they may not know of the way to identify tracks in Matroska.This element and its child elements add a way to map the internal tracks known to the Chapter Codec to the track IDs in Matroska.This allows remuxing a file with Chapter Codec without changing the content of the codec data, just the track mapping.
5.1.4.1.27.1.TrackTranslateTrackID Element
id / type:
0x66A5 / binary
path:
\Segment\Tracks\TrackEntry\TrackTranslate\TrackTranslateTrackID
minOccurs / maxOccurs:
1 / 1
definition:
The binary value used to represent thisTrackEntry in the chapter codec data.The format depends on theChapProcessCodecID used; seeSection 5.1.7.1.4.15.
5.1.4.1.27.2.TrackTranslateCodec Element
id / type:
0x66BF / uinteger
path:
\Segment\Tracks\TrackEntry\TrackTranslate\TrackTranslateCodec
minOccurs / maxOccurs:
1 / 1
definition:
Applies to the chapter codec of the given chapter edition(s); seeSection 5.1.7.1.4.15.
defined values:
SeeTable 31. Additional values can be registered in the "Matroska Chapter Codec IDs" registry defined inSection 27.14.
5.1.4.1.27.3.TrackTranslateEditionUID Element
id / type:
0x66FC / uinteger
path:
\Segment\Tracks\TrackEntry\TrackTranslate\TrackTranslateEditionUID
definition:
Specifies a chapter edition UID to which thisTrackTranslate applies.
usage notes:
When noTrackTranslateEditionUID is specified in theTrackTranslate, theTrackTranslate applies to all chapter editions found in theSegment using the givenTrackTranslateCodec.
5.1.4.1.28.Video Element
id / type:
0xE0 / master
path:
\Segment\Tracks\TrackEntry\Video
maxOccurs:
1
definition:
Video settings.
5.1.4.1.28.1.FlagInterlaced Element
id / type / default:
0x9A / uinteger / 0
path:
\Segment\Tracks\TrackEntry\Video\FlagInterlaced
minOccurs / maxOccurs:
1 / 1
minver:
2
definition:
Specifies whether the video frames in this track are interlaced.
restrictions:
SeeTable 3.
stream copy:
True (Section 8)
Table 3:FlagInterlaced Values
valuelabeldefinition
0undeterminedUnknown status. This valueSHOULD be avoided.
1interlacedInterlaced frames.
2progressiveNo interlacing.
5.1.4.1.28.2.FieldOrder Element
id / type / default:
0x9D / uinteger / 2
path:
\Segment\Tracks\TrackEntry\Video\FieldOrder
minOccurs / maxOccurs:
1 / 1
minver:
4
definition:
Specifies the field ordering of video frames in this track.
restrictions:
SeeTable 4.
usage notes:
IfFlagInterlaced is not set to 1, this elementMUST be ignored.
stream copy:
True (Section 8)
Table 4:FieldOrder Values
valuelabeldefinition
0progressiveInterlaced frames. This valueSHOULD be avoided; settingFlagInterlaced to 2 is sufficient.
1tffTop field displayed first. Top field stored first.
2undeterminedUnknown field order. This valueSHOULD be avoided.
6bffBottom field displayed first. Bottom field stored first.
9tff (interleaved)Top field displayed first. Fields are interleaved in storage with the top line of the top field stored first.
14bff (interleaved)Bottom field displayed first. Fields are interleaved in storage with the top line of the top field stored first.
5.1.4.1.28.3.StereoMode Element
id / type / default:
0x53B8 / uinteger / 0
path:
\Segment\Tracks\TrackEntry\Video\StereoMode
minOccurs / maxOccurs:
1 / 1
minver:
3
definition:
Stereo-3D video mode. SeeSection 18.10 for more details.
defined values:
SeeTable 5. Additional values can be registered in the "Matroska Stereo Modes" registry defined inSection 27.7.
stream copy:
True (Section 8)
Table 5:StereoMode Values
valuelabel
0mono
1side by side (left eye first)
2top - bottom (right eye is first)
3top - bottom (left eye is first)
4checkboard (right eye is first)
5checkboard (left eye is first)
6row interleaved (right eye is first)
7row interleaved (left eye is first)
8column interleaved (right eye is first)
9column interleaved (left eye is first)
10anaglyph (cyan/red)
11side by side (right eye first)
12anaglyph (green/magenta)
13both eyes laced in one Block (left eye is first)
14both eyes laced in one Block (right eye is first)
5.1.4.1.28.4.AlphaMode Element
id / type / default:
0x53C0 / uinteger / 0
path:
\Segment\Tracks\TrackEntry\Video\AlphaMode
minOccurs / maxOccurs:
1 / 1
minver:
3
definition:
Indicates whether theBlockAdditional element withBlockAddID of "1"contains Alpha data as defined by the Codec Mapping for theCodecID.Undefined values (i.e., values other than 0 or 1)SHOULD NOT be used, as thebehavior of known implementations is different.
defined values:
SeeTable 6. Additional values can be registered in the "Matroska Alpha Modes" registry defined inSection 27.8.
stream copy:
True (Section 8)
Table 6:AlphaMode Values
valuelabeldefinition
0noneTheBlockAdditional element withBlockAddID of "1" does not exist orSHOULD NOT be considered as containing such data.
1presentTheBlockAdditional element withBlockAddID of "1" contains alpha channel data.
5.1.4.1.28.5.OldStereoMode Element
id / type:
0x53B9 / uinteger
path:
\Segment\Tracks\TrackEntry\Video\OldStereoMode
maxOccurs:
1
maxver:
2
definition:
BogusStereoMode value used in old versions of[libmatroska].
restrictions:
SeeTable 7.
usage notes:
This elementMUST NOT be used. It was an incorrect value used in libmatroska up to 0.9.0.
Table 7:OldStereoMode Values
valuelabel
0mono
1right eye
2left eye
3both eyes
5.1.4.1.28.6.PixelWidth Element
id / type:
0xB0 / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Tracks\TrackEntry\Video\PixelWidth
minOccurs / maxOccurs:
1 / 1
definition:
Width of the encoded video frames in pixels.
stream copy:
True (Section 8)
5.1.4.1.28.7.PixelHeight Element
id / type:
0xBA / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Tracks\TrackEntry\Video\PixelHeight
minOccurs / maxOccurs:
1 / 1
definition:
Height of the encoded video frames in pixels.
stream copy:
True (Section 8)
5.1.4.1.28.8.PixelCropBottom Element
id / type / default:
0x54AA / uinteger / 0
path:
\Segment\Tracks\TrackEntry\Video\PixelCropBottom
minOccurs / maxOccurs:
1 / 1
definition:
The number of video pixels to remove at the bottom of the image.
stream copy:
True (Section 8)
5.1.4.1.28.9.PixelCropTop Element
id / type / default:
0x54BB / uinteger / 0
path:
\Segment\Tracks\TrackEntry\Video\PixelCropTop
minOccurs / maxOccurs:
1 / 1
definition:
The number of video pixels to remove at the top of the image.
stream copy:
True (Section 8)
5.1.4.1.28.10.PixelCropLeft Element
id / type / default:
0x54CC / uinteger / 0
path:
\Segment\Tracks\TrackEntry\Video\PixelCropLeft
minOccurs / maxOccurs:
1 / 1
definition:
The number of video pixels to remove on the left of the image.
stream copy:
True (Section 8)
5.1.4.1.28.11.PixelCropRight Element
id / type / default:
0x54DD / uinteger / 0
path:
\Segment\Tracks\TrackEntry\Video\PixelCropRight
minOccurs / maxOccurs:
1 / 1
definition:
The number of video pixels to remove on the right of the image.
stream copy:
True (Section 8)
5.1.4.1.28.12.DisplayWidth Element
id / type:
0x54B0 / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Tracks\TrackEntry\Video\DisplayWidth
maxOccurs:
1
definition:
Width of the video frames to display. Applies to the video frame after cropping (PixelCrop* Elements).
notes:
SeeTable 8.
stream copy:
True (Section 8)
Table 8:DisplayWidth Implementation Notes
attributenote
defaultIf the DisplayUnit of the sameTrackEntry is 0, then the default value forDisplayWidth is equal toPixelWidth -PixelCropLeft -PixelCropRight; else, there is no default value.
5.1.4.1.28.13.DisplayHeight Element
id / type:
0x54BA / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Tracks\TrackEntry\Video\DisplayHeight
maxOccurs:
1
definition:
Height of the video frames to display. Applies to the video frame after cropping (PixelCrop* Elements).
notes:
SeeTable 9.
stream copy:
True (Section 8)
Table 9:DisplayHeight Implementation Notes
attributenote
defaultIf the DisplayUnit of the sameTrackEntry is 0, then the default value forDisplayHeight is equal toPixelHeight -PixelCropTop -PixelCropBottom; else, there is no default value.
5.1.4.1.28.14.DisplayUnit Element
id / type / default:
0x54B2 / uinteger / 0
path:
\Segment\Tracks\TrackEntry\Video\DisplayUnit
minOccurs / maxOccurs:
1 / 1
definition:
HowDisplayWidth andDisplayHeight are interpreted.
defined values:
SeeTable 10. Additional values can be registered in the "Matroska Display Units" registry defined inSection 27.9.
Table 10:DisplayUnit Values
valuelabel
0pixels
1centimeters
2inches
3display aspect ratio
4unknown
5.1.4.1.28.15.UncompressedFourCC Element
id / type:
0x2EB524 / binary
length:
4
path:
\Segment\Tracks\TrackEntry\Video\UncompressedFourCC
minOccurs / maxOccurs:
SeeTable 11 / 1
definition:
Specifies the uncompressed pixel format used for theTrack's data as a FourCC.This value is similar in scope to the biCompression value of AVI'sBITMAPINFO[AVIFormat]. There is neither a definitive list of FourCC values nor an official registry. Some common values for YUV pixel formats can be found at[MSYUV8],[MSYUV16], and[FourCC-YUV]. Some common values for uncompressed RGB pixel formats can be found at[MSRGB] and[FourCC-RGB].
notes:
SeeTable 11.
stream copy:
True (Section 8)
Table 11:UncompressedFourCC Implementation Notes
attributenote
minOccursUncompressedFourCCMUST be set (minOccurs=1) inTrackEntry when theCodecID element of theTrackEntry is set to "V_UNCOMPRESSED".
5.1.4.1.28.16.Colour Element
id / type:
0x55B0 / master
path:
\Segment\Tracks\TrackEntry\Video\Colour
maxOccurs:
1
minver:
4
definition:
Settings describing the color format.
stream copy:
True (Section 8)
5.1.4.1.28.17.MatrixCoefficients Element
id / type / default:
0x55B1 / uinteger / 2
path:
\Segment\Tracks\TrackEntry\Video\Colour\MatrixCoefficients
minOccurs / maxOccurs:
1 / 1
minver:
4
definition:
The Matrix Coefficients of the video used to derive luma and chroma values from red, green, and blue color primaries.For clarity, the value and meanings forMatrixCoefficients are adopted from Table 4 of[ITU-H.273].
restrictions:
SeeTable 12.
stream copy:
True (Section 8)
Table 12:MatrixCoefficients Values
valuelabel
0Identity
1ITU-R BT.709
2unspecified
3reserved
4US FCC 73.682
5ITU-R BT.470BG
6SMPTE 170M
7SMPTE 240M
8YCoCg
9BT2020 Non-constant Luminance
10BT2020 Constant Luminance
11SMPTE ST 2085
12Chroma-derived Non-constant Luminance
13Chroma-derived Constant Luminance
14ITU-R BT.2100-0
5.1.4.1.28.18.BitsPerChannel Element
id / type / default:
0x55B2 / uinteger / 0
path:
\Segment\Tracks\TrackEntry\Video\Colour\BitsPerChannel
minOccurs / maxOccurs:
1 / 1
minver:
4
definition:
Number of decoded bits per channel. A value of 0 indicates that theBitsPerChannel is unspecified.
stream copy:
True (Section 8)
5.1.4.1.28.19.ChromaSubsamplingHorz Element
id / type:
0x55B3 / uinteger
path:
\Segment\Tracks\TrackEntry\Video\Colour\ChromaSubsamplingHorz
maxOccurs:
1
minver:
4
definition:
The number of pixels to remove in the Cr and Cb channels for every pixel not removed horizontally. Example: For video with 4:2:0 chroma subsampling, theChromaSubsamplingHorzSHOULD be set to 1.
stream copy:
True (Section 8)
5.1.4.1.28.20.ChromaSubsamplingVert Element
id / type:
0x55B4 / uinteger
path:
\Segment\Tracks\TrackEntry\Video\Colour\ChromaSubsamplingVert
maxOccurs:
1
minver:
4
definition:
The number of pixels to remove in the Cr and Cb channels for every pixel not removed vertically.Example: For video with 4:2:0 chroma subsampling, theChromaSubsamplingVertSHOULD be set to 1.
stream copy:
True (Section 8)
5.1.4.1.28.21.CbSubsamplingHorz Element
id / type:
0x55B5 / uinteger
path:
\Segment\Tracks\TrackEntry\Video\Colour\CbSubsamplingHorz
maxOccurs:
1
minver:
4
definition:
The number of pixels to remove in the Cb channel for every pixel not removed horizontally.This is additive withChromaSubsamplingHorz.Example: For video with 4:2:1 chromasubsampling, theChromaSubsamplingHorzSHOULD be set to 1, andCbSubsamplingHorzSHOULD be set to 1.
stream copy:
True (Section 8)
5.1.4.1.28.22.CbSubsamplingVert Element
id / type:
0x55B6 / uinteger
path:
\Segment\Tracks\TrackEntry\Video\Colour\CbSubsamplingVert
maxOccurs:
1
minver:
4
definition:
The number of pixels to remove in the Cb channel for every pixel not removed vertically.This is additive withChromaSubsamplingVert.
stream copy:
True (Section 8)
5.1.4.1.28.23.ChromaSitingHorz Element
id / type / default:
0x55B7 / uinteger / 0
path:
\Segment\Tracks\TrackEntry\Video\Colour\ChromaSitingHorz
minOccurs / maxOccurs:
1 / 1
minver:
4
definition:
How chroma is subsampled horizontally.
defined values:
SeeTable 13. Additional values can be registered in the "Matroska Horizontal Chroma Sitings" registry defined inSection 27.10.
stream copy:
True (Section 8)
Table 13:ChromaSitingHorz Values
valuelabel
0unspecified
1left collocated
2half
5.1.4.1.28.24.ChromaSitingVert Element
id / type / default:
0x55B8 / uinteger / 0
path:
\Segment\Tracks\TrackEntry\Video\Colour\ChromaSitingVert
minOccurs / maxOccurs:
1 / 1
minver:
4
definition:
How chroma is subsampled vertically.
defined values:
SeeTable 14. Additional values can be registered in the "Matroska Vertical Chroma Sitings" registry defined inSection 27.11.
stream copy:
True (Section 8)
Table 14:ChromaSitingVert Values
valuelabel
0unspecified
1top collocated
2half
5.1.4.1.28.25.Color Range Element
id / type / default:
0x55B9 / uinteger / 0
path:
\Segment\Tracks\TrackEntry\Video\Colour\Range
minOccurs / maxOccurs:
1 / 1
minver:
4
definition:
Clipping of the color ranges.
defined values:
SeeTable 15. Additional values can be registered in the "Matroska Color Ranges" registry defined inSection 27.12.
stream copy:
True (Section 8)
Table 15:Range Values
valuelabel
0unspecified
1broadcast range
2full range (no clipping)
3defined by MatrixCoefficients / TransferCharacteristics
5.1.4.1.28.26.TransferCharacteristics Element
id / type / default:
0x55BA / uinteger / 2
path:
\Segment\Tracks\TrackEntry\Video\Colour\TransferCharacteristics
minOccurs / maxOccurs:
1 / 1
minver:
4
definition:
The transfer characteristics of the video. For clarity,the value and meanings forTransferCharacteristics are adopted from Table 3 of[ITU-H.273].
restrictions:
SeeTable 16.
stream copy:
True (Section 8)
Table 16:TransferCharacteristics Values
valuelabel
0reserved
1ITU-R BT.709
2unspecified
3reserved2
4Gamma 2.2 curve - BT.470M
5Gamma 2.8 curve - BT.470BG
6SMPTE 170M
7SMPTE 240M
8Linear
9Log
10Log Sqrt
11IEC 61966-2-4
12ITU-R BT.1361 Extended Colour Gamut
13IEC 61966-2-1
14ITU-R BT.2020 10 bit
15ITU-R BT.2020 12 bit
16ITU-R BT.2100 Perceptual Quantization
17SMPTE ST 428-1
18ARIB STD-B67 (HLG)
5.1.4.1.28.27.Primaries Element
id / type / default:
0x55BB / uinteger / 2
path:
\Segment\Tracks\TrackEntry\Video\Colour\Primaries
minOccurs / maxOccurs:
1 / 1
minver:
4
definition:
The color primaries of the video. For clarity,the value and meanings forPrimaries are adopted from Table 2 of[ITU-H.273].
restrictions:
SeeTable 17.
stream copy:
True (Section 8)
Table 17:Primaries Values
valuelabel
0reserved
1ITU-R BT.709
2unspecified
3reserved2
4ITU-R BT.470M
5ITU-R BT.470BG - BT.601 625
6ITU-R BT.601 525 - SMPTE 170M
7SMPTE 240M
8FILM
9ITU-R BT.2020
10SMPTE ST 428-1
11SMPTE RP 432-2
12SMPTE EG 432-2
22EBU Tech. 3213-E - JEDEC P22 phosphors
5.1.4.1.28.28.MaxCLL Element
id / type:
0x55BC / uinteger
path:
\Segment\Tracks\TrackEntry\Video\Colour\MaxCLL
maxOccurs:
1
minver:
4
definition:
Maximum brightness of a single pixel (Maximum Content Light Level)in candelas per square meter (cd/m2).
stream copy:
True (Section 8)
5.1.4.1.28.29.MaxFALL Element
id / type:
0x55BD / uinteger
path:
\Segment\Tracks\TrackEntry\Video\Colour\MaxFALL
maxOccurs:
1
minver:
4
definition:
Maximum brightness of a single full frame (Maximum Frame-Average Light Level)in candelas per square meter (cd/m2).
stream copy:
True (Section 8)
5.1.4.1.28.30.MasteringMetadata Element
id / type:
0x55D0 / master
path:
\Segment\Tracks\TrackEntry\Video\Colour\MasteringMetadata
maxOccurs:
1
minver:
4
definition:
SMPTE 2086 mastering data.
stream copy:
True (Section 8)
5.1.4.1.28.31.PrimaryRChromaticityX Element
id / type:
0x55D1 / float
range:
0x0p+0-0x1p+0
path:
\Segment\Tracks\TrackEntry\Video\Colour\MasteringMetadata\PrimaryRChromaticityX
maxOccurs:
1
minver:
4
definition:
Red X chromaticity coordinate, as defined by[CIE-1931].
stream copy:
True (Section 8)
5.1.4.1.28.32.PrimaryRChromaticityY Element
id / type:
0x55D2 / float
range:
0x0p+0-0x1p+0
path:
\Segment\Tracks\TrackEntry\Video\Colour\MasteringMetadata\PrimaryRChromaticityY
maxOccurs:
1
minver:
4
definition:
Red Y chromaticity coordinate, as defined by[CIE-1931].
stream copy:
True (Section 8)
5.1.4.1.28.33.PrimaryGChromaticityX Element
id / type:
0x55D3 / float
range:
0x0p+0-0x1p+0
path:
\Segment\Tracks\TrackEntry\Video\Colour\MasteringMetadata\PrimaryGChromaticityX
maxOccurs:
1
minver:
4
definition:
Green X chromaticity coordinate, as defined by[CIE-1931].
stream copy:
True (Section 8)
5.1.4.1.28.34.PrimaryGChromaticityY Element
id / type:
0x55D4 / float
range:
0x0p+0-0x1p+0
path:
\Segment\Tracks\TrackEntry\Video\Colour\MasteringMetadata\PrimaryGChromaticityY
maxOccurs:
1
minver:
4
definition:
Green Y chromaticity coordinate, as defined by[CIE-1931].
stream copy:
True (Section 8)
5.1.4.1.28.35.PrimaryBChromaticityX Element
id / type:
0x55D5 / float
range:
0x0p+0-0x1p+0
path:
\Segment\Tracks\TrackEntry\Video\Colour\MasteringMetadata\PrimaryBChromaticityX
maxOccurs:
1
minver:
4
definition:
Blue X chromaticity coordinate, as defined by[CIE-1931].
stream copy:
True (Section 8)
5.1.4.1.28.36.PrimaryBChromaticityY Element
id / type:
0x55D6 / float
range:
0x0p+0-0x1p+0
path:
\Segment\Tracks\TrackEntry\Video\Colour\MasteringMetadata\PrimaryBChromaticityY
maxOccurs:
1
minver:
4
definition:
Blue Y chromaticity coordinate, as defined by[CIE-1931].
stream copy:
True (Section 8)
5.1.4.1.28.37.WhitePointChromaticityX Element
id / type:
0x55D7 / float
range:
0x0p+0-0x1p+0
path:
\Segment\Tracks\TrackEntry\Video\Colour\MasteringMetadata\WhitePointChromaticityX
maxOccurs:
1
minver:
4
definition:
White X chromaticity coordinate, as defined by[CIE-1931].
stream copy:
True (Section 8)
5.1.4.1.28.38.WhitePointChromaticityY Element
id / type:
0x55D8 / float
range:
0x0p+0-0x1p+0
path:
\Segment\Tracks\TrackEntry\Video\Colour\MasteringMetadata\WhitePointChromaticityY
maxOccurs:
1
minver:
4
definition:
White Y chromaticity coordinate, as defined by[CIE-1931].
stream copy:
True (Section 8)
5.1.4.1.28.39.LuminanceMax Element
id / type:
0x55D9 / float
range:
>= 0x0p+0
path:
\Segment\Tracks\TrackEntry\Video\Colour\MasteringMetadata\LuminanceMax
maxOccurs:
1
minver:
4
definition:
Maximum luminance. Represented in candelas per square meter (cd/m2).
stream copy:
True (Section 8)
5.1.4.1.28.40.LuminanceMin Element
id / type:
0x55DA / float
range:
>= 0x0p+0
path:
\Segment\Tracks\TrackEntry\Video\Colour\MasteringMetadata\LuminanceMin
maxOccurs:
1
minver:
4
definition:
Minimum luminance. Represented in candelas per square meter (cd/m2).
stream copy:
True (Section 8)
5.1.4.1.28.41.Projection Element
id / type:
0x7670 / master
path:
\Segment\Tracks\TrackEntry\Video\Projection
maxOccurs:
1
minver:
4
definition:
Describes the video projection details. Used to render spherical or VR videos or to flip videos horizontally or vertically.
stream copy:
True (Section 8)
5.1.4.1.28.42.ProjectionType Element
id / type / default:
0x7671 / uinteger / 0
path:
\Segment\Tracks\TrackEntry\Video\Projection\ProjectionType
minOccurs / maxOccurs:
1 / 1
minver:
4
definition:
Describes the projection used for this video track.
defined values:
SeeTable 18. Additional values can be registered in the "Matroska Projection Types" registry defined inSection 27.15.
stream copy:
True (Section 8)
Table 18:ProjectionType Values
valuelabel
0rectangular
1equirectangular
2cubemap
3mesh
5.1.4.1.28.43.ProjectionPrivate Element
id / type:
0x7672 / binary
path:
\Segment\Tracks\TrackEntry\Video\Projection\ProjectionPrivate
maxOccurs:
1
minver:
4
definition:
Private data that only applies to a specific projection.
  • IfProjectionType equals 0 (rectangular), then this elementMUST NOT be present.
  • IfProjectionType equals 1 (equirectangular), then this elementMUST be present and contain the same binary data that would be stored inside an ISOBMFF Equirectangular Projection Box ("equi").
  • IfProjectionType equals 2 (cubemap), then this elementMUST be present and contain the same binary data that would be stored inside an ISOBMFF Cubemap Projection Box ("cbmp").
  • IfProjectionType equals 3 (mesh), then this elementMUST be present and contain the same binary data that would be stored inside an ISOBMFF Mesh Projection Box ("mshp").
usage notes:
ISOBMFF box size and FourCC fields are not included in the binary data,but the FullBox version and flag fields are. This is to avoidredundant framing information while preserving versioning and semantics between the two container formats.
stream copy:
True (Section 8)
5.1.4.1.28.44.ProjectionPoseYaw Element
id / type / default:
0x7673 / float / 0x0p+0
range:
>= -0xB4p+0, <= 0xB4p+0
path:
\Segment\Tracks\TrackEntry\Video\Projection\ProjectionPoseYaw
minOccurs / maxOccurs:
1 / 1
minver:
4
definition:
Specifies a yaw rotation to the projection. Value represents a clockwise rotation, in degrees, around the up vector. This rotation must be appliedbefore anyProjectionPosePitch orProjectionPoseRoll rotations.The value of this elementMUST be in the -180 to 180 degree range, both inclusive.

SettingProjectionPoseYaw to 180 or -180 degrees withProjectionPoseRoll andProjectionPosePitch set to 0 degrees flips the image horizontally.

stream copy:
True (Section 8)
5.1.4.1.28.45.ProjectionPosePitch Element
id / type / default:
0x7674 / float / 0x0p+0
range:
>= -0x5Ap+0, <= 0x5Ap+0
path:
\Segment\Tracks\TrackEntry\Video\Projection\ProjectionPosePitch
minOccurs / maxOccurs:
1 / 1
minver:
4
definition:
Specifies a pitch rotation to the projection. Value represents a counter-clockwise rotation, in degrees, around the right vector. This rotation must be appliedafter theProjectionPoseYaw rotation and before theProjectionPoseRoll rotation.The value of this elementMUST be in the -90 to 90 degree range, both inclusive.
stream copy:
True (Section 8)
5.1.4.1.28.46.ProjectionPoseRoll Element
id / type / default:
0x7675 / float / 0x0p+0
range:
>= -0xB4p+0, <= 0xB4p+0
path:
\Segment\Tracks\TrackEntry\Video\Projection\ProjectionPoseRoll
minOccurs / maxOccurs:
1 / 1
minver:
4
definition:
Specifies a roll rotation to the projection. Value represents acounter-clockwise rotation, in degrees, around the forward vector. Thisrotation must be applied after theProjectionPoseYaw andProjectionPosePitch rotations. The value of this elementMUST be in the -180 to 180 degree range, both inclusive. SettingProjectionPoseRoll to 180 or -180 degrees andProjectionPoseYaw to 180 or -180 degrees withProjectionPosePitch set to 0 degrees flips the image vertically.SettingProjectionPoseRoll to 180 or -180 degrees withProjectionPoseYaw andProjectionPosePitch set to 0 degreesflips the image horizontally and vertically.
stream copy:
True (Section 8)
5.1.4.1.29.Audio Element
id / type:
0xE1 / master
path:
\Segment\Tracks\TrackEntry\Audio
maxOccurs:
1
definition:
Audio settings.
5.1.4.1.29.1.SamplingFrequency Element
id / type / default:
0xB5 / float / 0x1.f4p+12
range:
> 0x0p+0
path:
\Segment\Tracks\TrackEntry\Audio\SamplingFrequency
minOccurs / maxOccurs:
1 / 1
definition:
Sampling frequency in Hz.
stream copy:
True (Section 8)
5.1.4.1.29.2.OutputSamplingFrequency Element
id / type:
0x78B5 / float
range:
> 0x0p+0
path:
\Segment\Tracks\TrackEntry\Audio\OutputSamplingFrequency
maxOccurs:
1
definition:
Real output sampling frequency in Hz that is used for Spectral Band Replication (SBR) techniques.
notes:
SeeTable 19.
Table 19:OutputSamplingFrequency Implementation Notes
attributenote
defaultThe default value forOutputSamplingFrequency of the sameTrackEntry is equal to theSamplingFrequency.
5.1.4.1.29.3.Channels Element
id / type / default:
0x9F / uinteger / 1
range:
not 0 (1-18446744073709551615)
path:
\Segment\Tracks\TrackEntry\Audio\Channels
minOccurs / maxOccurs:
1 / 1
definition:
Numbers of channels in the track.
stream copy:
True (Section 8)
5.1.4.1.29.4.BitDepth Element
id / type:
0x6264 / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Tracks\TrackEntry\Audio\BitDepth
maxOccurs:
1
definition:
Bits per sample, mostly used for PCM.
stream copy:
True (Section 8)
5.1.4.1.30.TrackOperation Element
id / type:
0xE2 / master
path:
\Segment\Tracks\TrackEntry\TrackOperation
maxOccurs:
1
minver:
3
definition:
Operation that needs to be applied on tracks to create this virtual track. For more details, seeSection 18.8.
stream copy:
True (Section 8)
5.1.4.1.30.1.TrackCombinePlanes Element
id / type:
0xE3 / master
path:
\Segment\Tracks\TrackEntry\TrackOperation\TrackCombinePlanes
maxOccurs:
1
minver:
3
definition:
Contains the list of all video plane tracks that need to be combined to create this 3D track.
stream copy:
True (Section 8)
5.1.4.1.30.2.TrackPlane Element
id / type:
0xE4 / master
path:
\Segment\Tracks\TrackEntry\TrackOperation\TrackCombinePlanes\TrackPlane
minOccurs:
1
minver:
3
definition:
Contains a video plane track that needs to be combined to create this 3D track.
stream copy:
True (Section 8)
5.1.4.1.30.3.TrackPlaneUID Element
id / type:
0xE5 / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Tracks\TrackEntry\TrackOperation\TrackCombinePlanes\TrackPlane\TrackPlaneUID
minOccurs / maxOccurs:
1 / 1
minver:
3
definition:
TheTrackUID number of the track representing the plane.
stream copy:
True (Section 8)
5.1.4.1.30.4.TrackPlaneType Element
id / type:
0xE6 / uinteger
path:
\Segment\Tracks\TrackEntry\TrackOperation\TrackCombinePlanes\TrackPlane\TrackPlaneType
minOccurs / maxOccurs:
1 / 1
minver:
3
definition:
The kind of plane this track corresponds to.
defined values:
SeeTable 20. Additional values can be registered in the "Matroska Track Plane Types" registry defined inSection 27.17.
stream copy:
True (Section 8)
Table 20:TrackPlaneType Values
valuelabel
0left eye
1right eye
2background
5.1.4.1.30.5.TrackJoinBlocks Element
id / type:
0xE9 / master
path:
\Segment\Tracks\TrackEntry\TrackOperation\TrackJoinBlocks
maxOccurs:
1
minver:
3
definition:
Contains the list of all tracks whoseBlocks need to be combined to create this virtual track.
stream copy:
True (Section 8)
5.1.4.1.30.6.TrackJoinUID Element
id / type:
0xED / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Tracks\TrackEntry\TrackOperation\TrackJoinBlocks\TrackJoinUID
minOccurs:
1
minver:
3
definition:
TheTrackUID number of a track whose blocks are used to create this virtual track.
stream copy:
True (Section 8)
5.1.4.1.31.ContentEncodings Element
id / type:
0x6D80 / master
path:
\Segment\Tracks\TrackEntry\ContentEncodings
maxOccurs:
1
definition:
Settings for several content encoding mechanisms like compression or encryption.
stream copy:
True (Section 8)
5.1.4.1.31.1.ContentEncoding Element
id / type:
0x6240 / master
path:
\Segment\Tracks\TrackEntry\ContentEncodings\ContentEncoding
minOccurs:
1
definition:
Settings for one content encoding like compression or encryption.
stream copy:
True (Section 8)
5.1.4.1.31.2.ContentEncodingOrder Element
id / type / default:
0x5031 / uinteger / 0
path:
\Segment\Tracks\TrackEntry\ContentEncodings\ContentEncoding\ContentEncodingOrder
minOccurs / maxOccurs:
1 / 1
definition:
Defines the order to apply eachContentEncoding of theContentEncodings.The decoder/demuxerMUST start with theContentEncoding with the highestContentEncodingOrder and work its way down to theContentEncoding with the lowestContentEncodingOrder.This valueMUST be unique for eachContentEncoding found in theContentEncodings of thisTrackEntry.
stream copy:
True (Section 8)
5.1.4.1.31.3.ContentEncodingScope Element
id / type / default:
0x5032 / uinteger / 1
range:
not 0 (0x1-0x8000000000000000)
path:
\Segment\Tracks\TrackEntry\ContentEncodings\ContentEncoding\ContentEncodingScope
minOccurs / maxOccurs:
1 / 1
definition:
A bit field that describes which elements have been modified in this way. Values (big-endian) can be OR'ed.
defined values:
SeeTable 21. Additional values can be registered in the "Matroska Content Encoding Scopes" registry defined inSection 27.5.
stream copy:
True (Section 8)
Table 21:ContentEncodingScope Values
valuelabeldefinition
0x1BlockAll frame contents, excluding lacing data.
0x2PrivateThe track'sCodecPrivate data.
0x4NextThe next ContentEncoding (nextContentEncodingOrder; the data insideContentCompression and/orContentEncryption). This valueSHOULD NOT be used, as it's not supported by players.
5.1.4.1.31.4.ContentEncodingType Element
id / type / default:
0x5033 / uinteger / 0
path:
\Segment\Tracks\TrackEntry\ContentEncodings\ContentEncoding\ContentEncodingType
minOccurs / maxOccurs:
1 / 1
definition:
A value describing the kind of transformation that is applied.
defined values:
SeeTable 22. Additional values can be registered in the "Matroska Content Encoding Types" registry defined inSection 27.6.
stream copy:
True (Section 8)
Table 22:ContentEncodingType Values
valuelabel
0Compression
1Encryption
5.1.4.1.31.5.ContentCompression Element
id / type:
0x5034 / master
path:
\Segment\Tracks\TrackEntry\ContentEncodings\ContentEncoding\ContentCompression
maxOccurs:
1
definition:
Settings describing the compression used.This elementMUST be present if the value ofContentEncodingType is 0 and absent otherwise.Each blockMUST be decompressable, even if no previous block is available in order to not prevent seeking.
stream copy:
True (Section 8)
5.1.4.1.31.6.ContentCompAlgo Element
id / type / default:
0x4254 / uinteger / 0
path:
\Segment\Tracks\TrackEntry\ContentEncodings\ContentEncoding\ContentCompression\ContentCompAlgo
minOccurs / maxOccurs:
1 / 1
definition:
The compression algorithm used.
defined values:
SeeTable 23. Additional values can be registered in the "Matroska Compression Algorithms" registry defined inSection 27.2.
usage notes:
Compression method "1" (bzlib) and "2" (lzo1x) lack proper documentation on the format, which limits implementation possibilities. Due to licensing conflicts on commonly available libraries' compression methods, "2" (lzo1x) does not offer widespread interoperability. AMatroska WriterSHOULD NOT use these compression methods by default. AMatroska ReaderMAY support methods "1" and "2" andSHOULD support other methods.
stream copy:
True (Section 8)
Table 23:ContentCompAlgo Values
valuelabeldefinition
0zlibzlib compression[RFC1950].
1bzlibbzip2 compression[BZIP2]SHOULD NOT be used; see usage notes.
2lzo1xLempel-Ziv-Oberhumer compression[LZO]SHOULD NOT be used; see usage notes.
3Header StrippingOctets inContentCompSettings (Section 5.1.4.1.31.7) have been stripped from each frame.
5.1.4.1.31.7.ContentCompSettings Element
id / type:
0x4255 / binary
path:
\Segment\Tracks\TrackEntry\ContentEncodings\ContentEncoding\ContentCompression\ContentCompSettings
maxOccurs:
1
definition:
Settings that might be needed by the decompressor. For Header Stripping (ContentCompAlgo=3),the bytes that were removed from the beginning of each frame of the track.
stream copy:
True (Section 8)
5.1.4.1.31.8.ContentEncryption Element
id / type:
0x5035 / master
path:
\Segment\Tracks\TrackEntry\ContentEncodings\ContentEncoding\ContentEncryption
maxOccurs:
1
definition:
Settings describing the encryption used.This elementMUST be present if the value ofContentEncodingType is 1 (encryption) andMUST be ignored otherwise.AMatroska PlayerMAY support encryption.
stream copy:
True (Section 8)
5.1.4.1.31.9.ContentEncAlgo Element
id / type / default:
0x47E1 / uinteger / 0
path:
\Segment\Tracks\TrackEntry\ContentEncodings\ContentEncoding\ContentEncryption\ContentEncAlgo
minOccurs / maxOccurs:
1 / 1
definition:
The encryption algorithm used.
defined values:
SeeTable 24. Additional values can be registered in the "Matroska Encryption Algorithms" registry defined inSection 27.3.
stream copy:
True (Section 8)
Table 24:ContentEncAlgo Values
valuelabeldefinition
0Not encryptedThe data are not encrypted.
1DESData Encryption Standard (DES)[FIPS46-3]. This valueSHOULD be avoided.
23DESTriple Data Encryption Algorithm[SP800-67]. This valueSHOULD be avoided.
3TwofishTwofish Encryption Algorithm[Twofish].
4BlowfishBlowfish Encryption Algorithm[Blowfish]. This valueSHOULD be avoided.
5AESAdvanced Encryption Standard (AES)[FIPS197].
5.1.4.1.31.10.ContentEncKeyID Element
id / type:
0x47E2 / binary
path:
\Segment\Tracks\TrackEntry\ContentEncodings\ContentEncoding\ContentEncryption\ContentEncKeyID
maxOccurs:
1
definition:
For public key algorithms, the ID of the public key that the data was encrypted with.
stream copy:
True (Section 8)
5.1.4.1.31.11.ContentEncAESSettings Element
id / type:
0x47E7 / master
path:
\Segment\Tracks\TrackEntry\ContentEncodings\ContentEncoding\ContentEncryption\ContentEncAESSettings
maxOccurs:
1
minver:
4
definition:
Settings describing the encryption algorithm used.
notes:
SeeTable 25.
stream copy:
True (Section 8)
Table 25:ContentEncAESSettings Implementation Notes
attributenote
maxOccursContentEncAESSettingsMUST NOT be set (maxOccurs=0) if ContentEncAlgo is not AES (5).
5.1.4.1.31.12.AESSettingsCipherMode Element
id / type:
0x47E8 / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Tracks\TrackEntry\ContentEncodings\ContentEncoding\ContentEncryption\ContentEncAESSettings\AESSettingsCipherMode
minOccurs / maxOccurs:
1 / 1
minver:
4
definition:
The AES cipher mode used in the encryption.
defined values:
SeeTable 26. Additional values can be registered in the "Matroska AES Cipher Modes" registry defined inSection 27.4.
notes:
SeeTable 27.
stream copy:
True (Section 8)
Table 26:AESSettingsCipherMode Values
valuelabeldefinition
1AES-CTRCounter[SP800-38A]
2AES-CBCCipher Block Chaining[SP800-38A]
Table 27:AESSettingsCipherMode Implementation Notes
attributenote
maxOccursAESSettingsCipherModeMUST NOT be set (maxOccurs=0) if ContentEncAlgo is not AES (5).

5.1.5.Cues Element

id / type:
0x1C53BB6B / master
path:
\Segment\Cues
minOccurs / maxOccurs:
SeeTable 28 / 1
definition:
ATop-Level Element to speed seeking access. All entries arelocal to theSegment.
notes:
SeeTable 28.
Table 28:Cues Implementation Notes
attributenote
minOccursThis elementSHOULD be set when theSegment is not transmitted as a live stream; seeSection 23.2.
5.1.5.1.CuePoint Element
id / type:
0xBB / master
path:
\Segment\Cues\CuePoint
minOccurs:
1
definition:
Contains all information relative to a seek point in theSegment.
5.1.5.1.1.CueTime Element
id / type:
0xB3 / uinteger
path:
\Segment\Cues\CuePoint\CueTime
minOccurs / maxOccurs:
1 / 1
definition:
Absolute timestamp of the seek point, expressed in Segment Ticks, which are based onTimestampScale; seeSection 11.1.
5.1.5.1.2.CueTrackPositions Element
id / type:
0xB7 / master
path:
\Segment\Cues\CuePoint\CueTrackPositions
minOccurs:
1
definition:
Contains positions for different tracks corresponding to the timestamp.
5.1.5.1.2.1.CueTrack Element
id / type:
0xF7 / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Cues\CuePoint\CueTrackPositions\CueTrack
minOccurs / maxOccurs:
1 / 1
definition:
The track for which a position is given.
5.1.5.1.2.2.CueClusterPosition Element
id / type:
0xF1 / uinteger
path:
\Segment\Cues\CuePoint\CueTrackPositions\CueClusterPosition
minOccurs / maxOccurs:
1 / 1
definition:
TheSegment Position (Section 16) of theCluster containing the associatedBlock.
5.1.5.1.2.3.CueRelativePosition Element
id / type:
0xF0 / uinteger
path:
\Segment\Cues\CuePoint\CueTrackPositions\CueRelativePosition
maxOccurs:
1
minver:
4
definition:
The relative position inside theCluster of the referencedSimpleBlock orBlockGroupwith 0 being the first possible position for an element inside thatCluster.
5.1.5.1.2.4.CueDuration Element
id / type:
0xB2 / uinteger
path:
\Segment\Cues\CuePoint\CueTrackPositions\CueDuration
maxOccurs:
1
minver:
4
definition:
The duration of the block, expressed in Segment Ticks, which are based onTimestampScale; seeSection 11.1.If missing, the track'sDefaultDuration does not apply and no duration information is available in terms of the cues.
5.1.5.1.2.5.CueBlockNumber Element
id / type:
0x5378 / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Cues\CuePoint\CueTrackPositions\CueBlockNumber
maxOccurs:
1
definition:
Number of theBlock in the specifiedCluster.
5.1.5.1.2.6.CueCodecState Element
id / type / default:
0xEA / uinteger / 0
path:
\Segment\Cues\CuePoint\CueTrackPositions\CueCodecState
minOccurs / maxOccurs:
1 / 1
minver:
2
definition:
TheSegment Position (Section 16) of theCodec State corresponding to thisCues element. 0 means that thedata is taken from the initialTrackEntry.
5.1.5.1.2.7.CueReference Element
id / type:
0xDB / master
path:
\Segment\Cues\CuePoint\CueTrackPositions\CueReference
minver:
2
definition:
TheClusters containing the referencedBlocks.
5.1.5.1.2.8.CueRefTime Element
id / type:
0x96 / uinteger
path:
\Segment\Cues\CuePoint\CueTrackPositions\CueReference\CueRefTime
minOccurs / maxOccurs:
1 / 1
minver:
2
definition:
Timestamp of the referencedBlock, expressed in Segment Ticks which is based onTimestampScale; seeSection 11.1.

5.1.6.Attachments Element

id / type:
0x1941A469 / master
path:
\Segment\Attachments
maxOccurs:
1
definition:
Contains attached files.
5.1.6.1.AttachedFile Element
id / type:
0x61A7 / master
path:
\Segment\Attachments\AttachedFile
minOccurs:
1
definition:
An attached file.
5.1.6.1.1.FileDescription Element
id / type:
0x467E / utf-8
path:
\Segment\Attachments\AttachedFile\FileDescription
maxOccurs:
1
definition:
A human-friendly name for the attached file.
5.1.6.1.2.FileName Element
id / type:
0x466E / utf-8
path:
\Segment\Attachments\AttachedFile\FileName
minOccurs / maxOccurs:
1 / 1
definition:
Filename of the attached file.
5.1.6.1.3.FileMediaType Element
id / type:
0x4660 / string
path:
\Segment\Attachments\AttachedFile\FileMediaType
minOccurs / maxOccurs:
1 / 1
definition:
Media type of the file following the format described in[RFC6838].
stream copy:
True (Section 8)
5.1.6.1.4.FileData Element
id / type:
0x465C / binary
path:
\Segment\Attachments\AttachedFile\FileData
minOccurs / maxOccurs:
1 / 1
definition:
The data of the file.
stream copy:
True (Section 8)
5.1.6.1.5.FileUID Element
id / type:
0x46AE / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Attachments\AttachedFile\FileUID
minOccurs / maxOccurs:
1 / 1
definition:
UID representing the file, as random as possible.
stream copy:
True (Section 8)

5.1.7.Chapters Element

id / type:
0x1043A770 / master
path:
\Segment\Chapters
maxOccurs:
1
recurring:
True
definition:
A system to define basic menus and partition data.For more detailed information, seeSection 20.
5.1.7.1.EditionEntry Element
id / type:
0x45B9 / master
path:
\Segment\Chapters\EditionEntry
minOccurs:
1
definition:
Contains all information about aSegment edition.
5.1.7.1.1.EditionUID Element
id / type:
0x45BC / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Chapters\EditionEntry\EditionUID
maxOccurs:
1
definition:
A UID that identifies the edition. It's useful for tagging an edition.
stream copy:
True (Section 8)
5.1.7.1.2.EditionFlagDefault Element
id / type / default:
0x45DB / uinteger / 0
range:
0-1
path:
\Segment\Chapters\EditionEntry\EditionFlagDefault
minOccurs / maxOccurs:
1 / 1
definition:
Set to 1 if the editionSHOULD be used as the default one.
5.1.7.1.3.EditionFlagOrdered Element
id / type / default:
0x45DD / uinteger / 0
range:
0-1
path:
\Segment\Chapters\EditionEntry\EditionFlagOrdered
minOccurs / maxOccurs:
1 / 1
definition:
Set to 1 if the chapters can be defined multiple times and the order to play them is enforced; seeSection 20.1.3.
5.1.7.1.4.ChapterAtom Element
id / type:
0xB6 / master
path:
\Segment\Chapters\EditionEntry\+ChapterAtom
minOccurs:
1
recursive:
True
definition:
Contains the atom information to use as the chapter atom (applies to all tracks).
5.1.7.1.4.1.ChapterUID Element
id / type:
0x73C4 / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapterUID
minOccurs / maxOccurs:
1 / 1
definition:
A UID that identifies theChapter.
stream copy:
True (Section 8)
5.1.7.1.4.2.ChapterStringUID Element
id / type:
0x5654 / utf-8
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapterStringUID
maxOccurs:
1
minver:
3
definition:
A unique string ID that identifies theChapter.For example, it is used as the storage for cue identifier values[WebVTT].
5.1.7.1.4.3.ChapterTimeStart Element
id / type:
0x91 / uinteger
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapterTimeStart
minOccurs / maxOccurs:
1 / 1
definition:
Timestamp of the start ofChapter, expressed in Matroska Ticks -- i.e., in nanoseconds; seeSection 11.1.
5.1.7.1.4.4.ChapterTimeEnd Element
id / type:
0x92 / uinteger
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapterTimeEnd
minOccurs / maxOccurs:
SeeTable 29 / 1
definition:
Timestamp of the end ofChapter (timestamp excluded), expressed in Matroska Ticks -- i.e., in nanoseconds; seeSection 11.1.The valueMUST be greater than or equal to theChapterTimeStart of the sameChapterAtom.
usage notes:
With theChapterTimeEnd timestamp value being excluded, itMUST take into account the duration ofthe last frame it includes, especially for theChapterAtom using the last frames of theSegment.
notes:
SeeTable 29.
Table 29:ChapterTimeEnd Implementation Notes
attributenote
minOccursChapterTimeEndMUST be set (minOccurs=1) if theEdition is an ordered edition; seeSection 20.1.3. If it's aParent Chapter, seeSection 20.2.3.
5.1.7.1.4.5.ChapterFlagHidden Element
id / type / default:
0x98 / uinteger / 0
range:
0-1
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapterFlagHidden
minOccurs / maxOccurs:
1 / 1
definition:
Set to 1 if a chapter is hidden.Hidden chaptersSHOULD NOT be available to the user interface(but still be available to Control Tracks; seeSection 20.2.5 onChapter flags).
5.1.7.1.4.6.ChapterSegmentUUID Element
id / type:
0x6E67 / binary
length:
16
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapterSegmentUUID
minOccurs / maxOccurs:
SeeTable 30 / 1
definition:
TheSegmentUUID of anotherSegment to play during this chapter.
usage notes:
The valueMUST NOT be theSegmentUUID value of theSegment it belongs to.
notes:
SeeTable 30.
Table 30:ChapterSegmentUUID Implementation Notes
attributenote
minOccursChapterSegmentUUIDMUST be set (minOccurs=1) ifChapterSegmentEditionUID is used; seeSection 17.2 on Medium-LinkingSegments.
5.1.7.1.4.7.ChapterSegmentEditionUID Element
id / type:
0x6EBC / uinteger
range:
not 0 (1-18446744073709551615)
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapterSegmentEditionUID
maxOccurs:
1
definition:
TheEditionUID to play from theSegment linked inChapterSegmentUUID.IfChapterSegmentEditionUID is undeclared, then noEdition of theLinked Segment is used; seeSection 17.2 on Medium-LinkingSegments.
5.1.7.1.4.8.ChapterPhysicalEquiv Element
id / type:
0x63C3 / uinteger
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapterPhysicalEquiv
maxOccurs:
1
definition:
Specifies the physical equivalent of thisChapterAtom, e.g., "DVD" (60) or "SIDE" (50);seeSection 20.4 for a complete list of values.
5.1.7.1.4.9.ChapterDisplay Element
id / type:
0x80 / master
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapterDisplay
definition:
Contains all possible strings to use for the chapter display.
5.1.7.1.4.10.ChapString Element
id / type:
0x85 / utf-8
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapterDisplay\ChapString
minOccurs / maxOccurs:
1 / 1
definition:
Contains the string to use as the chapter atom.
5.1.7.1.4.11.ChapLanguage Element
id / type / default:
0x437C / string / eng
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapterDisplay\ChapLanguage
minOccurs:
1
definition:
A language corresponding to the string,in the Matroska languages form; seeSection 12 on language codes.This elementMUST be ignored if aChapLanguageBCP47 element is used within the sameChapterDisplay element.
5.1.7.1.4.12.ChapLanguageBCP47 Element
id / type:
0x437D / string
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapterDisplay\ChapLanguageBCP47
minver:
4
definition:
A language corresponding to theChapString,in the form defined in[RFC5646]; seeSection 12 on language codes.If aChapLanguageBCP47 element is used, then anyChapLanguage andChapCountry elements used in the sameChapterDisplayMUST be ignored.
5.1.7.1.4.13.ChapCountry Element
id / type:
0x437E / string
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapterDisplay\ChapCountry
definition:
A country corresponding to the string,in the Matroska countries form; seeSection 13 on country codes.This elementMUST be ignored if aChapLanguageBCP47 element is used within the sameChapterDisplay element.
5.1.7.1.4.14.ChapProcess Element
id / type:
0x6944 / master
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapProcess
definition:
Contains all the commands associated with the Atom.
5.1.7.1.4.15.ChapProcessCodecID Element
id / type / default:
0x6955 / uinteger / 0
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapProcess\ChapProcessCodecID
minOccurs / maxOccurs:
1 / 1
definition:
Contains the type of the codec used for processing.
defined values:
SeeTable 31. Additional values can be registered in the "Matroska Chapter Codec IDs" registry defined inSection 27.14.
Table 31:ChapProcessCodecID Values
valuelabeldefinition
0Matroska ScriptChapter commands using the Matroska Script codec.
1DVD-menuChapter commands using the DVD-like codec.
5.1.7.1.4.16.ChapProcessPrivate Element
id / type:
0x450D / binary
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapProcess\ChapProcessPrivate
maxOccurs:
1
definition:
Optional data attached to theChapProcessCodecID information.ForChapProcessCodecID = 1, it is the "DVD level" equivalent; seeSection 20.3 on DVD menus.
5.1.7.1.4.17.ChapProcessCommand Element
id / type:
0x6911 / master
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapProcess\ChapProcessCommand
definition:
Contains all the commands associated with the Atom.
5.1.7.1.4.18.ChapProcessTime Element
id / type:
0x6922 / uinteger
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapProcess\ChapProcessCommand\ChapProcessTime
minOccurs / maxOccurs:
1 / 1
definition:
Defines when the process commandSHOULD be handled.
restrictions:
SeeTable 32.
Table 32:ChapProcessTime Values
valuelabel
0during the whole chapter
1before starting playback
2after playback of the chapter
5.1.7.1.4.19.ChapProcessData Element
id / type:
0x6933 / binary
path:
\Segment\Chapters\EditionEntry\+ChapterAtom\ChapProcess\ChapProcessCommand\ChapProcessData
minOccurs / maxOccurs:
1 / 1
definition:
Contains the command information.The dataSHOULD be interpreted depending on theChapProcessCodecID value. ForChapProcessCodecID = 1,the data correspond to the binary DVD cell pre/post commands; seeSection 20.3 on DVD menus.

5.1.8.Tags Element

id / type:
0x1254C367 / master
path:
\Segment\Tags
definition:
Element containing metadata describingTracks,Editions,Chapters,Attachments, or theSegment as a whole.A list of valid tags can be found in[MatroskaTags].
5.1.8.1.Tag Element
id / type:
0x7373 / master
path:
\Segment\Tags\Tag
minOccurs:
1
definition:
A single metadata descriptor.
5.1.8.1.1.Targets Element
id / type:
0x63C0 / master
path:
\Segment\Tags\Tag\Targets
minOccurs / maxOccurs:
1 / 1
definition:
Specifies which other elements the metadata represented by the tag value applies to.If empty or omitted, then the tag value describes everything in theSegment.
5.1.8.1.1.1.TargetTypeValue Element
id / type / default:
0x68CA / uinteger / 50
range:
not 0 (1-18446744073709551615)
path:
\Segment\Tags\Tag\Targets\TargetTypeValue
minOccurs / maxOccurs:
1 / 1
definition:
A number to indicate the logical level of the target.
defined values:
SeeTable 33. Additional values can be registered in the "Matroska Tags Target Types" registry defined inSection 27.13.
usage notes:
TheTargetTypeValue values are meant to be compared.Higher valuesMUST correspond to a logical level that contains the lower logical levelTargetTypeValue values.
Table 33:TargetTypeValue Values
valuelabeldefinition
70COLLECTIONThe highest hierarchical level that tags can describe.
60EDITION / ISSUE / VOLUME / OPUS / SEASON / SEQUELA list of lower levels grouped together.
50ALBUM / OPERA / CONCERT / MOVIE / EPISODEThe most common grouping level of music and video (e.g., an episode for TV series).
40PART / SESSIONWhen an album or episode has different logical parts.
30TRACK / SONG / CHAPTERThe common parts of an album or movie.
20SUBTRACK / MOVEMENT / SCENECorresponds to parts of a track for audio, such as a movement or scene in a movie.
10SHOTThe lowest hierarchy found in music or movies.
5.1.8.1.1.2.TargetType Element
id / type:
0x63CA / string
path:
\Segment\Tags\Tag\Targets\TargetType
maxOccurs:
1
definition:
An informational string that can be used to display the logical level of the target, such as "ALBUM", "TRACK", "MOVIE", "CHAPTER", etc.
restrictions:
SeeTable 34.
Table 34:TargetType Values
valuelabel
COLLECTIONTargetTypeValue 70
EDITIONTargetTypeValue 60
ISSUETargetTypeValue 60
VOLUMETargetTypeValue 60
OPUSTargetTypeValue 60
SEASONTargetTypeValue 60
SEQUELTargetTypeValue 60
ALBUMTargetTypeValue 50
OPERATargetTypeValue 50
CONCERTTargetTypeValue 50
MOVIETargetTypeValue 50
EPISODETargetTypeValue 50
PARTTargetTypeValue 40
SESSIONTargetTypeValue 40
TRACKTargetTypeValue 30
SONGTargetTypeValue 30
CHAPTERTargetTypeValue 30
SUBTRACKTargetTypeValue 20
MOVEMENTTargetTypeValue 20
SCENETargetTypeValue 20
SHOTTargetTypeValue 10
5.1.8.1.1.3.TagTrackUID Element
id / type / default:
0x63C5 / uinteger / 0
path:
\Segment\Tags\Tag\Targets\TagTrackUID
definition:
A UID that identifies theTrack(s) that the tags belong to.
usage notes:
If the value is 0 at this level, the tags apply to all tracks in theSegment.If set to any other value, itMUST match theTrackUID value of a track found in thisSegment.
5.1.8.1.1.4.TagEditionUID Element
id / type / default:
0x63C9 / uinteger / 0
path:
\Segment\Tags\Tag\Targets\TagEditionUID
definition:
A UID that identifies theEditionEntry(s) that the tags belong to.
usage notes:
If the value is 0 at this level, the tags apply to all editions in theSegment.If set to any other value, itMUST match theEditionUID value of an edition found in thisSegment.
5.1.8.1.1.5.TagChapterUID Element
id / type / default:
0x63C4 / uinteger / 0
path:
\Segment\Tags\Tag\Targets\TagChapterUID
definition:
A UID that identifies theChapter(s) that the tags belong to.
usage notes:
If the value is 0 at this level, the tags apply to all chapters in theSegment.If set to any other value, itMUST match theChapterUID value of a chapter found in thisSegment.
5.1.8.1.1.6.TagAttachmentUID Element
id / type / default:
0x63C6 / uinteger / 0
path:
\Segment\Tags\Tag\Targets\TagAttachmentUID
definition:
A UID that identifies the Attachment(s) that the tags belong to.
usage notes:
If the value is 0 at this level, the tags apply to all the attachments intheSegment. If set to any other value, itMUST matchtheFileUID value of an attachment found in thisSegment.
5.1.8.1.2.SimpleTag Element
id / type:
0x67C8 / master
path:
\Segment\Tags\Tag\+SimpleTag
minOccurs:
1
recursive:
True
definition:
Contains general information about the target.
5.1.8.1.2.1.TagName Element
id / type:
0x45A3 / utf-8
path:
\Segment\Tags\Tag\+SimpleTag\TagName
minOccurs / maxOccurs:
1 / 1
definition:
The name of the tag value that is going to be stored.
5.1.8.1.2.2.TagLanguage Element
id / type / default:
0x447A / string / und
path:
\Segment\Tags\Tag\+SimpleTag\TagLanguage
minOccurs / maxOccurs:
1 / 1
definition:
Specifies the language of the specified tag in the Matroska languages form; seeSection 12 on language codes.This elementMUST be ignored if theTagLanguageBCP47 element is used within the sameSimpleTag element.
5.1.8.1.2.3.TagLanguageBCP47 Element
id / type:
0x447B / string
path:
\Segment\Tags\Tag\+SimpleTag\TagLanguageBCP47
maxOccurs:
1
minver:
4
definition:
The language used in theTagString,in the form defined in[RFC5646]; seeSection 12 on language codes.If this element is used, then anyTagLanguage elements used in the sameSimpleTagMUST be ignored.
5.1.8.1.2.4.TagDefault Element
id / type / default:
0x4484 / uinteger / 1
range:
0-1
path:
\Segment\Tags\Tag\+SimpleTag\TagDefault
minOccurs / maxOccurs:
1 / 1
definition:
A boolean value to indicate if this is the default/original language to use for the given tag.
5.1.8.1.2.5.TagString Element
id / type:
0x4487 / utf-8
path:
\Segment\Tags\Tag\+SimpleTag\TagString
maxOccurs:
1
definition:
The tag value.
5.1.8.1.2.6.TagBinary Element
id / type:
0x4485 / binary
path:
\Segment\Tags\Tag\+SimpleTag\TagBinary
maxOccurs:
1
definition:
The tag value if it is binary. Note that this cannot be used in the sameSimpleTag asTagString.

6.Matroska Element Ordering

With the exceptions of theEBML Header and theCRC-32element, the EBML specification[RFC8794] does not require anyparticular storage order for elements. However, this specification definesmandates and recommendations for ordering certain elements to facilitatebetter playback, seeking, and editing efficiency. This section describes andoffers rationale for ordering requirements and recommendations forMatroska.

6.1.Top-Level Elements

TheInfo element is the onlyREQUIREDTop-Level Element in a Matroska file.To be playable, MatroskaMUST also contain at least oneTracks element andCluster element.The firstInfo element and the firstTracks element eitherMUST be stored before the firstCluster element orSHALL both be referenced by aSeekHead element occurring before the firstCluster element.

AllTop-Level ElementsMUST use a 4-octet EBML Element ID.

When using Medium Linking, chapters are used to reference otherSegments to play in a given order (seeSection 17.2).ASegment containing theseLinked Chapters does not require aTracks element or aCluster element.

It is possible to edit a Matroska file after it has been created. Forexample, chapters, tags, or attachments can be added. When newTop-LevelElements are added to a Matroska file, theSeekHead element(s)MUST be updated so that theSeekHead element(s)itemizes the identity and position of allTop-Level Elements.

Editing, removing, or adding elements to a Matroska file often requiresthat some existing elements be voided or extended. Transforming the existingelements intoVoid elements as padding can be used as a method toavoid moving large amounts of data around.

6.2.CRC-32

As noted by the EBML specification[RFC8794], if aCRC-32 element is used, then theCRC-32 elementMUST be the first ordered element within itsParent Element.

In Matroska, allTop-Level Elements of an EBML DocumentSHOULD include aCRC-32 elementas their firstChild Element.TheSegment element, which is theRoot Element,SHOULD NOT have aCRC-32 element.

6.3.SeekHead

If used, the firstSeekHead elementMUST be the first non-CRC-32 Child elementof theSegment element. If a secondSeekHead element is used, then the firstSeekHead elementMUST reference the identity and position of the secondSeekHead element.

Additionally, the secondSeekHead elementMUST only referenceCluster elementsand not any otherTop-Level Element already contained within the firstSeekHead element.

The secondSeekHead elementMAY be stored in any order relative to the otherTop-Level Elements.Whether one or twoSeekHead elements are used, theSeekHead element(s)MUSTcollectively reference the identity and position of allTop-Level Elements exceptfor the firstSeekHead element.

6.4.Cues (Index)

TheCues element isRECOMMENDED to optimize seeking access in Matroska. It isprogrammatically simpler to add theCues element after allCluster elementshave been written because this does not require a prediction of how much space toreserve before writing theCluster elements. However, storing theCues elementbefore theCluster elements can provide some seeking advantages. If theCues elementis present, then itSHOULD either be stored before the firstCluster elementor be referenced by aSeekHead element.

6.5.Info

The firstInfo elementSHOULD occur before the firstTracks element and firstCluster element except when referenced by aSeekHead element.

6.6.Chapters Element

TheChapters elementSHOULD be placed before theCluster element(s). TheChapters element can be used during playback even if the user does not need to seek.It immediately gives the user information about what section is being read and whatother sections are available.

In the case ofOrdered Chapters, it isRECOMMENDED to evaluatethe logical linking before playing. TheChapters elementSHOULD be placed beforethe firstTracks element and after the firstInfo element.

6.7.Attachments

TheAttachments element is not intended to be used by default when playing the filebut could contain information relevant to the content, such as cover art or fonts.Cover art is useful even before the file is played, and fonts could be needed before playbackstarts for the initialization of subtitles. TheAttachments elementMAY be placed beforethe firstCluster element; however, if theAttachments element is likely to be edited,then itSHOULD be placed after the lastCluster element.

6.8.Tags

TheTags element is most subject to changes after the file was originally created.For easier editing, theTags element can be placed at the end of theSegment element,even after theAttachments element. On the other hand, it is inconvenient to have toseek in theSegment for tags, especially for network streams; thus, it's better if theTags element is found early in the stream. When editing theTags element, the originalTags element at the beginning can be overwritten with aVoid element and anewTags element written at the end of theSegment element. The file andSegment sizes will only marginally change.

7.Matroska Versioning

Matroska is based on the principle that a reading application does not have to support100% of the specifications in order to be able to play the file. Therefore, a Matroska file contains version indicators that tell a reading application what to expect.

It is possible and valid to have the version fields indicate that the filecontains Matroska elements from a higher specification version number whilesignaling that a reading applicationMUST only support a lowerversion number properly in order to play it back (possibly with a reducedfeature set).

TheEBML Header of each Matroska document informs the readingapplication on what version of Matroska to expect. The elements within theEBML Header with jurisdiction over this information areDocTypeVersion andDocTypeReadVersion.

DocTypeVersionMUST be equal to or greater than the highest Matroska version number ofany element present in the Matroska file. For example, a file using theSimpleBlock element (Section 5.1.3.4)MUST have aDocTypeVersion equal to or greater than 2. A file containingCueRelativePositionelements (Section 5.1.5.1.2.3)MUST have aDocTypeVersion equal to or greater than 4.

TheDocTypeReadVersionMUST contain the minimumversion number that a reading application can minimally support in order toplay the file back -- optionally with a reduced feature set. For example, if afile contains only elements of version 2 or lower except forCueRelativePosition (which is a version 4 Matroska element), thenDocTypeReadVersionSHOULD still be set to 2 and not 4because evaluatingCueRelativePosition is not necessary for standardplayback -- it makes seeking more precise if used.

A reading application supporting Matroska versionVMUST NOT refuse to read afile withDocReadTypeVersion equal to or lower thanV, even ifDocTypeVersionis greater thanV.

A reading application supporting at least Matroska versionV andreading a file whoseDocTypeReadVersion field is equal to or lowerthanVMUST skip Matroska/EBML elements it encountersbut does not know about if that unknown element fits into the size constraintsset by the currentParent Element.

8.Stream Copy

It is sometimes necessary to create a Matroska file from another Matroska file, for example, to add subtitles in a languageor to edit out a portion of the content.Some values from the original Matroska file need to be kept the same in the destination file.For example, theSamplingFrequency of an audio track wouldn't change between the two files.Some other values may change between the two files, for example, theTrackNumber of an audio track when another track has been added.

An element is marked with a property "stream copy: True" when the values of that element need to be kept identical between the source and destination files.If that property is not set, elements may or may not keep the same value between the source and destination files.

9.DefaultDecodedFieldDuration

TheDefaultDecodedFieldDuration element can signal to thedisplaying application how often fields of a video sequence will be availablefor displaying. It can be used for both interlaced and progressivecontent.

If the video sequence is signaled as interlaced (Section 5.1.4.1.28.1), thenDefaultDecodedFieldDuration equalsthe period between two successive fields at the output of the decoding process.For video sequences signaled as progressive,DefaultDecodedFieldDuration is half ofthe period between two successive frames at the output of the decoding process.

These values are valid at the end of the decoding process before post-processing(such as deinterlacing or inverse telecine) is applied.

Examples:

10.Cluster Blocks

Frames using referencesSHOULD be stored in "coding order" (i.e., the references first and thenthe frames referencing them). A consequence is that timestamps might not be consecutive.However, a frame with a past timestampMUST reference a frame already known; otherwise, it is considered bad/void.

Matroska has two similar ways to store frames in a block:

TheSimpleBlock is usually preferred unless some extra elements of theBlockGroup need to be used.AMatroska ReaderMUST support both types of blocks.

Each block contains the same parts in the following order:

The block header starts with the number of theTrack it corresponds to.The valueMUST correspond to theTrackNumber (Section 5.1.4.1.1) of aTrackEntry of theSegment.

TheTrackNumber is coded using the Variable-Size Integer (VINT) mechanism described inSection 4 of [RFC8794].To save space, the shortest VINT formSHOULD be used. The value can be coded using up to 8 octets.This is the only element with a variable size in the block header.

The timestamp is expressed in Track Ticks; seeSection 11.1.The value is stored as a signed value on 16 bits.

10.1.Block Structure

This section describes the binary data contained in theBlock element (Section 5.1.3.5.1). Bit 0 is the most significant bit.

As theTrackNumber size can vary between 1 and 8 octets, there are 8 different sizes for theBlock header.The definitions forTrackNumber sizes of 1 and 2 are provided; the other variants can be deduced by extending the size of theTrackNumber by multiples of 8 bits.

  0                   1                   2                   3  0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ |               |                               |       |I|LAC|U| |  Track Number |         Timestamp             | Rsvrd |N|ING|N| |               |                               |       |V|   |U| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Figure 11:Block Header with 1-Octet TrackNumber
  0                   1                   2                   3  0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ |          Track Number         |         Timestamp             | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ |       |I|LAC|U| | Rsvrd |N|ING|N|                     ... |       |V|   |U| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Figure 12:Block Header with 2-Octet TrackNumber

where:

Track Number:
8, 16, 24, 32, 40, 48, or 56 bits. An EBML VINT-coded track number.
Timestamp:
16 bits. Signed timestamp in Track Ticks.
Rsvrd:
4 bits. Reserved bitsMUST be set to 0.
INV:
1 bit. Invisible; The codecSHOULD decode this frame but not display it.
LACING:

2 bits. Uses lacing mode.

00b:
no lacing (Section 10.3.1)
01b:
Xiph lacing (Section 10.3.2)
11b:
EBML lacing (Section 10.3.3)
10b:
fixed-size lacing (Section 10.3.4)
UNU:
1 bit. Unused bit.

The remaining data in theBlock corresponds to the lacing data and frames usage as described in each respective lacing mode (seeSection 10.3).

10.2.SimpleBlock Structure

This section describes the binary data contained in theSimpleBlock element (Section 5.1.3.4). Bit 0 is the most significant bit.

TheSimpleBlock structure is inspired by theBlock structure; seeSection 10.1.The main differences are the added Keyframe flag and Discardable flag. Otherwise, everything is the same.

As theTrackNumber size can vary between 1 and 8 octets, there are 8 different sizes for theSimpleBlock header.The definitions forTrackNumber sizes of 1 and 2 are provided; theother variants can be deduced by extending the size of theTrackNumber by multiples of 8 bits.

  0                   1                   2                   3  0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ |               |                               |K|     |I|LAC|D| |  Track Number |         Timestamp             |E|Rsvrd|N|ING|I| |               |                               |Y|     |V|   |S| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Figure 13:SimpleBlock Header with 1-Octet TrackNumber
  0                   1                   2                   3  0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ |          Track Number         |         Timestamp             | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ |K|     |I|LAC|D| |E|Rsvrd|N|ING|I|                     ... |Y|     |V|   |S| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Figure 14:SimpleBlock Header with 2-Octet TrackNumber

where:

Track Number:
8, 16, 24, 32, 40, 48, or 56 bits. An EBML VINT-coded track number.
Timestamp:
16 bits. Signed timestamp in Track Ticks.
KEY:
1 bit. Keyframe; Set when theBlock contains only keyframes.
Rsvrd:
3 bits. Reserved bitsMUST be set to 0.
INV:
1 bit. Invisible; the codecSHOULD decode this frame but not display it.
LACING:

2 bits. Uses lacing mode.

00b:
no lacing (Section 10.3.1)
01b:
Xiph lacing (Section 10.3.2)
11b:
EBML lacing (Section 10.3.3)
10b:
fixed-size lacing (Section 10.3.4)
DIS:
1 bit. Discardable; The frames of theBlock can be discarded during playing if needed.

The remaining data in theSimpleBlock corresponds to the lacing data and frames usage as described in each respective lacing mode (seeSection 10.3).

10.3.Block Lacing

Lacing is a mechanism to save space when storing data. It is typically used for small blocksof data (referred to as frames in Matroska). It packs multiple frames into a singleBlock orSimpleBlock.

LacingMUST NOT be used to store a single frame in aBlock orSimpleBlock.

There are three types of lacing:

  • Xiph, which is inspired by what is found in the Ogg container[RFC3533]

  • EBML, which is the same with sizes coded differently

  • Fixed-size, where the size is not coded

When lacing is not used, i.e., to store a single frame, the lacing bits (bits 5 and 6) of theBlock orSimpleBlockMUST be set to zero.

For example, a user wants to store three frames of the same track. The first frame is 800 octets long,the second is 500 octets long, and the third is 1000 octets long.Because these frames are small,they can be stored in a lace to save space.

It is possible to not use lacing at all and just store a single frame without any extra data.When theFlagLacing (Section 5.1.4.1.12) is set to 0, all blocks of that trackMUST NOT use lacing.

10.3.1.No Lacing

When no lacing is used, the number of frames in the lace is omitted, and only one frame can be stored in theBlock. The LACING bits of theBlock Header flags are set to00b.

TheBlock for an 800-octet frame is as follows:

Table 35:No Lacing
Block OctetValueDescription
4-803<frame>Single frame data

When aBlock contains a single frame, itMUST use this "no lacing" mode.

10.3.2.Xiph Lacing

The Xiph lacing uses the same coding of size as found in the Ogg container[RFC3533].The LACING bits of theBlock Header flags are set to01b.

TheBlock data with laced frames is stored as follows:

  • Lacing Head on 1 Octet: Number of frames in the lace minus 1.

  • Lacing size of each frame except the last one.

  • Binary data of each frame consecutively.

The lacing size is split into 255 values, stored as unsigned octets -- for example, 500 is coded 255;245 or [0xFF 0xF5].A frame with a size multiple of 255 is coded with a 0 at the end of the size -- for example, 765 is coded 255;255;255;0 or [0xFF 0xFF 0xFF 0x00].

The size of the last frame is deduced from the size remaining in theBlock after the other frames.

Because large sizes result in large coding of the sizes, it isRECOMMENDED to use Xiph lacing only with small frames.

In our example, the 800-, 500-, and 1000-octet frames are stored with Xiph lacing in aBlock as follows:

Table 36:Xiph Lacing Example
Block OctetsValueDescription
40x02Number of frames minus 1
5-80xFF 0xFF 0xFF 0x23Size of the first frame (255;255;255;35)
9-100xFF 0xF5Size of the second frame (255;245)
11-810First frame data
811-1310Second frame data
1311-2310Third frame data

TheBlock is 2311 octets, and the last frame starts at 1311, so we can deduce that the size of the last frame is 2311 - 1311 = 1000.

10.3.3.EBML Lacing

The EBML lacing encodes the frame size with an EBML-like encoding[RFC8794].The LACING bits of theBlock Header flags are set to11b.

TheBlock data with laced frames is stored as follows:

  • Lacing Head on 1 Octet: Number of frames in the lace minus 1.

  • Lacing size of each frame except the last one.

  • Binary data of each frame consecutively.

The first frame size is encoded as an EBML VINT value.The remaining frame sizes are encoded as signed values using the difference between the frame size and the previous frame size.These signed values are encoded as VINT, with a mapping from signed to unsigned numbers.Decoding the unsigned number stored in the VINT to a signed number is done by subtracting 2((7*n)-1)-1, wheren is the octet size of the VINT.

Table 37:EBML Lacing Signed VINT Bits Usage
Bit Representation of Signed VINTPossible Value Range
1xxx xxxx2^7 values from -(26-1) to 26
01xx xxxx xxxx xxxx2^14 values from -(213-1) to 213
001x xxxx xxxx xxxx xxxx xxxx2^21 values from -(220-1) to 220
0001 xxxx xxxx xxxx xxxx xxxx xxxx xxxx2^28 values from -(227-1) to 227
0000 1xxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx2^35 values from -(234-1) to 234

In our example, the 800-, 500-, and 1000-octet frames are stored with EBML lacing in aBlock as follows:

Table 38:EBML Lacing Example
Block OctetsValueDescription
40x02Number of frames minus 1
5-60x43 0x20Size of the first frame (800 = 0x320 + 0x4000)
7-80x5E 0xD3Size of the second frame (500 - 800 = -300 = - 0x12C + 0x1FFF + 0x4000)
8-807<frame1>First frame data
808-1307<frame2>Second frame data
1308-2307<frame3>Third frame data

TheBlock is 2308 octets, and the last frame starts at 1308, so we can deduce that the size of the last frame is 2308 - 1308 = 1000.

10.3.4.Fixed-size Lacing

Fixed-size lacing doesn't store the frame size; rather, it only stores the number of frames in the lace.Each frameMUST have the same size. The frame size of each frame is deduced from the total size of theBlock.The LACING bits of theBlock Header flags are set to10b.

TheBlock data with laced frames is stored as follows:

  • Lacing Head on 1 Octet: Number of frames in the lace minus 1.

  • Binary data of each frame consecutively.

For example, for three frames that are 800 octets each:

Table 39:Fixed-Size Lacing Example
Block OctetsValueDescription
40x02Number of frames minus 1
5-804<frame1>First frame data
805-1604<frame2>Second frame data
1605-2404<frame3>Third frame data

This gives aBlock of 2405 octets. When reading theBlock, we find that there are three frames (Octet 4). The data start at Octet 5, so the size of each frame is (2405 - 5) / 3 = 800.

10.3.5.Laced Frames Timestamp

ABlock only contains a single timestamp value. But when lacing is used, it contains more than one frame.Each frame originally has its own timestamp, or Presentation Timestamp (PTS). That timestamp applies tothe first frame in the lace.

In the lace, each frame after the first one has an underdetermined timestamp.However, each of these framesMUST be contiguous -- i.e., the decoded dataMUST NOT contain any gapbetween them. If there is a gap in the stream, the frames around the gapMUST NOT be in the sameBlock.

Lacing is only useful for small contiguous data to save space. This is usually the case for audio tracksand not the case for video (which use a lot of data) or subtitle tracks (which have long gaps).For audio, there is usually a fixed output sampling frequency for the whole track,so the decoder should be able to recover the timestamp of each sample, knowing eachoutput sample is contiguous with a fixed frequency.For subtitles, this is usually not the case, so lacingSHOULD NOT be used.

10.4.Random Access Points

Random Access Points (RAPs) are positions where the parser can seek to andstart playback without decoding what was before. In Matroska,BlockGroups andSimpleBlocks can be RAPs. To seek to theseelements, it is still necessary to seek to theCluster containingthem, read theCluster Timestamp, and start playback from theBlockGroup orSimpleBlock that is a RAP.

Because a Matroska File is usually composed of multiple tracks playing at the same time-- video, audio, and subtitles -- to seek properly to a RAP, each selected track must betaken into account. Usually, all audio and subtitleBlockGroups orSimpleBlocks are RAPs.They are independent of each other and can be played randomly.

On the other hand, video tracks often use references to previous and futureframes for better coding efficiency. Frames with such referencesMUST either contain one or moreReferenceBlockelements in theirBlockGroup orMUST be marked asnon-keyframe in aSimpleBlock; seeSection 10.2.

<Cluster>  <Timestamp>123456</Timestamp>  <BlockGroup>    <!-- References a Block 40 Track Ticks before this one -->    <ReferenceBlock>-40</ReferenceBlock>    <Block/>  </BlockGroup>  ...</Cluster>
Figure 15:BlockGroup with a Frame That References Another Frame, with the EBML Tree Shown as XML
<Cluster>  <Timestamp>123456</Timestamp>  <SimpleBlock/> (octet 3 bit 0 not set)  ...</Cluster>
Figure 16:SimpleBlock with a Frame That References Another Frame, with the EBML Tree Shown as XML

Frames that are RAPs (i.e., frames that don't depend on other frames)MUST set the keyframeflag if they are in aSimpleBlock or their parentBlockGroupMUST NOT containaReferenceBlock.

<Cluster>  <Timestamp>123456</Timestamp>  <BlockGroup>    <!-- No ReferenceBlock allowed in this BlockGroup -->    <Block/>  </BlockGroup>  ...</Cluster>
Figure 17:BlockGroup with a Frame That References No Other Frame, with the EBML Tree Shown as XML
<Cluster>  <Timestamp>123456</Timestamp>  <SimpleBlock/> (octet 3 bit 0 set)  ...</Cluster>
Figure 18:SimpleBlock with a Frame That References No Other Frame, with the EBML Tree Shown as XML

There may be cases where the use ofBlockGroup is necessary, as the frame may need aBlockDuration,BlockAdditions,CodecState, orDiscardPadding element.For those cases, aSimpleBlockMUST NOT be used;the reference informationSHOULD be recovered for non-RAP frames.

<Cluster>  <Timestamp>123456</Timestamp>  <SimpleBlock/> (octet 3 bit 0 not set)  ...</Cluster>
Figure 19:SimpleBlock with a Frame That References Another Frame, with the EBML Tree Shown as XML
<Cluster>  <Timestamp>123456</Timestamp>  <BlockGroup>    <!-- ReferenceBlock value recovered based on the codec -->    <ReferenceBlock>-40</ReferenceBlock>    <BlockDuration>20</BlockDuration>    <Block/>  </BlockGroup>  ...</Cluster>
Figure 20:Same Frame That References Another Frame Put inside aBlockGroup to AddBlockDuration, with the EBML Tree Shown as XML

When a frame in aBlockGroup is not a RAP, theBlockGroupMUST contain at least aReferenceBlock.TheReferenceBlocksMUST be used in one of the following ways:

  • each reference frame listed as aReferenceBlock,

  • some referenced frames listed as aReferenceBlock, even if the timestamp value is accurate, or

  • oneReferenceBlock with the timestamp value "0" corresponding to a self or unknown reference.

The lack ofReferenceBlock would mean such a frame is a RAP, and seeking on thatframe that actually depends on other frames may create a bogus output or even crash.

<Cluster>  <Timestamp>123456</Timestamp>  <BlockGroup>    <!-- ReferenceBlock value not recovered from the codec -->    <ReferenceBlock>0</ReferenceBlock>    <BlockDuration>20</BlockDuration>    <Block/>  </BlockGroup>  ...</Cluster>
Figure 21:Same Frame That References Another Frame Put inside aBlockGroup, but the Reference Could Not Be Recovered, with the EBML Tree Shown as XML
<Cluster>  <Timestamp>123456</Timestamp>  <BlockGroup>    <!-- References a Block 80 Track Ticks before this one -->    <ReferenceBlock>-80</ReferenceBlock>    <!-- References a Block 40 Track Ticks after this one -->    <ReferenceBlock>40</ReferenceBlock>    <Block/>  </BlockGroup>  ...</Cluster>
Figure 22:BlockGroup with a Frame That References Two Other Frames, with the EBML Tree Shown as XML

Intra-only video frames, such as the ones found in AV1 or VP9, can be decoded without any otherframe, but they don't reset the codec state. Thus, seeking to these frames is not possible,as the next frames may need frames that are not known from this seeking point.Such intra-only framesMUST NOT be considered as keyframes, so the keyframe flagMUST NOT be set in theSimpleBlock or aReferenceBlockMUST be usedto signify the frame is not a RAP. The timestamp value of theReferenceBlockMUSTbe "0", meaning it's referencing itself.

<Cluster>  <Timestamp>123456</Timestamp>  <BlockGroup>    <!-- References itself to mark it should not be used as RAP -->    <ReferenceBlock>0</ReferenceBlock>    <Block/>  </BlockGroup>  ...</Cluster>
Figure 23:Intra-Only Frame (Not a RAP), with the EBML Tree Shown as XML

Because a videoSimpleBlock has less information on references than a videoBlockGroup,it is possible to remux a video track usingBlockGroup into aSimpleBlock,as long as it doesn't use any otherBlockGroup features thanReferenceBlock.

11.Timestamps

Historically, timestamps in Matroska were mistakenly called timecodes. TheTimestamp elementwas called Timecode, theTimestampScale element was called TimecodeScale, theTrackTimestampScale element was called TrackTimecodeScale, and theReferenceTimestamp element was called ReferenceTimeCode.

11.1.Timestamp Ticks

All timestamp values in Matroska are expressed in multiples of a tick.They are usually stored as integers.There are three types of ticks possible: Matroska Ticks, Segment Ticks, and Track Ticks.

11.1.1.Matroska Ticks

The timestamp value is stored directly in nanoseconds.

The elements storing values in Matroska Ticks/nanoseconds are:

11.1.2.Segment Ticks

Elements in Segment Ticks involve the use of theTimestampScale element of theSegment to get the timestamp in nanoseconds of the element, with the following formula:

timestamp in nanosecond = element value * TimestampScale

This allows for storage of smaller integer values in the elements.

When using the default value of "1,000,000" forTimestampScale, one Segment Tick represents one millisecond.

The elements storing values in Segment Ticks are:

11.1.3.Track Ticks

Elements in Track Ticks involve the use of theTimestampScaleelement of theSegment and theTrackTimestampScale elementof theTrack to get the timestamp in nanoseconds of the element, withthe following formula:

timestamp in nanoseconds =    element value * TrackTimestampScale * TimestampScale

This allows for storage of smaller integer values in the elements.The resulting floating-point values of the timestamps are still expressed in nanoseconds.

When using the default values of "1,000,000" forTimestampScale and "1.0" forTrackTimestampScale, one Track Tick represents one millisecond.

The elements storing values in Track Ticks are:

When theTrackTimestampScale is interpreted as "1.0", Track Ticks are equivalent to Segment Ticksand give an integer value in nanoseconds. This is the most common case asTrackTimestampScale is usually omitted.

A value ofTrackTimestampScale other than "1.0"MAYbe used to scale the timestamps more in tune with eachTrack samplingfrequency. For historical reasons, a lot ofMatroska Readers don'ttake theTrackTimestampScale value into account. Thus, using a valueother than "1.0" might not work in many places.

11.2.Block Timestamps

ABlock element andSimpleBlock element timestamp is thetime when the decoded data of the first frame in theBlock/SimpleBlockMUST be presented if thetrack of thatBlock/SimpleBlock is selected for playback.This is also known as the Presentation Timestamp (PTS).

TheBlock element andSimpleBlock element store theirtimestamps as signed integers, relative to theCluster\Timestampvalue of theCluster they are stored in. To get the timestamp of aBlock orSimpleBlock in nanoseconds, the following formulais used:

( Cluster\Timestamp + ( block timestamp * TrackTimestampScale ) ) *TimestampScale

TheBlock element andSimpleBlock element store their timestamps as 16-bit signed integers,allowing a range from "-32768" to "+32767" Track Ticks.Although these values can be negative, when added to theCluster\Timestamp, the resulting frame timestampSHOULD NOT be negative.

When aCodecDelay element is set, its valueMUST be subtracted from eachBlock timestamp of that track.To get the timestamp in nanoseconds of the first frame in aBlock orSimpleBlock, the formula becomes:

( ( Cluster\Timestamp + ( block timestamp * TrackTimestampScale ) ) *  TimestampScale ) - CodecDelay

The resulting frame timestampSHOULD NOT be negative.

During playback, when a frame has a negative timestamp, the contentMUST be decoded by the decoder but not played to the user.

11.3.TimestampScale Rounding

The default Track Tick duration is one millisecond.

TheTimestampScale is a floating-point value that is usually"1.0". But when it's not, the multipliedBlock Timestamp is afloating-point value in nanoseconds. TheMatroska ReaderSHOULD use the nearest rounding value in nanoseconds to get theproper nanosecond timestamp of aBlock. This allows some cleverTimestampScale values to have a more refined timestamp precision perframe.

12.Language Codes

Matroska versions 1 through 3 use language codes that can be either the three-letterbibliographic ISO 639-2 form[ISO639-2] (like "fre" for French)or such a language code followed by a dash and a country code for specialities in languages (like "fre-ca" for Canadian French).TheISO 639-2 Language elements areLanguage element,TagLanguage element, andChapLanguage element.

Starting in Matroska version 4, the forms defined in either[ISO639-2] or[RFC5646]MAY be used, although the form in[RFC5646] isRECOMMENDED. TheLanguage elements in the[RFC5646] formareLanguageBCP47 element,TagLanguageBCP47 element, andChapLanguageBCP47 element. If both an[ISO639-2] Language element and an[RFC5646] Language element are used within the sameParent Element, then theLanguage element in the[ISO639-2] formMUSTbe ignored and precedence given to theLanguage element in the[RFC5646] form.

In this document, "BCP47" in element names refers specifically to[RFC5646], which is part of BCP 47.

13.Country Codes

Country codes are the[RFC5646] two-letter region subtags, without the UK exception.

14.Encryption

This Matroska specification provides no interoperable solution for securingthe data container with any assurances of confidentiality, integrity,authenticity, or authorization. TheContentEncryption element (Section 5.1.4.1.31.8) and associated sub-fields (Section 5.1.4.1.31.9 toSection 5.1.4.1.31.12) are defined only for the benefit ofimplementers to construct their own proprietary solution or as the basis forfurther standardization activities. How to use these fields to secure aMatroska data container is out of scope, as are any related issues such as keymanagement and distribution.

AMatroska Reader who encounters containers that use the fieldsdefined in this sectionMUST rely on out-of-scope guidance todecode the associated content.

Because encryption occurs within theBlock element, it is possibleto manipulate encrypted streams without decrypting them. The streams couldpotentially be copied, deleted, cut, appended, or any number of other possibleediting techniques without decryption. The data can be used without having toexpose it or go through the decrypting process.

Encryption can also be layered within Matroska. This means that two completely differenttypes of encryption can be used, requiring two separate keys to be able to decrypt a stream.

Encryption information is stored in theContentEncodings element under theContentEncryption element.

For encryption systems sharing public/private keys, the creation of the keys and the exchange of keysare not covered by this document. They have to be handled by the system using Matroska.

The algorithms described inTable 24 supportdifferent modes of operations and key sizes. The specification of theseparameters is required for a complete solution but is out of scope of thisdocument and left to the proprietary implementations using them or subsequentprofiles of this document.

TheContentEncodingScope element gives an idea of which part ofthe track is encrypted, but eachContentEncAlgo element and itssub-elements (likeAESSettingsCipherMode) define exactly how theencrypted track should be interpreted.

An example of an extension that builds upon these security-related fields in this specification is[WebM-Enc].It uses AES-CTR,ContentEncAlgo = 5 (Section 5.1.4.1.31.9), andAESSettingsCipherMode = 1 (Section 5.1.4.1.31.12).

AMatroska WriterMUST NOT use insecurecryptographic algorithms to create new archives or streams, but aMatroskaReaderMAY support these algorithms to read previouslymade archives or streams.

15.Image Presentation

15.1.Cropping

ThePixelCrop elements (PixelCropTop,PixelCropBottom,PixelCropRight, andPixelCropLeft)indicate when, and by how much, encoded video framesSHOULD becropped for display. These elements allow edges of the frame that are notintended for display (such as the sprockets of a full-frame film scan or theVideo ANCillary (VANC) area of a digitized analog videotape) to be stored buthidden.PixelCropTop andPixelCropBottom store an integerof how many rows of pixelsSHOULD be cropped from the top andbottom of the image, respectively.PixelCropLeft andPixelCropRight store an integer of how many columns of pixelsSHOULD be cropped from the left and right of the image,respectively.

For example, a pillar-boxed video that stores a 1440x1080 visual imagewithin the center of a padded 1920x1080 encoded image may set bothPixelCropLeft andPixelCropRight to "240", so aMatroskaPlayer should crop off 240 columns of pixels from the left and right ofthe encoded image to present the image with the pillar-boxes hidden.

Cropping has to be performed before resizing and the display dimensionsgiven byDisplayWidth,DisplayHeight, andDisplayUnit apply to the already-cropped image.

15.2.Rotation

TheProjectionPoseRoll element (Section 5.1.4.1.28.46) can be used to indicate that the imagefrom the associated video trackSHOULD be rotated forpresentation. For instance, the following example of theProjectionelement (Section 5.1.4.1.28.41) and theProjectionPoseRoll element represents a video track where the imageSHOULD be presented with a 90-degree counter-clockwiserotation, with the EBML tree shown as XML:

<Projection>  <ProjectionPoseRoll>90</ProjectionPoseRoll></Projection>
Figure 24:Rotation Example

16.Segment Position

TheSegment Position of an element refers to the position of thefirst octet of theElement ID of that element, measured in octets,from the beginning of theElement Data section of the containingSegment element. In other words, theSegment Position of anelement is the distance in octets from the beginning of its containingSegment element minus the size of theElement ID andElement Data Size of thatSegment element. TheSegmentPosition of the firstChild Element of theSegmentelement is 0. An element that is not stored within aSegmentelement, such as the elements of theEBML Header, do not have aSegment Position.

16.1.Segment Position Exception

Elements that are defined to store aSegment PositionMAY define reserved values toindicate a special meaning.

16.2.Example of Segment Position

This table presents an example ofSegment Position by showing a hexadecimal representationof a very small Matroska file with labels to show the offsets in octets. The file containsaSegment element with anElement ID of "0x18538067" and aMuxingApp element with anElement ID of "0x4D80".

     0                             1                             2     0  1  2  3  4  5  6  7  8  9  0  1  2  3  4  5  6  7  8  9  0     +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+   0 |1A|45|DF|A3|8B|42|82|88|6D|61|74|72|6F|73|6B|61|     ^ EBML Header   0 |                                               |18|53|80|67|                                                     ^ Segment ID  20 |93|     ^ Segment Data Size  20 |  |15|49|A9|66|8E|4D|80|84|69|65|74|66|57|41|84|69|65|74|66|        ^ Start of Segment data  20 |                 |4D|80|84|69|65|74|66|57|41|84|69|65|74|66|                       ^ MuxingApp start

In the above example, theElement ID of theSegment element is stored at offset 16,theElement Data Size of theSegment element is stored at offset 20, and theElement Data of theSegment element is stored at offset 21.

TheMuxingApp element is stored at offset 26. Since theSegment Position ofan element is calculated by subtracting the position of theElement Data ofthe containingSegment element from the position of that element, theSegment Positionof theMuxingApp element in the above example is "26 - 21" or "5".

17.Linked Segments

Matroska provides several methods to link two or moreSegmentelements together to create aLinked Segment. ALinkedSegment is a set of multipleSegments linked together into asingle presentation by using Hard Linking or Medium Linking.

AllSegments within aLinked SegmentMUST have aSegmentUUID.

AllSegments within aLinked SegmentSHOULD be stored within the same directoryor be quickly accessible based on theirSegmentUUIDin order to have a seamless transition between segments.

AllSegments within aLinked SegmentMAY set aSegmentFamily with a common value to makeit easier for aMatroska Player to know whichSegments are meant to be played together.

TheSegmentFilename,PrevFilename, andNextFilename elementsMAY also give hints onthe original filenames that were used when theSegment links were created, in case someSegmentUUIDs are damaged.

17.1.Hard Linking

Hard Linking, also called "splitting", is the process of creating aLinked Segmentby linking multipleSegment elements using theNextUUID andPrevUUID elements.

AllSegments within aHard Linked SegmentMUST use the sameTracks list andTimestampScale.

Within aLinked Segment, the timestamps ofBlock andSimpleBlockMUST consecutively followthe timestamps ofBlock andSimpleBlock from the previousSegment in linking order.

With Hard Linking, the chapters of anySegment within theLinked SegmentMUST only reference the currentSegment.TheNextUUID andPrevUUID reference the respectiveSegmentUUID values of the next and previousSegments.

The firstSegment of aLinked SegmentMUST NOT have aPrevUUID element.The lastSegment of aLinked SegmentMUST NOT have aNextUUID element.

For each node of the chain ofSegments of aLinked Segment, at least oneSegmentMUST reference the otherSegment within the chain.

In a chain ofSegments of aLinked Segment, theNextUUID always takes precedence over thePrevUUID.Thus, if SegmentA has aNextUUID to SegmentB and SegmentB has aPrevUUID to SegmentC,the link to use isNextUUID between SegmentA and SegmentB, and SegmentC is not part of theLinked Segment.

If SegmentB has aPrevUUID to SegmentA, but SegmentA has noNextUUID, then theMatroska PlayerMAY consider these twoSegments linked as SegmentA followed by SegmentB.

As an example, threeSegments can be Hard Linked as aLinked Segment throughcross-referencing each other withSegmentUUID,PrevUUID, andNextUUID as shown in this table:

Table 40:Usual Hard Linking UIDs
file nameSegmentUUIDPrevUUIDNextUUID
start.mkv71000c23cd310998 53fbc94dd984a5ddInvalida77b3598941cb803 eac0fcdafe44fac9
middle.mkva77b3598941cb803 eac0fcdafe44fac971000c23cd310998 53fbc94dd984a5dd6c92285fa6d3e827 b198d120ea3ac674
end.mkv6c92285fa6d3e827 b198d120ea3ac674a77b3598941cb803 eac0fcdafe44fac9Invalid

An example where only theNextUUID element is used:

Table 41:Hard Linking without PrevUUID
file nameSegmentUUIDPrevUUIDNextUUID
start.mkv71000c23cd310998 53fbc94dd984a5ddInvalida77b3598941cb803 eac0fcdafe44fac9
middle.mkva77b3598941cb803 eac0fcdafe44fac9n/a6c92285fa6d3e827 b198d120ea3ac674
end.mkv6c92285fa6d3e827 b198d120ea3ac674n/aInvalid

An example where only thePrevUUID element is used:

Table 42:Hard Linking without NextUUID
file nameSegmentUUIDPrevUUIDNextUUID
start.mkv71000c23cd310998 53fbc94dd984a5ddInvalidn/a
middle.mkva77b3598941cb803 eac0fcdafe44fac971000c23cd310998 53fbc94dd984a5ddn/a
end.mkv6c92285fa6d3e827 b198d120ea3ac674a77b3598941cb803 eac0fcdafe44fac9Invalid

An example where only themiddle.mkv is using thePrevUUID andNextUUID elements:

Table 43:Hard Linking with Mixed UID Links
file nameSegmentUUIDPrevUUIDNextUUID
start.mkv71000c23cd310998 53fbc94dd984a5ddInvalidn/a
middle.mkva77b3598941cb803 eac0fcdafe44fac971000c23cd310998 53fbc94dd984a5dd6c92285fa6d3e827 b198d120ea3ac674
end.mkv6c92285fa6d3e827 b198d120ea3ac674n/aInvalid

17.2.Medium Linking

Medium Linking creates relationships betweenSegments usingOrdered Chapters (Section 20.1.3) and theChapterSegmentUUID element. AChapter Edition withOrdered ChaptersMAY containChapterselements that reference timestamp ranges from otherSegments. TheSegment referenced by theOrdered Chapter via theChapterSegmentUUID elementSHOULD be played as part ofaLinked Segment.

The timestamps ofSegment content referenced byOrdered ChaptersMUST be adjusted according to the cumulative duration of the previousOrdered Chapters.

As an example, a file namedintro.mkv could have aSegmentUUID of "0xb16a58609fc7e60653a60c984fc11ead". Another filecalledprogram.mkv could use aChapter Edition that containstwoOrdered Chapters. The first chapter references theSegment ofintro.mkv with the use of aChapterSegmentUUID,ChapterSegmentEditionUID,ChapterTimeStart, and an optionalChapterTimeEnd element.The second chapter references content within theSegment ofprogram.mkv. AMatroska PlayerSHOULDrecognize theLinked Segment created by the use ofChapterSegmentUUID in an enabledEdition and present thereference content of the twoSegments as a single presentation.

TheChapterSegmentUUID represents theSegment that holds the content to play in place of theLinked Chapter.TheChapterSegmentUUIDMUST NOT be theSegmentUUID of its ownSegment.

There are two ways to use a chapter link:

  • Linked-Duration linking

  • Linked-Edition linking

17.2.1.Linked-Duration

AMatroska PlayerMUST play the content of theLinked Segment from theChapterTimeStart until theChapterTimeEnd timestamp in place of theLinked Chapter.

ChapterTimeStart andChapterTimeEnd represent timestamps in theLinked Segment matching the value ofChapterSegmentUUID.Their valuesMUST be in the range of theLinked Segment duration.

TheChapterTimeEnd valueMUST be set when using Linked-Duration chapter linking.ChapterSegmentEditionUIDMUST NOT be set.

17.2.2.Linked-Edition

AMatroska PlayerMUST play the wholeLinked Edition of theLinked Segment in place of theLinked Chapter.

ChapterSegmentEditionUID represents a validEdition from theLinked Segment matching the value ofChapterSegmentUUID.

When using Linked-Edition chapter linking,ChapterTimeEnd isOPTIONAL.

18.Track Flags

18.1.Default Flag

The Default flag is a hint for aMatroska Player indicating that agiven trackSHOULD be eligible to be automatically selected asthe default track for a given language. If no tracks in a given language havethe Default flag set, then all tracks in that language are eligible forautomatic selection. This can be used to indicate that a track provides"regular service" that is suitable for users with default settings, as opposedto specialized services, such as commentary, captions for users with hearingimpairments, or descriptive audio.

TheMatroska PlayerMAY override the Default flagfor any reason, including user preferences to prefer tracks providingaccessibility services.

18.2.Forced Flag

The Forced flag tells theMatroska Player that itSHOULD display this subtitle track, even if user preferencesusually would not call for any subtitles to be displayed alongside the audiotrack that is currently selected. This can be used to indicate that a trackcontains translations of on-screen text or dialogue spoken in a differentlanguage than the track's primary language.

18.3.Hearing-Impaired Flag

The Hearing-Impaired flag tells theMatroska Player that itSHOULD prefer this track when selecting a default track for auser with a hearing impairment and that itMAY prefer to selecta different track when selecting a default track for a user that is nothearing impaired.

18.4.Visual-Impaired Flag

The Visual-Impaired flag tells theMatroska Player that itSHOULD prefer this track when selecting a default track for auser with a visual impairment and that itMAY prefer to selecta different track when selecting a default track for a user that is notvisually impaired.

18.5.Descriptions Flag

The Descriptions flag tells theMatroska Player that this track issuitable to play via a text-to-speech system for a user with a visualimpairment and that itSHOULD NOT automatically select thistrack when selecting a default track for a user that is not visuallyimpaired.

18.6.Original Flag

The Original flag tells theMatroska Player that this track is inthe original language and that itSHOULD prefer this track ifconfigured to prefer original-language tracks of this track's type.

18.7.Commentary Flag

The Commentary flag tells theMatroska Player that this trackcontains commentary on the content.

18.8.Track Operation

TrackOperation allows for the combination of multiple tracks to make a virtual one. It usestwo separate system to combine tracks. One to create a 3D "composition" (left/right/background planes)and one to simplify join two tracks together to make a single track.

A track created withTrackOperation is a proper track with a UID and all its flags.However, the codec ID is meaningless because each "sub" track needs to be decoded by itsown decoder before the "operation" is applied. TheCues elements corresponding to sucha virtual trackSHOULD be the union of theCues elements for each of the tracks it's composed of (when theCues are defined per track).

In the case ofTrackJoinBlocks, theBlock elements (fromBlockGroup andSimpleBlock) of all the tracksSHOULD be used as if they were defined for this new virtualTrack. When twoBlock elements have overlapping start orend timestamps, it's up to the underlying system to either drop some of theseframes or render them the way they overlap. This situationSHOULD be avoided when creating such tracks, as you can neverbe sure of the end result on different platforms.

18.9.Overlay Track

An overlay trackSHOULD be rendered in the same channel as the track it's linked to.When content is found in such a track, itSHOULD be played on the rendering channelinstead of the original track.

18.10.Multi-planar and 3D Videos

There are two different ways to compress 3D videos: have each eye track in a separate trackand have one track have both eyes combined inside (which is more efficient compression-wise).Matroska supports both ways.

For the single-track variant, there is theStereoMode element,which defines how planes are assembled in the track (mono or left-rightcombined). Odd values ofStereoMode means the left plane comes firstfor more convenient reading. The pixel count of the track(PixelWidth/PixelHeight) is the raw number of pixels (forexample, 3840x1080 for full HD side by side), and theDisplayWidth/DisplayHeight in pixels is the number of pixelsfor one plane (1920x1080 for that full HD stream). Old stereo 3D movies weredisplayed using anaglyph (cyan and red colors separated). For compatibilitywith such movies, there is a value of theStereoMode that correspondsto anaglyph.

There is also a "packed" mode (values 13 and 14) that consists of packing two frames togetherin aBlock that uses lacing. The first frame is the left eye and the other frame is the right eye(or vice versa). The framesSHOULD be decoded in that order and are possibly dependenton each other (P and B frames).

For separate tracks, Matroska needs to define exactly which track does what.TrackOperation withTrackCombinePlanes does that. For more details, seeSection 18.8 on howTrackOperation works.

The 3D support is still in infancy and may evolve to support more features.

TheStereoMode used to be part of Matroska v2, but it didn't meet therequirement for multiple tracks. There was also a bug in[libmatroska] prior to 0.9.0 that would save/read it as0x53B9 instead of0x53B8; seeOldStereoMode (Section 5.1.4.1.28.5).Matroska ReadersMAY support these legacy files by checking Matroska v2 or0x53B9. The older values ofStereoMode were 0 (mono), 1 (right eye),2 (left eye), and 3 (both eyes); these are the only values that can be foundinOldStereoMode. They are not compatible with theStereoMode values found inMatroska v3 and above.

19.Default Track Selection

This section provides some example sets ofTracks and hypotheticaluser settings, along with indications of which ones a similarly configuredMatroska PlayerSHOULD automatically select forplayback by default in such a situation. A playerMAY provideadditional settings with more detailed controls for more nuancedscenarios. These examples are provided as guidelines to illustrate theintended usages of the various supportedTrack flags and theirexpected behaviors.

Track names are shown in English for illustrative purposes; actualfiles may have titles in the language of each track or provide titles inmultiple languages.

19.1.Audio Selection

Example track set:

Table 44:Audio Tracks for Default Selection
No.TypeLangLayoutOriginalDefaultOther FlagsName
1VideoundN/AN/AN/ANone
2Audioeng5.111None
3Audioeng2.011None
4Audioeng2.010Visual-ImpairedDescriptive audio
5Audioesp5.101None
6Audioesp2.000Visual-ImpairedDescriptive audio
7Audioeng2.010CommentaryDirector's Commentary
8Audioeng2.010NoneKaraoke

The table above shows a file with seven audio tracks -- five in English and two in Spanish.

The English tracks all have the Original flag, indicating that English is the original content language.

Generally, the player will first consider the track languages. If the player has an option to preferoriginal-language audio and the user has enabled it, then it should prefer one of the tracks with the Original flag.If the user has configured to specifically prefer audio tracks in English orSpanish, the player should select one of the tracks in the correspondinglanguage. The player may also wish to prefer a track with the Original flag ifno tracks matching any of the user's explicitly preferred languages areavailable.

Two of the tracks have the Visual-Impaired flag. If the player has been configured to prefer such tracks,it should select one; otherwise, it should avoid them if possible.

If selecting an English track, when other settings have left multiple possible options,it may be useful to exclude the tracks that lack the Default flag. Here, one provides descriptive service forindividuals with visual impairments (which has its own flag and may be automatically selected by user configurationbut is unsuitable for users with default-configured players), one is a commentary track(which has its own flag and the player may or may not have specialized handling for),and the last contains karaoke versions of the music that plays during the film (which is an unusualspecialized audio service that Matroska has no built-in support for indicating, so it's indicatedin the track name instead). By not setting the Default flag on these specialized tracks, the file's authorhints that they should not be automatically selected by a default-configured player.

Having narrowed its choices down, the example player now may have to select between tracks 2 and 3.The only difference between these tracks is their channel layouts: 2 is 5.1 surround, while 3 is stereo.If the player is aware that the output device is a pair of headphones or stereo speakers, it may wishto prefer the stereo mix automatically. On the other hand, if it knows that the device is a surround system,it may wish to prefer the surround mix.

If the player finishes analyzing all of the available audio tracks and finds that more than one seem equallyand maximally preferable, itSHOULD default to the first of the group.

19.2.Subtitle Selection

Example track set:

Table 45:Subtitle Tracks for Default Selection
No.TypeLangOriginalDefaultForcedOther FlagsName
1VideoundN/AN/AN/ANone
2Audiofra11N/ANone
3Audiopor01N/ANone
4Subtitlesfra110None
5Subtitlesfra100Hearing-ImpairedCaptions for users with hearing impairments
6Subtitlespor010None
7Subtitlespor001NoneSigns
8Subtitlespor000Hearing-ImpairedSDH

The table above shows two audio tracks and five subtitle tracks. As we can see, French is the original language.

We'll start by discussing the case where the user prefers French (or original-language)audio (or has explicitly selected the French audio track) and also prefers French subtitles.

In this case, if the player isn't configured to display captions when the audio matches theirpreferred subtitle languages, the player doesn't need to select a subtitle track at all.

If the userhas indicated that they want captions to be displayed, the selection simplycomes down to whether hearing-impaired subtitles are preferred.

The situation for a user who prefers Portuguese subtitles starts out somewhat analogous.If they select the original French audio (either by explicit audio language preference,preference for original-language tracks, or explicitly selecting that track), then theselection once again comes down to the hearing-impaired preference.

However, the case where the Portuguese audio track is selected has an important catch:a Forced track in Portuguese is present. This may contain translations of on-screen textfrom the video track or of portions of the audio that are not translated (music, for instance).This means that even if the user's preferences wouldn't normally call for captions here,the Forced track should be selected nonetheless, rather than selecting no track at all.On the other hand, if the user's preferencesdo call for captions, the non-Forced tracksshould be preferred, as the Forced track will not contain captioning for the dialogue.

20.Chapters

The MatroskaChapters system can have multipleEditions, and eachEdition can consist ofSimple Chapters where a chapter start time is used as a marker in the timeline only. AnEdition can be more complex withOrdered Chapters where a chapter end timestamp is additionallyused or much more complex withLinked Chapters. The MatroskaChapters system can also have a menustructure borrowed from the DVD-menu system[DVD-Video] or have its own built-in Matroska menu structure.

20.1.EditionEntry

TheEditionEntry is also called anEdition.AnEdition contains a set ofEdition flags andMUST contain at least oneChapterAtom element.Chapters are always inside anEdition (or aChapter itself is part of anEdition).MultipleEditions are allowed. Some of theseEditionsMAY be ordered and others not.

20.1.1.EditionFlagDefault

Only oneEditionSHOULD have anEditionFlagDefault flag set totrue.

20.1.2.Default Edition

TheDefault Edition is theEdition that aMatroska PlayerSHOULD use for playback by default.

The firstEdition with theEditionFlagDefault flag set totrue is theDefault Edition.

When allEditionFlagDefault flags are set tofalse, then the firstEditionis theDefault Edition.

Table 46:Default Edition, All Default
EditionFlagDefaultDefault Edition
Edition 1trueX
Edition 2true
Edition 3true
Table 47:Default Edition, No Default
EditionFlagDefaultDefault Edition
Edition 1falseX
Edition 2false
Edition 3false
Table 48:Default Edition, With Default
EditionFlagDefaultDefault Edition
Edition 1false
Edition 2trueX
Edition 3false

20.1.3.EditionFlagOrdered

TheEditionFlagOrdered flag is a significant feature, as itenables anEdition ofOrdered Chapters that defines andarranges a virtual timeline rather than simply labeling points within thetimeline. For example, withEditions ofOrdered Chapters, asingleMatroska file can present multiple edits of a film withoutduplicating content. Alternatively, if a videotape is digitized in full, oneOrdered Edition could present the full content (including colorbars,countdown, slate, a feature presentation, and black frames), while anotherEdition ofOrdered Chapters can useChapters thatonly mark the intended presentation with the colorbars and other ancillaryvisual information excluded. If anEdition ofOrderedChapters is enabled, then theMatroska PlayerMUST play thoseChapters in their stored order fromthe timestamp marked in theChapterTimeStart element to the timestampmarked in toChapterTimeEnd element.

If theEditionFlagOrdered flag evaluates to "0",SimpleChapters are used and only theChapterTimeStart of aChapter is used as a chapter mark to jump to the predefined point inthe timeline. WithSimple Chapters, aMatroska PlayerMUST ignore certain elements inside aChapterselement. In that case, these elements are informational only.

The following list shows the differentChapters elements only found inOrdered Chapters.

  • ChapterAtom\ChapterSegmentUUID

  • ChapterAtom\ChapterSegmentEditionUID

  • ChapterAtom\ChapProcess

  • Info\ChapterTranslate

  • TrackEntry\TrackTranslate

Furthermore, there are other EBML elements that could be used if theEditionFlagOrderedevaluates to "1".

20.1.3.1.Ordered-Edition and Matroska Segment Linking
Hard Linking:

Ordered Chapters supersede theHard Linking.

Medium Linking:

Ordered Chapters are used in a normal way and can be combinedwith theChapterSegmentUUID element, which establishes a link to anotherSegment.

SeeSection 17 onLinked Segments for more informationaboutHard Linking andMedium Linking.

20.2.ChapterAtom

TheChapterAtom is also called aChapter.

20.2.1.ChapterTimeStart

ChapterTimeStart is the timestamp of the start ofChapter with nanosecond accuracy and is not scaled byTimestampScale.ForSimple Chapters, this is the position of the chapter markers in the timeline.

20.2.2.ChapterTimeEnd

ChapterTimeEnd is the timestamp of the end ofChapterwith nanosecond accuracy and is not scaled byTimestampScale. Thetimestamp defined by theChapterTimeEnd is not part of theChapter. AMatroska Player calculates the duration of thisChapter using the difference between theChapterTimeEnd andChapterTimeStart. The end timestampMUST be greaterthan or equal to the start timestamp.

When theChapterTimeEnd timestamp is equal to theChapterTimeStart timestamp,the timestamp is included in theChapter. It can be useful to put markers ina file or add chapter commands with ordered chapter commands without having to play anything;seeSection 5.1.7.1.4.14.

Table 49:ChapterTimeEnd Usage Possibilities
ChapterStart timestampEnd timestampDuration
Chapter 1010000000001000000000
Chapter 2100000000050000000004000000000
Chapter 3600000000060000000000
Chapter 490000000008000000000Invalid (-1000000000)

20.2.3.Nested Chapters

AChapterAtom element can contain otherChapterAtom elements.That element is aParent Chapter, and theChapterAtom elements it contains areNested Chapters.

Nested Chapters can be useful to tag small parts of aSegment that already have tags oradd Chapter Codec commands on smaller parts of aSegment that already have Chapter Codec commands.

TheChapterTimeStart of aNested ChapterMUST be greater than or equal to theChapterTimeStart of itsParent Chapter.

If theParent Chapter of aNested Chapter has aChapterTimeEnd, theChapterTimeStart of thatNested ChapterMUST be smaller than or equal to theChapterTimeEnd of theParent Chapter.

20.2.4.Nested Chapters in Ordered Chapters

TheChapterTimeEnd of the lowest level ofNested ChaptersMUST be set forOrdered Chapters.

When used withOrdered Chapters, theChapterTimeEnd value of aParent Chapter is useless for playback,as the proper playback sections are described in itsNested Chapters.TheChapterTimeEndSHOULD NOT be set inParent Chapters andMUST be ignored for playback.

20.2.5.ChapterFlagHidden

EachChapter'sChapterFlagHidden flag works independently ofParent Chapters.ANested Chapter with aChapterFlagHidden flag that evaluates to"0" remains visible in the user interface even if theParent Chapter'sChapterFlagHidden flag is set to "1".

Table 50:ChapterFlagHidden Nested Visibility
Chapter + Nested ChapterChapterFlagHiddenvisible
Chapter 10yes
Nested Chapter 1.10yes
Nested Chapter 1.21no
Chapter 21no
Nested Chapter 2.10yes
Nested Chapter 2.21no

20.3.Menu Features

The menu features are handled like achapter codec. That means each codec has a type,some private data, and some data in the chapters.

The type of the menu system is defined by theChapProcessCodecID parameter.For now, only two values are supported: 0 (Matroska Script) and 1 (menu borrowed from the DVD[DVD-Video]).The private data stored inChapProcessPrivate andChapProcessData depends on theChapProcessCodecID value.

The menu system, as well as Chapter Codecs in general, can perform actions on theMatroska Player, such as jumping to anotherChapter orEdition, selecting different tracks, and possibly more.The scope of all the possibilities of Chapter Codecs is not covered in this document, as itdepends on the Chapter Codec features and its integration in aMatroska Player.

20.4.Physical Types

Each level can have different meanings for audio and video. TheORIGINAL_MEDIA_TYPE tag[MatroskaTags] can be used tospecify a string for ChapterPhysicalEquiv = 60. Here is the list of possible levels for both audio and video:

Table 51:ChapterPhysicalEquiv Meaning per Track Type
ValueAudioVideoComment
70SET / PACKAGESET / PACKAGEthe collection of different media
60CD / 12" / 10" / 7" / TAPE / MINIDISC / DATDVD / VHS / LASERDISCthe physical medium like a CD or a DVD
50SIDESIDEwhen the original medium (LP/DVD) has different sides
40-LAYERanother physical level on DVDs
30SESSIONSESSIONas found on CDs and DVDs
20TRACK-as found on audio CDs
10INDEX-the first logical level of the side/medium

20.5.Chapter Examples

20.5.1.Example 1: Basic Chaptering

In this example, a movie is split in different chapters. It could also just be anaudio file (album) in which each track corresponds to a chapter.

  • 00000 ms - 05000 ms: Intro
  • 05000 ms - 25000 ms: Before the crime
  • 25000 ms - 27500 ms: The crime
  • 27500 ms - 38000 ms: After the crime
  • 38000 ms - 43000 ms: Credits

This translates to Matroska form, with the EBML tree shown as follows in XML:

<Chapters>  <EditionEntry>    <EditionUID>16603393396715046047</EditionUID>    <ChapterAtom>      <ChapterUID>1193046</ChapterUID>      <ChapterTimeStart>0</ChapterTimeStart>      <ChapterTimeEnd>5000000000</ChapterTimeEnd>      <ChapterDisplay>        <ChapString>Intro</ChapString>      </ChapterDisplay>    </ChapterAtom>    <ChapterAtom>      <ChapterUID>2311527</ChapterUID>      <ChapterTimeStart>5000000000</ChapterTimeStart>      <ChapterTimeEnd>25000000000</ChapterTimeEnd>      <ChapterDisplay>        <ChapString>Before the crime</ChapString>      </ChapterDisplay>      <ChapterDisplay>        <ChapString>Avant le crime</ChapString>        <ChapLanguage>fra</ChapLanguage>      </ChapterDisplay>    </ChapterAtom>    <ChapterAtom>      <ChapterUID>3430008</ChapterUID>      <ChapterTimeStart>25000000000</ChapterTimeStart>      <ChapterTimeEnd>27500000000</ChapterTimeEnd>      <ChapterDisplay>        <ChapString>The crime</ChapString>      </ChapterDisplay>      <ChapterDisplay>        <ChapString>Le crime</ChapString>        <ChapLanguage>fra</ChapLanguage>      </ChapterDisplay>    </ChapterAtom>    <ChapterAtom>      <ChapterUID>4548489</ChapterUID>      <ChapterTimeStart>27500000000</ChapterTimeStart>      <ChapterTimeEnd>38000000000</ChapterTimeEnd>      <ChapterDisplay>        <ChapString>After the crime</ChapString>      </ChapterDisplay>      <ChapterDisplay>        <ChapString>Apres le crime</ChapString>        <ChapLanguage>fra</ChapLanguage>      </ChapterDisplay>    </ChapterAtom>    <ChapterAtom>      <ChapterUID>5666960</ChapterUID>      <ChapterTimeStart>38000000000</ChapterTimeStart>      <ChapterTimeEnd>43000000000</ChapterTimeEnd>      <ChapterDisplay>        <ChapString>Credits</ChapString>      </ChapterDisplay>      <ChapterDisplay>        <ChapString>Generique</ChapString>        <ChapLanguage>fra</ChapLanguage>      </ChapterDisplay>    </ChapterAtom>  </EditionEntry></Chapters>
Figure 25:Basic Chapters Example

20.5.2.Example 2: Nested Chapters

In this example, an (existing) album is split into different chapters, and oneof them contains another splitting.

20.5.2.1.The Micronauts "Bleep To Bleep"
  • 00:00 - 12:28: Baby wants to Bleep/Rock

    • 00:00 - 04:38: Baby wants to bleep (pt.1)
    • 04:38 - 07:12: Baby wants to rock
    • 07:12 - 10:33: Baby wants to bleep (pt.2)
    • 10:33 - 12:28: Baby wants to bleep (pt.3)
  • 12:30 - 19:38: Bleeper_O+2
  • 19:40 - 22:20: Baby wants to bleep (pt.4)
  • 22:22 - 25:18: Bleep to bleep
  • 25:20 - 33:35: Baby wants to bleep (k)
  • 33:37 - 44:28: Bleeper

This translates to Matroska form, with the EBML tree shown as follows in XML:

<Chapters>  <EditionEntry>    <EditionUID>1281690858003401414</EditionUID>    <ChapterAtom>      <ChapterUID>1</ChapterUID>      <ChapterTimeStart>0</ChapterTimeStart>      <ChapterTimeEnd>748000000</ChapterTimeEnd>      <ChapterDisplay>        <ChapString>Baby wants to Bleep/Rock</ChapString>      </ChapterDisplay>      <ChapterAtom>        <ChapterUID>2</ChapterUID>        <ChapterTimeStart>0</ChapterTimeStart>        <ChapterTimeEnd>278000000</ChapterTimeEnd>        <ChapterDisplay>          <ChapString>Baby wants to bleep (pt.1)</ChapString>        </ChapterDisplay>      </ChapterAtom>      <ChapterAtom>        <ChapterUID>3</ChapterUID>        <ChapterTimeStart>278000000</ChapterTimeStart>        <ChapterTimeEnd>432000000</ChapterTimeEnd>        <ChapterDisplay>          <ChapString>Baby wants to rock</ChapString>        </ChapterDisplay>      </ChapterAtom>      <ChapterAtom>        <ChapterUID>4</ChapterUID>        <ChapterTimeStart>432000000</ChapterTimeStart>        <ChapterTimeEnd>633000000</ChapterTimeEnd>        <ChapterDisplay>          <ChapString>Baby wants to bleep (pt.2)</ChapString>        </ChapterDisplay>      </ChapterAtom>      <ChapterAtom>        <ChapterUID>5</ChapterUID>        <ChapterTimeStart>633000000</ChapterTimeStart>        <ChapterTimeEnd>748000000</ChapterTimeEnd>        <ChapterDisplay>          <ChapString>Baby wants to bleep (pt.3)</ChapString>        </ChapterDisplay>      </ChapterAtom>    </ChapterAtom>    <ChapterAtom>      <ChapterUID>6</ChapterUID>      <ChapterTimeStart>750000000</ChapterTimeStart>      <ChapterTimeEnd>1178500000</ChapterTimeEnd>      <ChapterDisplay>        <ChapString>Bleeper_O+2</ChapString>      </ChapterDisplay>    </ChapterAtom>    <ChapterAtom>      <ChapterUID>7</ChapterUID>      <ChapterTimeStart>1180500000</ChapterTimeStart>      <ChapterTimeEnd>1340000000</ChapterTimeEnd>      <ChapterDisplay>        <ChapString>Baby wants to bleep (pt.4)</ChapString>      </ChapterDisplay>    </ChapterAtom>    <ChapterAtom>      <ChapterUID>8</ChapterUID>      <ChapterTimeStart>1342000000</ChapterTimeStart>      <ChapterTimeEnd>1518000000</ChapterTimeEnd>      <ChapterDisplay>        <ChapString>Bleep to bleep</ChapString>      </ChapterDisplay>    </ChapterAtom>    <ChapterAtom>      <ChapterUID>9</ChapterUID>      <ChapterTimeStart>1520000000</ChapterTimeStart>      <ChapterTimeEnd>2015000000</ChapterTimeEnd>      <ChapterDisplay>        <ChapString>Baby wants to bleep (k)</ChapString>      </ChapterDisplay>    </ChapterAtom>    <ChapterAtom>      <ChapterUID>10</ChapterUID>      <ChapterTimeStart>2017000000</ChapterTimeStart>      <ChapterTimeEnd>2668000000</ChapterTimeEnd>      <ChapterDisplay>        <ChapString>Bleeper</ChapString>      </ChapterDisplay>    </ChapterAtom>  </EditionEntry></Chapters>
Figure 26:Nested Chapters Example

21.Attachments

Matroska supports storage of related files and data in theAttachments element (aTop-LevelElement).Attachments elements can be used to store relatedcover art, font files, transcripts, reports, error recovery files, pictures,text-based annotations, copies of specifications, or other ancillary filesrelated to theSegment.

Matroska ReadersMUST NOT execute files stored asAttachments elements.

21.1.Cover Art

This section defines a set of guidelines for the storage of cover art inMatroska files. AMatroska ReaderMAY use embeddedcover art to display a representational still-image depiction of themultimedia contents of the Matroska file.

Only[JPEG] and PNG[RFC2083] image formatsSHOULD be used for cover art pictures.

There can be two different covers for a movie/album: a portrait style (e.g., a DVD case)and a landscape style (e.g., a wide banner ad).

There can be two versions of the same cover: thenormal cover andthesmall cover. The dimension of thenormal coverSHOULD be 600 pixels on the smallest side (e.g., 960x600 forlandscape, 600x800 for portrait, or 600x600 for square). The dimension of thesmall coverSHOULD be 120 pixels on the smallest side(e.g., 192x120 or 120x160).

Versions of cover art can be differentiated by the filename, which isstored in theFileName element. The default filename of thenormal cover in square or portrait mode iscover.(jpg|png). When stored, thenormal coverSHOULD be the firstAttachments element in storageorder. Thesmall coverSHOULD be prefixed with"small_", such assmall_cover.(jpg|png). The landscape variantSHOULD be suffixed with "_land", such ascover_land.(jpg|png). The filenames are case-sensitive.

The following table provides examples of file names for cover art inAttachments.

Table 52:Cover Art Filenames
File NameImage OrientationPixel Length of Smallest Side
cover.jpgPortrait or square600
small_cover.pngPortrait or square120
cover_land.pngLandscape600
small_cover_land.jpgLandscape120

21.2.Font Files

Font filesMAY be added to a Matroska file as Attachments so that the font file may be usedto display an associated subtitle track. This allows the presentation of a Matroska file to beconsistent in various environments where the needed fonts might not be available on the local system.

Depending on the font format in question, each font file can contain multiple font variants.Each font variant has a name that will be referred to as Font Name from now on.This Font Name can be different from the Attachment'sFileName, even when disregarding the extension.In order to select a font for display, aMatroska PlayerSHOULD consider both the Font Nameand the base name of the Attachment'sFileName, preferring the former when there are multiple matches.

Subtitle codecs, such as SubStation Alpha (SSA) and Advanced SubStation Alpha (ASS), usually refer to a font by its Font Name, not by its filename.If none of the Attachments are a match for the Font Name, theMatroska PlayerSHOULDattempt to find a system font whose Font Name matches the one used in the subtitle track.

Since loading fonts temporarily can take a while, aMatroska Player usuallyloads or installs all the fonts found in attachments so they are ready to be used during playback.Failure to use the font attachment might result in incorrect rendering of the subtitles.

If a selected subtitle track has someAttachmentLink elements, the playerMAY restrict its font rendering to use only these fonts.

AMatroska PlayerSHOULD handle the official font media types from[RFC8081] when the system can handle the type:

  • font/sfnt: Generic SFNT Font Type

  • font/ttf: TrueType Font (TTF) Font Type

  • font/otf: OpenType Layout (OTF) Font Type

  • font/collection: Collection Font Type

  • font/woff: WOFF 1.0

  • font/woff2: WOFF 2.0

Fonts in Matroska existed long before[RFC8081]. A few unofficial media types for fonts were used in existing files.Therefore, it isRECOMMENDED for aMatroska Player to support the following legacy media types for font attachments:

  • application/x-truetype-font: TrueType fonts, equivalent tofont/ttf and sometimesfont/otf

  • application/x-font-ttf: TrueType fonts, equivalent tofont/ttf

  • application/vnd.ms-opentype: OpenType Layout fonts, equivalent tofont/otf

  • application/font-sfnt: Generic SFNT Font Type, equivalent tofont/sfnt

  • application/font-woff: WOFF 1.0, equivalent tofont/woff

There may also be some font attachments with theapplication/octet-stream media type.In that case, theMatroska PlayerMAY try to guess the font type by checking the file extension of theAttachedFile\FileName string.Common file extensions for fonts are:

  • .ttf for TrueType fonts, equivalent tofont/ttf

  • .otf for OpenType Layout fonts, equivalent tofont/otf

  • .ttc for Collection fonts, equivalent tofont/collection

The file extension checkMUST be case-insensitive.

Matroska WritersSHOULD use a valid font media type from[RFC8081] in theAttachedFile\FileMediaType of the font attachment.TheyMAY use the media types found in older files when compatibility with older players is necessary.

22.Cues

TheCues element provides an index of certainClusterelements to allow for optimized seeking to absolute timestamps within theSegment. TheCues element contains one or manyCuePoint elements, each of whichMUST reference anabsolute timestamp (via theCueTime element), aTrack (viatheCueTrack element), and aSegment Position (via theCueClusterPosition element). Additional non-mandated elements arepart of theCuePoint element, such asCueDuration,CueRelativePosition,CueCodecState, and others that provideanyMatroska Reader with additional information to use in theoptimization of seeking performance.

22.1.Recommendations

The following recommendations are provided to optimize Matroska performance.

  • Unless Matroska is used as a live stream, itSHOULD contain aCues element.

  • For each video track, each keyframeSHOULD be referenced by aCuePoint element.

  • It isRECOMMENDED to not reference non-keyframes of video tracks inCues unlessit references aCluster element that contains aCodecState element but no keyframes.

  • For each subtitle track present, each subtitle frameSHOULD be referenced by aCuePoint element with aCueDuration element.

  • References to audio tracksMAY be skipped inCuePoint elements if a video trackis present. When included, theCuePoint elementsSHOULD reference audio keyframesonce every 500 milliseconds at most.

  • If the referenced frame is not stored within the firstSimpleBlock or firstBlockGroup within itsCluster element, then theCueRelativePosition elementSHOULD be written to reference where in theCluster the reference frame is stored.

  • If aCuePoint element references aCluster element that includes aCodecState element,then thatCuePoint elementMUST use aCueCodecState element.

  • CuePoint elementsSHOULD be numerically sorted in storage order by the value of theCueTime element.

23.Matroska Streaming

In Matroska, there are two kinds of streaming: file access and livestreaming.

23.1.File Access

File access can simply be reading a file located on your computer, but it also includesaccessing a file from an HTTP (web) server or Common Internet File System (CIFS) (Windows share) server. These protocolsare usually safe from reading errors, and seeking in the stream is possible. However,when a file is stored far away or on a slow server, seeking can be an expensive operationand should be avoided.When followed, the guidelines inSection 25 help reduce the number ofseeking operations for regular playback and also have the playback startquickly without needing to read lot of data first (like aCues element,Attachments element, orSeekHead element).

Matroska, having a small overhead, is well suited for storing music/videos on fileservers without a big impact on the bandwidth used. Matroska does not require the indexto be loaded before playing, which allows playback to start very quickly. The index canbe loaded only when seeking is requested the first time.

23.2.Livestreaming

Livestreaming is the equivalent of television broadcasting on the Internet. There are twofamilies of servers for livestreaming: RTP / Real-Time Streaming Protocol (RTSP) and HTTP. Matroska is not meant to beused over RTP. RTP already has timing and channel mechanisms that would be wasted if doubledin Matroska. Additionally, having the same information at the RTP and Matroska level wouldbe a source of confusion if they do not match.Livestreaming of Matroska over file-like protocols like HTTP, QUIC, etc., is possible.

A live Matroska stream is different from a file because it usually has noknown end (only ending when the client disconnects). For this, all bits of the"size" portion of theSegment elementMUST be set to1. Another option is to concatenateSegment elements with knownsizes, one after the other. This solution allows a change of codec/resolutionbetween each segment. For example, this allows for a switch between 4:3 and16:9 in a television program.

WhenSegment elements are continuous, certain elements (likeSeekHead,Cues,Chapters, andAttachments)MUST NOT be used.

It is possible for aMatroska Player to detect that a stream isnot seekable. If the stream has neither aSeekHead list nor aCues list at the beginning of the stream, itSHOULD beconsidered non-seekable. Even though it is possible to seek forward in thestream, it isNOT RECOMMENDED.

In the context of live radio or web TV, it is possible to "tag" the content while it isplaying. TheTags element can be placed betweenClusters each time it is necessary.In that case, the newTags elementMUST reset the previously encounteredTags elementsand use the new values instead.

24.Tags

24.1.Tags Precedence

Tags allow tagging all kinds of Matroska parts with very detailed metadata in multiple languages.

Some Matroska elements also contain their own string value, like the trackName element (Section 5.1.4.1.18) or theChapString element (Section 5.1.7.1.4.10).

The following Matroska elements can also be defined with tags:

When both values exist in the file, the value found in Tags takes precedence over the value found in the original location of the element.For example, if you have aTrackEntry\Name element and a tag valueTITLE for that track in a MatroskaSegment, the tag value stringSHOULD be used instead of theTrackEntry\Name string to identify the track.

As the Tag element is optional, a lot ofMatroska Readers do nothandle it and will not use the tags value when it's found. Thus, for maximumcompatibility, it's usually better to put the strings in theTrackEntry,ChapterAtom, andAttachments elementsand keep the tags matching these values if tags are also used.

24.2.Tag Levels

Tag elements allow tagging information on multiple levels, with each level having aTargetTypeValue (Section 5.1.8.1.1.1).An element for a givenTargetTypeValue also applies to the lower levels denoted by smallerTargetTypeValue values. If an upper valuedoesn't apply to a level but the actual value to use is not known,an emptyTagString (Section 5.1.8.1.2.5) or an emptyTagBinary (Section 5.1.8.1.2.6)MUST be used as the tag value for this level.

See[MatroskaTags] for more details on common tag names, types, and descriptions.

25.Implementation Recommendations

25.1.Cluster

It isRECOMMENDED that each individualCluster element contain no more thanfive seconds or five megabytes of content.

25.2.SeekHead

It isRECOMMENDED that the firstSeekHead element be followed by aVoid element toallow for theSeekHead element to be expanded to cover newTop-Level Elementsthat could be added to the Matroska file, such asTags,Chapters, andAttachments elements.

The size of thisVoid element should be adjusted depending on theTags,Chapters, andAttachments elements in the Matroska file.

25.3.Optimum Layouts

While there can beTop-Level Elements in any order, some orderings of elements are better than others.The following subsections detail optimum layouts for different use cases.

25.3.1.Optimum Layout for a Muxer

This is the basic layout muxers should be using for an efficient playback experience:

25.3.2.Optimum Layout after Editing Tags

When tags from the previous layout need to be extended, they are moved to the end with the extra information.The location where the old tags were located is voided.

25.3.3.Optimum Layout with Cues at the Front

Cues are usually a big chunk of data referencing a lot of locations in the file.Players that want to seek in the file need to seek to the end of the fileto access these locations. It is often better if they are placed early in the file.On the other hand, that means players that don't intend to seek will have to read/skipthese data no matter what.

Because theCues reference locations further in the file, it's often complicated toallocate the proper space for that element before all the locations are known.Therefore, this layout is rarely used:

25.3.4.Optimum Layout for Livestreaming

In livestreaming (Section 23.2), only a few elements make sense. For example,SeekHead andCues are useless.All elements other than theClustersMUST be placed before theClusters.

  • Info
  • Tracks
  • Attachments (rare)
  • Tags
  • Clusters

26.Security Considerations

Matroska inherits security considerations from EBML[RFC8794].

Attacks on aMatroska Reader could include:

The same error handling done for EBML applies to Matroska files.Particular error handling is not covered in this specification, as this isdepends on the goal of theMatroska Readers.Matroska Readers decide how to handle the errors whether or not they arerecoverable in their code.For example, if the checksum of the\Segment\Tracks is invalid, somecould decide to try to read the data anyway, some will just reject the file,and most will not even check it.

Matroska Reader implementations need to be robust against malicious payloads. Those related to denial of service are outlined inSection 2.1 of [RFC4732].

Although rarer, the same may apply to aMatroska Writer. Malicious stream datamust not cause theMatroska Writer to misbehave, as this might allow an attacker accessto transcoding gateways.

As an audio/video container format, a Matroska file or stream willpotentially encapsulate numerous byte streams created with a variety ofcodecs. Implementers will need to consider the security considerations ofthese encapsulated formats.

27.IANA Considerations

27.1.Matroska Element IDs Registry

IANA has created a new registry called the "Matroska Element IDs"registry.

To register a new Element ID in this registry, one needs an Element ID, anElement Name, a Change Controller, and anoptional Reference to a document describing the Element ID.

Element IDs are encodedusing the VINT mechanism described inSection 4 of [RFC8794] and can be betweenone and five octets long. Five-octet Element IDs are possibleonly if declared in the EBML Header.

Element IDs are described inSection 5 of [RFC8794], with the changes in[Err7189] and[Err7191].

One-octet Matroska Element IDs (range 0x80-0xFE) are to be allocated according to the "RFC Required" policy[RFC8126].

Two-octet Matroska Element IDs (range 0x407F-0x7FFE) are to be allocated according to the "Specification Required" policy[RFC8126].

Two-octet Matroska Element IDs between 0x0100 and 0x407E are not valid foruse as an Element ID.

Three-octet (range 0x203FFF-0x3FFFFE) and four-octet Matroska Element IDs (range 0x101FFFFF-0x1FFFFFFE) are to be allocated according to the "First Come First Served" policy[RFC8126].

Three-octet Matroska Element IDs between 0x010000 and 0x203FFE are not valid for use as an Element ID.

Four-octet Matroska Element IDs between 0x01000000 and 0x101FFFFE are not valid for use as an Element ID.

The allowed values in the "Matroska Element IDs" registry are similar to the ones foundin the "EBML Element IDs" registry defined inSection 17.1 of [RFC8794].

EBML Element IDs defined for the EBML Header -- as defined inSection 17.1 of [RFC8794] --MUST NOT be used as Matroska Element IDs.

Given the scarcity of one-octet Element IDs, they should only be createdto save space for elements found many times in a file (for example,BlockGrouporChapters). The four-octet Element IDs are mostly for synchronization oflarge elements. They should only be used for such high-level elements.Elements that are not expected to be used often should use three-octet ElementIDs.

Elements found inAppendix A have an assigned Matroska Element ID for historical reasons.These elements are not in use andSHOULD NOT be reused unless there are no other IDs available with the desired size.Such IDs are marked as "Reclaimed" in the "Matroska Element IDs" registry, as they could be used for other things in the future.

Table 53 shows the initial contents of the"Matroska Element IDs" registry. The Change Controller for the initialentries is the IETF.

Table 53:Initial Contents of "Matroska Element IDs" Registry
Element IDElement NameReference
0x80ChapterDisplayRFC 9559,Section 5.1.7.1.4.9
0x83TrackTypeRFC 9559,Section 5.1.4.1.3
0x85ChapStringRFC 9559,Section 5.1.7.1.4.10
0x86CodecIDRFC 9559,Section 5.1.4.1.21
0x88FlagDefaultRFC 9559,Section 5.1.4.1.5
0x8ESlicesReclaimed (RFC 9559,Appendix A.5)
0x91ChapterTimeStartRFC 9559,Section 5.1.7.1.4.3
0x92ChapterTimeEndRFC 9559,Section 5.1.7.1.4.4
0x96CueRefTimeRFC 9559,Section 5.1.5.1.2.8
0x97CueRefClusterReclaimed (RFC 9559,Appendix A.37)
0x98ChapterFlagHiddenRFC 9559,Section 5.1.7.1.4.5
0x9AFlagInterlacedRFC 9559,Section 5.1.4.1.28.1
0x9BBlockDurationRFC 9559,Section 5.1.3.5.3
0x9CFlagLacingRFC 9559,Section 5.1.4.1.12
0x9DFieldOrderRFC 9559,Section 5.1.4.1.28.2
0x9FChannelsRFC 9559,Section 5.1.4.1.29.3
0xA0BlockGroupRFC 9559,Section 5.1.3.5
0xA1BlockRFC 9559,Section 5.1.3.5.1
0xA2BlockVirtualReclaimed (RFC 9559,Appendix A.3)
0xA3SimpleBlockRFC 9559,Section 5.1.3.4
0xA4CodecStateRFC 9559,Section 5.1.3.5.6
0xA5BlockAdditionalRFC 9559,Section 5.1.3.5.2.2
0xA6BlockMoreRFC 9559,Section 5.1.3.5.2.1
0xA7PositionRFC 9559,Section 5.1.3.2
0xAACodecDecodeAllReclaimed (RFC 9559,Appendix A.22)
0xABPrevSizeRFC 9559,Section 5.1.3.3
0xAETrackEntryRFC 9559,Section 5.1.4.1
0xAFEncryptedBlockReclaimed (RFC 9559,Appendix A.15)
0xB0PixelWidthRFC 9559,Section 5.1.4.1.28.6
0xB2CueDurationRFC 9559,Section 5.1.5.1.2.4
0xB3CueTimeRFC 9559,Section 5.1.5.1.1
0xB5SamplingFrequencyRFC 9559,Section 5.1.4.1.29.1
0xB6ChapterAtomRFC 9559,Section 5.1.7.1.4
0xB7CueTrackPositionsRFC 9559,Section 5.1.5.1.2
0xB9FlagEnabledRFC 9559,Section 5.1.4.1.4
0xBAPixelHeightRFC 9559,Section 5.1.4.1.28.7
0xBBCuePointRFC 9559,Section 5.1.5.1
0xC0TrickTrackUIDReclaimed (RFC 9559,Appendix A.28)
0xC1TrickTrackSegmentUIDReclaimed (RFC 9559,Appendix A.29)
0xC4TrickMasterTrackSegmentUIDReclaimed (RFC 9559,Appendix A.32)
0xC6TrickTrackFlagReclaimed (RFC 9559,Appendix A.30)
0xC7TrickMasterTrackUIDReclaimed (RFC 9559,Appendix A.31)
0xC8ReferenceFrameReclaimed (RFC 9559,Appendix A.12)
0xC9ReferenceOffsetReclaimed (RFC 9559,Appendix A.13)
0xCAReferenceTimestampReclaimed (RFC 9559,Appendix A.14)
0xCBBlockAdditionIDReclaimed (RFC 9559,Appendix A.9)
0xCCLaceNumberReclaimed (RFC 9559,Appendix A.7)
0xCDFrameNumberReclaimed (RFC 9559,Appendix A.8)
0xCEDelayReclaimed (RFC 9559,Appendix A.10)
0xCFSliceDurationReclaimed (RFC 9559,Appendix A.11)
0xD7TrackNumberRFC 9559,Section 5.1.4.1.1
0xDBCueReferenceRFC 9559,Section 5.1.5.1.2.7
0xE0VideoRFC 9559,Section 5.1.4.1.28
0xE1AudioRFC 9559,Section 5.1.4.1.29
0xE2TrackOperationRFC 9559,Section 5.1.4.1.30
0xE3TrackCombinePlanesRFC 9559,Section 5.1.4.1.30.1
0xE4TrackPlaneRFC 9559,Section 5.1.4.1.30.2
0xE5TrackPlaneUIDRFC 9559,Section 5.1.4.1.30.3
0xE6TrackPlaneTypeRFC 9559,Section 5.1.4.1.30.4
0xE7TimestampRFC 9559,Section 5.1.3.1
0xE8TimeSliceReclaimed (RFC 9559,Appendix A.6)
0xE9TrackJoinBlocksRFC 9559,Section 5.1.4.1.30.5
0xEACueCodecStateRFC 9559,Section 5.1.5.1.2.6
0xEBCueRefCodecStateReclaimed (RFC 9559,Appendix A.39)
0xEDTrackJoinUIDRFC 9559,Section 5.1.4.1.30.6
0xEEBlockAddIDRFC 9559,Section 5.1.3.5.2.3
0xF0CueRelativePositionRFC 9559,Section 5.1.5.1.2.3
0xF1CueClusterPositionRFC 9559,Section 5.1.5.1.2.2
0xF7CueTrackRFC 9559,Section 5.1.5.1.2.1
0xFAReferencePriorityRFC 9559,Section 5.1.3.5.4
0xFBReferenceBlockRFC 9559,Section 5.1.3.5.5
0xFDReferenceVirtualReclaimed (RFC 9559,Appendix A.4)
0xFFReservedRFC 9559
0x0100-0x407ENot valid for use as an Element IDRFC 9559,Section 27.1
0x41A4BlockAddIDNameRFC 9559,Section 5.1.4.1.17.2
0x41E4BlockAdditionMappingRFC 9559,Section 5.1.4.1.17
0x41E7BlockAddIDTypeRFC 9559,Section 5.1.4.1.17.3
0x41EDBlockAddIDExtraDataRFC 9559,Section 5.1.4.1.17.4
0x41F0BlockAddIDValueRFC 9559,Section 5.1.4.1.17.1
0x4254ContentCompAlgoRFC 9559,Section 5.1.4.1.31.6
0x4255ContentCompSettingsRFC 9559,Section 5.1.4.1.31.7
0x437CChapLanguageRFC 9559,Section 5.1.7.1.4.11
0x437DChapLanguageBCP47RFC 9559,Section 5.1.7.1.4.12
0x437EChapCountryRFC 9559,Section 5.1.7.1.4.13
0x4444SegmentFamilyRFC 9559,Section 5.1.2.7
0x4461DateUTCRFC 9559,Section 5.1.2.11
0x447ATagLanguageRFC 9559,Section 5.1.8.1.2.2
0x447BTagLanguageBCP47RFC 9559,Section 5.1.8.1.2.3
0x4484TagDefaultRFC 9559,Section 5.1.8.1.2.4
0x4485TagBinaryRFC 9559,Section 5.1.8.1.2.6
0x4487TagStringRFC 9559,Section 5.1.8.1.2.5
0x4489DurationRFC 9559,Section 5.1.2.10
0x44B4TagDefaultBogusReclaimed (RFC 9559,Appendix A.43)
0x450DChapProcessPrivateRFC 9559,Section 5.1.7.1.4.16
0x45A3TagNameRFC 9559,Section 5.1.8.1.2.1
0x45B9EditionEntryRFC 9559,Section 5.1.7.1
0x45BCEditionUIDRFC 9559,Section 5.1.7.1.1
0x45DBEditionFlagDefaultRFC 9559,Section 5.1.7.1.2
0x45DDEditionFlagOrderedRFC 9559,Section 5.1.7.1.3
0x465CFileDataRFC 9559,Section 5.1.6.1.4
0x4660FileMediaTypeRFC 9559,Section 5.1.6.1.3
0x4661FileUsedStartTimeReclaimed (RFC 9559,Appendix A.41)
0x4662FileUsedEndTimeReclaimed (RFC 9559,Appendix A.42)
0x466EFileNameRFC 9559,Section 5.1.6.1.2
0x4675FileReferralReclaimed (RFC 9559,Appendix A.40)
0x467EFileDescriptionRFC 9559,Section 5.1.6.1.1
0x46AEFileUIDRFC 9559,Section 5.1.6.1.5
0x47E1ContentEncAlgoRFC 9559,Section 5.1.4.1.31.9
0x47E2ContentEncKeyIDRFC 9559,Section 5.1.4.1.31.10
0x47E3ContentSignatureReclaimed (RFC 9559,Appendix A.33)
0x47E4ContentSigKeyIDReclaimed (RFC 9559,Appendix A.34)
0x47E5ContentSigAlgoReclaimed (RFC 9559,Appendix A.35)
0x47E6ContentSigHashAlgoReclaimed (RFC 9559,Appendix A.36)
0x47E7ContentEncAESSettingsRFC 9559,Section 5.1.4.1.31.11
0x47E8AESSettingsCipherModeRFC 9559,Section 5.1.4.1.31.12
0x4D80MuxingAppRFC 9559,Section 5.1.2.13
0x4DBBSeekRFC 9559,Section 5.1.1.1
0x5031ContentEncodingOrderRFC 9559,Section 5.1.4.1.31.2
0x5032ContentEncodingScopeRFC 9559,Section 5.1.4.1.31.3
0x5033ContentEncodingTypeRFC 9559,Section 5.1.4.1.31.4
0x5034ContentCompressionRFC 9559,Section 5.1.4.1.31.5
0x5035ContentEncryptionRFC 9559,Section 5.1.4.1.31.8
0x535FCueRefNumberReclaimed (RFC 9559,Appendix A.38)
0x536ENameRFC 9559,Section 5.1.4.1.18
0x5378CueBlockNumberRFC 9559,Section 5.1.5.1.2.5
0x537FTrackOffsetReclaimed (RFC 9559,Appendix A.18)
0x53ABSeekIDRFC 9559,Section 5.1.1.1.1
0x53ACSeekPositionRFC 9559,Section 5.1.1.1.2
0x53B8StereoModeRFC 9559,Section 5.1.4.1.28.3
0x53B9OldStereoModeRFC 9559,Section 5.1.4.1.28.5
0x53C0AlphaModeRFC 9559,Section 5.1.4.1.28.4
0x54AAPixelCropBottomRFC 9559,Section 5.1.4.1.28.8
0x54B0DisplayWidthRFC 9559,Section 5.1.4.1.28.12
0x54B2DisplayUnitRFC 9559,Section 5.1.4.1.28.14
0x54B3AspectRatioTypeReclaimed (RFC 9559,Appendix A.24)
0x54BADisplayHeightRFC 9559,Section 5.1.4.1.28.13
0x54BBPixelCropTopRFC 9559,Section 5.1.4.1.28.9
0x54CCPixelCropLeftRFC 9559,Section 5.1.4.1.28.10
0x54DDPixelCropRightRFC 9559,Section 5.1.4.1.28.11
0x55AAFlagForcedRFC 9559,Section 5.1.4.1.6
0x55ABFlagHearingImpairedRFC 9559,Section 5.1.4.1.7
0x55ACFlagVisualImpairedRFC 9559,Section 5.1.4.1.8
0x55ADFlagTextDescriptionsRFC 9559,Section 5.1.4.1.9
0x55AEFlagOriginalRFC 9559,Section 5.1.4.1.10
0x55AFFlagCommentaryRFC 9559,Section 5.1.4.1.11
0x55B0ColourRFC 9559,Section 5.1.4.1.28.16
0x55B1MatrixCoefficientsRFC 9559,Section 5.1.4.1.28.17
0x55B2BitsPerChannelRFC 9559,Section 5.1.4.1.28.18
0x55B3ChromaSubsamplingHorzRFC 9559,Section 5.1.4.1.28.19
0x55B4ChromaSubsamplingVertRFC 9559,Section 5.1.4.1.28.20
0x55B5CbSubsamplingHorzRFC 9559,Section 5.1.4.1.28.21
0x55B6CbSubsamplingVertRFC 9559,Section 5.1.4.1.28.22
0x55B7ChromaSitingHorzRFC 9559,Section 5.1.4.1.28.23
0x55B8ChromaSitingVertRFC 9559,Section 5.1.4.1.28.24
0x55B9RangeRFC 9559,Section 5.1.4.1.28.25
0x55BATransferCharacteristicsRFC 9559,Section 5.1.4.1.28.26
0x55BBPrimariesRFC 9559,Section 5.1.4.1.28.27
0x55BCMaxCLLRFC 9559,Section 5.1.4.1.28.28
0x55BDMaxFALLRFC 9559,Section 5.1.4.1.28.29
0x55D0MasteringMetadataRFC 9559,Section 5.1.4.1.28.30
0x55D1PrimaryRChromaticityXRFC 9559,Section 5.1.4.1.28.31
0x55D2PrimaryRChromaticityYRFC 9559,Section 5.1.4.1.28.32
0x55D3PrimaryGChromaticityXRFC 9559,Section 5.1.4.1.28.33
0x55D4PrimaryGChromaticityYRFC 9559,Section 5.1.4.1.28.34
0x55D5PrimaryBChromaticityXRFC 9559,Section 5.1.4.1.28.35
0x55D6PrimaryBChromaticityYRFC 9559,Section 5.1.4.1.28.36
0x55D7WhitePointChromaticityXRFC 9559,Section 5.1.4.1.28.37
0x55D8WhitePointChromaticityYRFC 9559,Section 5.1.4.1.28.38
0x55D9LuminanceMaxRFC 9559,Section 5.1.4.1.28.39
0x55DALuminanceMinRFC 9559,Section 5.1.4.1.28.40
0x55EEMaxBlockAdditionIDRFC 9559,Section 5.1.4.1.16
0x5654ChapterStringUIDRFC 9559,Section 5.1.7.1.4.2
0x56AACodecDelayRFC 9559,Section 5.1.4.1.25
0x56BBSeekPreRollRFC 9559,Section 5.1.4.1.26
0x5741WritingAppRFC 9559,Section 5.1.2.14
0x5854SilentTracksReclaimed (RFC 9559,Appendix A.1)
0x58D7SilentTrackNumberReclaimed (RFC 9559,Appendix A.2)
0x61A7AttachedFileRFC 9559,Section 5.1.6.1
0x6240ContentEncodingRFC 9559,Section 5.1.4.1.31.1
0x6264BitDepthRFC 9559,Section 5.1.4.1.29.4
0x63A2CodecPrivateRFC 9559,Section 5.1.4.1.22
0x63C0TargetsRFC 9559,Section 5.1.8.1.1
0x63C3ChapterPhysicalEquivRFC 9559,Section 5.1.7.1.4.8
0x63C4TagChapterUIDRFC 9559,Section 5.1.8.1.1.5
0x63C5TagTrackUIDRFC 9559,Section 5.1.8.1.1.3
0x63C6TagAttachmentUIDRFC 9559,Section 5.1.8.1.1.6
0x63C9TagEditionUIDRFC 9559,Section 5.1.8.1.1.4
0x63CATargetTypeRFC 9559,Section 5.1.8.1.1.2
0x6624TrackTranslateRFC 9559,Section 5.1.4.1.27
0x66A5TrackTranslateTrackIDRFC 9559,Section 5.1.4.1.27.1
0x66BFTrackTranslateCodecRFC 9559,Section 5.1.4.1.27.2
0x66FCTrackTranslateEditionUIDRFC 9559,Section 5.1.4.1.27.3
0x67C8SimpleTagRFC 9559,Section 5.1.8.1.2
0x68CATargetTypeValueRFC 9559,Section 5.1.8.1.1.1
0x6911ChapProcessCommandRFC 9559,Section 5.1.7.1.4.17
0x6922ChapProcessTimeRFC 9559,Section 5.1.7.1.4.18
0x6924ChapterTranslateRFC 9559,Section 5.1.2.8
0x6933ChapProcessDataRFC 9559,Section 5.1.7.1.4.19
0x6944ChapProcessRFC 9559,Section 5.1.7.1.4.14
0x6955ChapProcessCodecIDRFC 9559,Section 5.1.7.1.4.15
0x69A5ChapterTranslateIDRFC 9559,Section 5.1.2.8.1
0x69BFChapterTranslateCodecRFC 9559,Section 5.1.2.8.2
0x69FCChapterTranslateEditionUIDRFC 9559,Section 5.1.2.8.3
0x6D80ContentEncodingsRFC 9559,Section 5.1.4.1.31
0x6DE7MinCacheReclaimed (RFC 9559,Appendix A.16)
0x6DF8MaxCacheReclaimed (RFC 9559,Appendix A.17)
0x6E67ChapterSegmentUUIDRFC 9559,Section 5.1.7.1.4.6
0x6EBCChapterSegmentEditionUIDRFC 9559,Section 5.1.7.1.4.7
0x6FABTrackOverlayReclaimed (RFC 9559,Appendix A.23)
0x7373TagRFC 9559,Section 5.1.8.1
0x7384SegmentFilenameRFC 9559,Section 5.1.2.2
0x73A4SegmentUUIDRFC 9559,Section 5.1.2.1
0x73C4ChapterUIDRFC 9559,Section 5.1.7.1.4.1
0x73C5TrackUIDRFC 9559,Section 5.1.4.1.2
0x7446AttachmentLinkRFC 9559,Section 5.1.4.1.24
0x75A1BlockAdditionsRFC 9559,Section 5.1.3.5.2
0x75A2DiscardPaddingRFC 9559,Section 5.1.3.5.7
0x7670ProjectionRFC 9559,Section 5.1.4.1.28.41
0x7671ProjectionTypeRFC 9559,Section 5.1.4.1.28.42
0x7672ProjectionPrivateRFC 9559,Section 5.1.4.1.28.43
0x7673ProjectionPoseYawRFC 9559,Section 5.1.4.1.28.44
0x7674ProjectionPosePitchRFC 9559,Section 5.1.4.1.28.45
0x7675ProjectionPoseRollRFC 9559,Section 5.1.4.1.28.46
0x78B5OutputSamplingFrequencyRFC 9559,Section 5.1.4.1.29.2
0x7BA9TitleRFC 9559,Section 5.1.2.12
0x7D7BChannelPositionsReclaimed (RFC 9559,Appendix A.27)
0x7FFFReservedRFC 9559
0x010000-0x203FFENot valid for use as an Element IDRFC 9559,Section 27.1
0x22B59CLanguageRFC 9559,Section 5.1.4.1.19
0x22B59DLanguageBCP47RFC 9559,Section 5.1.4.1.20
0x23314FTrackTimestampScaleRFC 9559,Section 5.1.4.1.15
0x234E7ADefaultDecodedFieldDurationRFC 9559,Section 5.1.4.1.14
0x2383E3FrameRateReclaimed (RFC 9559,Appendix A.26)
0x23E383DefaultDurationRFC 9559,Section 5.1.4.1.13
0x258688CodecNameRFC 9559,Section 5.1.4.1.23
0x26B240CodecDownloadURLReclaimed (RFC 9559,Appendix A.21)
0x2AD7B1TimestampScaleRFC 9559,Section 5.1.2.9
0x2EB524UncompressedFourCCRFC 9559,Section 5.1.4.1.28.15
0x2FB523GammaValueReclaimed (RFC 9559,Appendix A.25)
0x3A9697CodecSettingsReclaimed (RFC 9559,Appendix A.19)
0x3B4040CodecInfoURLReclaimed (RFC 9559,Appendix A.20)
0x3C83ABPrevFilenameRFC 9559,Section 5.1.2.4
0x3CB923PrevUUIDRFC 9559,Section 5.1.2.3
0x3E83BBNextFilenameRFC 9559,Section 5.1.2.6
0x3EB923NextUUIDRFC 9559,Section 5.1.2.5
0x3FFFFFReservedRFC 9559
0x01000000-0x101FFFFENot valid for use as an Element IDRFC 9559,Section 27.1
0x1043A770ChaptersRFC 9559,Section 5.1.7
0x114D9B74SeekHeadRFC 9559,Section 5.1.1
0x1254C367TagsRFC 9559,Section 5.1.8
0x1549A966InfoRFC 9559,Section 5.1.2
0x1654AE6BTracksRFC 9559,Section 5.1.4
0x18538067SegmentRFC 9559,Section 5.1
0x1941A469AttachmentsRFC 9559,Section 5.1.6
0x1C53BB6BCuesRFC 9559,Section 5.1.5
0x1F43B675ClusterRFC 9559,Section 5.1.3
0x1FFFFFFFReservedRFC 9559

27.2.Matroska Compression Algorithms Registry

IANA has created a new registry called the "Matroska Compression Algorithms" registry.The values correspond to the unsigned integerContentCompAlgo value described inSection 5.1.4.1.31.6.

To register a new Compression Algorithm in this registry, one needs a Compression Algorithm value,a description, a Change Controller, anda Reference to a document describing the Compression Algorithm.

The Compression Algorithms are to be allocated according to the "Specification Required" policy[RFC8126]. Available values range from 4-18446744073709551615.

Table 54 shows the initial contents of the "Matroska Compression Algorithms" registry.The Change Controller for the initial entries is the IETF.

Table 54:Initial Contents of "Matroska Compression Algorithms" Registry
Compression AlgorithmDescriptionReference
0zlibRFC 9559,Section 5.1.4.1.31.6
1bzlibRFC 9559,Section 5.1.4.1.31.6
2lzo1xRFC 9559,Section 5.1.4.1.31.6
3Header StrippingRFC 9559,Section 5.1.4.1.31.6

27.3.Matroska Encryption Algorithms Registry

IANA has created a new registry called the "Matroska Encryption Algorithms" registry.The values correspond to the unsigned integerContentEncAlgo value described inSection 5.1.4.1.31.9.

To register a new Encryption Algorithm in this registry, one needs an Encryption Algorithm value,a description, a Change Controller, andan optional Reference to a document describing the Encryption Algorithm.

The Encryption Algorithms are to be allocated according to the "First Come First Served" policy[RFC8126]. Available values range from 6-18446744073709551615.

Table 55 shows the initial contents of the "Matroska Encryption Algorithms" registry. The Change Controller for the initial entries is the IETF.

Table 55:Initial Contents of "Matroska Encryption Algorithms" Registry
Encryption AlgorithmDescriptionReference
0Not encryptedRFC 9559,Section 5.1.4.1.31.9
1DESRFC 9559,Section 5.1.4.1.31.9
23DESRFC 9559,Section 5.1.4.1.31.9
3TwofishRFC 9559,Section 5.1.4.1.31.9
4BlowfishRFC 9559,Section 5.1.4.1.31.9
5AESRFC 9559,Section 5.1.4.1.31.9

27.4.Matroska AES Cipher Modes Registry

IANA has created a new registry called the "Matroska AES Cipher Modes" registry.The values correspond to the unsigned integerAESSettingsCipherMode value described inSection 5.1.4.1.31.12.

To register a new AES Cipher Mode in this registry, one needs an AES Cipher Mode value,a description, a Change Controller, andan optional Reference to a document describing the AES Cipher Mode.

The AES Cipher Modes are to be allocated according to the "First Come First Served" policy[RFC8126]. Available values range from 3-18446744073709551615.

The value 0 is not valid for use as an AES Cipher Mode.

Table 56 shows the initial contents of the "Matroska AES Cipher Modes" registry.The Change Controller for the initial entries is the IETF.

Table 56:Initial Contents of "Matroska AES Cipher Modes" Registry
AES Cipher ModeDescriptionReference
0Not valid for use as an AES Cipher ModeRFC 9559,Section 5.1.4.1.31.12
1AES-CTRRFC 9559,Section 5.1.4.1.31.12
2AES-CBCRFC 9559,Section 5.1.4.1.31.12

27.5.Matroska Content Encoding Scopes Registry

IANA has created a new registry called the "Matroska Content Encoding Scopes" registry.The values correspond to the unsigned integerContentEncodingScope value described inSection 5.1.4.1.31.3.

To register a new Content Encoding Scope in this registry, one needs a Content Encoding Scope value,a description, a Change Controller, anda Reference to a document describing the Content Encoding Scope.

The Content Encoding Scopes are to be allocated according to the "Specification Required" policy[RFC8126]. Available values range from 0x8-0x8000000000000000.

The Content Encoding Scope is a bit-field value, so only power of 2 values can be registered.

The value 0 is not valid for use as a Content Encoding Scope.

Table 57 shows the initial contents of the "Matroska Content Encoding Scopes" registry. The Change Controller for the initial entries is the IETF.

Table 57:Initial Contents of "Matroska Content Encoding Scopes" Registry
Content Encoding ScopeDescriptionReference
0x0Not valid for use as a Content Encoding ScopeRFC 9559,Section 5.1.4.1.31.3
0x1BlockRFC 9559,Section 5.1.4.1.31.3
0x2PrivateRFC 9559,Section 5.1.4.1.31.3
0x4NextRFC 9559,Section 5.1.4.1.31.3

27.6.Matroska Content Encoding Types Registry

IANA has created a new registry called the "Matroska Content Encoding Types" registry.The values correspond to the unsigned integerContentEncodingType value described inSection 5.1.4.1.31.4.

To register a new Content Encoding Type in this registry, one needs a Content Encoding Type value,a description, a Change Controller, anda Reference to a document describing the Content Encoding Type.

The Content Encoding Types are to be allocated according to the "Specification Required" policy[RFC8126]. Available values range from 2-18446744073709551615.

Table 58 shows the initial contents of the "Matroska Content Encoding Types" registry. The Change Controller for the initial entries is the IETF.

Table 58:Initial Contents of "Matroska Content Encoding Types" Registry
Content Encoding TypeDescriptionReference
0CompressionRFC 9559,Section 5.1.4.1.31.4
1EncryptionRFC 9559,Section 5.1.4.1.31.4

27.7.Matroska Stereo Modes Registry

IANA has created a new registry called the "Matroska Stereo Modes" registry.The values correspond to the unsigned integerStereoMode value described inSection 5.1.4.1.28.3.

To register a new Stereo Mode in this registry, one needs a Stereo Mode value,a description, a Change Controller, anda Reference to a document describing the Stereo Mode.

The Stereo Modes are to be allocated according to the "Specification Required" policy[RFC8126]. Available values range from 15-18446744073709551615.

Table 59 shows the initial contents of the "Matroska Stereo Modes" registry. The Change Controller for the initial entries is the IETF.

Table 59:Initial Contents of "Matroska Stereo Modes" Registry
Stereo ModeDescriptionReference
0monoRFC 9559,Section 5.1.4.1.28.3
1side by side (left eye first)RFC 9559,Section 5.1.4.1.28.3
2top - bottom (right eye is first)RFC 9559,Section 5.1.4.1.28.3
3top - bottom (left eye is first)RFC 9559,Section 5.1.4.1.28.3
4checkboard (right eye is first)RFC 9559,Section 5.1.4.1.28.3
5checkboard (left eye is first)RFC 9559,Section 5.1.4.1.28.3
6row interleaved (right eye is first)RFC 9559,Section 5.1.4.1.28.3
7row interleaved (left eye is first)RFC 9559,Section 5.1.4.1.28.3
8column interleaved (right eye is first)RFC 9559,Section 5.1.4.1.28.3
9column interleaved (left eye is first)RFC 9559,Section 5.1.4.1.28.3
10anaglyph (cyan/red)RFC 9559,Section 5.1.4.1.28.3
11side by side (right eye first)RFC 9559,Section 5.1.4.1.28.3
12anaglyph (green/magenta)RFC 9559,Section 5.1.4.1.28.3
13both eyes laced in one Block (left eye is first)RFC 9559,Section 5.1.4.1.28.3
14both eyes laced in one Block (right eye is first)RFC 9559,Section 5.1.4.1.28.3

27.8.Matroska Alpha Modes Registry

IANA has created a new registry called the "Matroska Alpha Modes" registry.The values correspond to the unsigned integerAlphaMode value described inSection 5.1.4.1.28.4.

To register a new Alpha Mode in this registry, one needs an Alpha Mode value,a description, a Change Controller, andan optional Reference to a document describing the Alpha Mode.

The Alpha Modes are to be allocated according to the "First Come First Served" policy[RFC8126]. Available values range from 2-18446744073709551615.

Table 60 shows the initial contents of the "Matroska Alpha Modes" registry. The Change Controller for the initial entries is the IETF.

Table 60:Initial Contents of "Matroska Alpha Modes" Registry
Alpha ModeDescriptionReference
0noneRFC 9559,Section 5.1.4.1.28.4
1presentRFC 9559,Section 5.1.4.1.28.4

27.9.Matroska Display Units Registry

IANA has created a new registry called the "Matroska Display Units" registry.The values correspond to the unsigned integerDisplayUnit value described inSection 5.1.4.1.28.14.

To register a new Display Unit in this registry, one needs a Display Unit value,a description, a Change Controller, anda Reference to a document describing the Display Unit.

The Display Units are to be allocated according to the "Specification Required" policy[RFC8126]. Available values range from 5-18446744073709551615.

Table 61 shows the initial contents of the "Matroska Display Units" registry. The Change Controller for the initial entries is the IETF.

Table 61:Initial Contents of "Matroska Display Units" Registry
Display UnitDescriptionReference
0pixelsRFC 9559,Section 5.1.4.1.28.14
1centimetersRFC 9559,Section 5.1.4.1.28.14
2inchesRFC 9559,Section 5.1.4.1.28.14
3display aspect ratioRFC 9559,Section 5.1.4.1.28.14
4unknownRFC 9559,Section 5.1.4.1.28.14

27.10.Matroska Horizontal Chroma Sitings Registry

IANA has created a new registry called the "Matroska Horizontal Chroma Sitings" registry.The values correspond to the unsigned integerChromaSitingHorz value described inSection 5.1.4.1.28.23.

To register a new Horizontal Chroma Siting in this registry, one needs a Horizontal Chroma Siting value,a description, a Change Controller, andan optional Reference to a document describing the Horizontal Chroma Siting.

The Horizontal Chroma Sitings are to be allocated according to the "First Come First Served" policy[RFC8126]. Available values range from 3-18446744073709551615.

Table 62 shows the initial contents of the "Matroska Horizontal Chroma Sitings" registry.The Change Controller for the initial entries is the IETF.

Table 62:Initial Contents of "Matroska Horizontal Chroma Sitings" Registry
Horizontal Chroma SitingDescriptionReference
0unspecifiedRFC 9559,Section 5.1.4.1.28.23
1left collocatedRFC 9559,Section 5.1.4.1.28.23
2halfRFC 9559,Section 5.1.4.1.28.23

27.11.Matroska Vertical Chroma Sitings Registry

IANA has created a new registry called the "Matroska Vertical Chroma Sitings" registry.The values correspond to the unsigned integerChromaSitingVert value described inSection 5.1.4.1.28.24.

To register a new Vertical Chroma Siting in this registry, one needs a Vertical Chroma Siting value,a description, a Change Controller, andan optional Reference to a document describing the Vertical Chroma Siting.

The Vertical Chroma Sitings are to be allocated according to the "First Come First Served" policy[RFC8126]. Available values range from 3-18446744073709551615.

Table 63 shows the initial contents of the "Matroska Vertical Chroma Sitings" registry.The Change Controller for the initial entries is the IETF.

Table 63:Initial Contents of "Matroska Vertical Chroma Sitings" Registry
Vertical Chroma SitingDescriptionReference
0unspecifiedRFC 9559,Section 5.1.4.1.28.24
1top collocatedRFC 9559,Section 5.1.4.1.28.24
2halfRFC 9559,Section 5.1.4.1.28.24

27.12.Matroska Color Ranges Registry

IANA has created a new registry called the "Matroska Color Ranges" registry.The values correspond to the unsigned integerRange value described inSection 5.1.4.1.28.25.

To register a new Color Range in this registry, one needs a Color Range value,a description, a Change Controller, anda Reference to a document describing the Color Range.

The Color Ranges are to be allocated according to the "Specification Required" policy[RFC8126]. Available values range from 4-18446744073709551615.

Table 64 shows the initial contents of the "Matroska Color Ranges" registry. The Change Controller for the initial entries is the IETF.

Table 64:Initial Contents of "Matroska Color Ranges" Registry
Color RangeDescriptionReference
0unspecifiedRFC 9559,Section 5.1.4.1.28.25
1broadcast rangeRFC 9559,Section 5.1.4.1.28.25
2full range (no clipping)RFC 9559,Section 5.1.4.1.28.25
3defined by MatrixCoefficients / TransferCharacteristicsRFC 9559,Section 5.1.4.1.28.25

27.13.Matroska Tags Target Types Registry

IANA has created a new registry called the "Matroska Tags Target Types" registry.The values correspond to the unsigned integerTargetTypeValue value described inSection 5.1.8.1.1.1.

To register a new Tags Target Type in this registry, one needs a Tags Target Type value,a description, a Change Controller, anda Reference to a document describing the Tags Target Type.

The Tags Target Types are to be allocated according to the "Specification Required" policy[RFC8126]. Available values range from 1-9, 11-19, 21-29, 31-39, 41-49, 51-59, 61-69, and 71-18446744073709551615.

The value 0 is not valid for use as a Tags Target Type.

Table 65 shows the initial contents of the "Matroska Tags Target Types" registry. The Change Controller for the initial entries is the IETF.

Table 65:Initial Contents of "Matroska Tags Target Types" Registry
Tags Target TypeDescriptionReference
70COLLECTIONRFC 9559,Section 5.1.8.1.1.1
60EDITION / ISSUE / VOLUME / OPUS / SEASON / SEQUELRFC 9559,Section 5.1.8.1.1.1
50ALBUM / OPERA / CONCERT / MOVIE / EPISODERFC 9559,Section 5.1.8.1.1.1
40PART / SESSIONRFC 9559,Section 5.1.8.1.1.1
30TRACK / SONG / CHAPTERRFC 9559,Section 5.1.8.1.1.1
20SUBTRACK / MOVEMENT / SCENERFC 9559,Section 5.1.8.1.1.1
10SHOTRFC 9559,Section 5.1.8.1.1.1
0Not valid for use as a Tags Target TypeRFC 9559,Section 5.1.8.1.1.1

27.14.Matroska Chapter Codec IDs Registry

IANA has created a new registry called the "Matroska Chapter Codec IDs" registry.The values correspond to the unsigned integerChapProcessCodecID,ChapterTranslateCodec, andTrackTranslateCodec values described inSection 5.1.7.1.4.15.

To register a new Chapter Codec ID in this registry, one needs a Chapter Codec ID value,a description, a Change Controller, anda Reference to a document describing the Chapter Codec ID.

The Chapter Codec IDs are to be allocated according to the "Specification Required" policy[RFC8126]. Available values range from 2-18446744073709551615.

Table 66 shows the initial contents of the "Matroska Chapter Codec IDs" registry. The Change Controller for the initial entries is the IETF.

Table 66:Initial Contents of "Matroska Chapter Codec IDs" Registry
Chapter Codec IDDescriptionReference
0Matroska ScriptRFC 9559,Section 5.1.7.1.4.15
1DVD-menuRFC 9559,Section 5.1.7.1.4.15

27.15.Matroska Projection Types Registry

IANA has created a new registry called the "Matroska Projection Types" registry.The values correspond to the unsigned integerProjectionType value described inSection 5.1.4.1.28.42.

To register a new Projection Type in this registry, one needs a Projection Type value,a description, a Change Controller, andan optional Reference to a document describing the Projection Type.

The Projection Types are to be allocated according to the "First Come First Served" policy[RFC8126]. Available values range from 4-18446744073709551615.

Table 67 shows the initial contents of the "Matroska Projection Types" registry. The Change Controller for the initial entries is the IETF.

Table 67:Initial Contents of "Matroska Projection Types" Registry
Projection TypeDescriptionReference
0rectangularRFC 9559,Section 5.1.4.1.28.42
1equirectangularRFC 9559,Section 5.1.4.1.28.42
2cubemapRFC 9559,Section 5.1.4.1.28.42
3meshRFC 9559,Section 5.1.4.1.28.42

27.16.Matroska Track Types Registry

IANA has created a new registry called the "Matroska Track Types" registry.The values correspond to the unsigned integerTrackType value described inSection 5.1.4.1.3.

To register a new Track Type in this registry, one needs a Track Type value,a description, a Change Controller, anda Reference to a document describing the Track Type.

The Track Types are to be allocated according to the "Specification Required" policy[RFC8126]. Available values range from 4-15, 19-31, and 34-18446744073709551615.

The value 0 is not valid for use as a Track Type.

Table 68 shows the initial contents of the "Matroska Track Types" registry.The Change Controller for the initial entries is the IETF.

Table 68:Initial Contents of "Matroska Track Types" Registry
Track TypeDescriptionReference
0Not valid for use as a Track TypeRFC 9559,Section 5.1.4.1.3
1videoRFC 9559,Section 5.1.4.1.3
2audioRFC 9559,Section 5.1.4.1.3
3complexRFC 9559,Section 5.1.4.1.3
16logoRFC 9559,Section 5.1.4.1.3
17subtitleRFC 9559,Section 5.1.4.1.3
18buttonsRFC 9559,Section 5.1.4.1.3
32controlRFC 9559,Section 5.1.4.1.3
33metadataRFC 9559,Section 5.1.4.1.3

27.17.Matroska Track Plane Types Registry

IANA has created a new registry called the "Matroska Track Plane Types" registry.The values correspond to the unsigned integerTrackPlaneType value described inSection 5.1.4.1.30.4.

To register a new Track Plane Type in this registry, one needs a Track Plane Type value,a description, a Change Controller, andan optional Reference to a document describing the Track Plane Type.

The Track Plane Types are to be allocated according to the "First Come First Served" policy[RFC8126]. Available values range from 3-18446744073709551615.

Table 69 shows the initial contents of the "Matroska Track Plane Types" registry.The Change Controller for the initial entries is the IETF.

Table 69:Initial Contents of "Matroska Track Plane Types" Registry
Track Plane TypeDescriptionReference
0left eyeRFC 9559,Section 5.1.4.1.30.4
1right eyeRFC 9559,Section 5.1.4.1.30.4
2backgroundRFC 9559,Section 5.1.4.1.30.4

27.18.Media Types

Matroska files and streams are found in three main forms: audio-video,audio-only, and (occasionally) stereoscopic video.

Historically, Matroska files and streams have used the following media types with an "x-" prefix.For better compatibility, a systemSHOULD be able to handle both formats.Newer systemsSHOULD NOT use the historic format and use the format that follows the format in[RFC6838] instead.

IANA has registered three media types per the templates (see[RFC6838]) in the following subsections.

27.18.1.For Files Containing Video Tracks

Type name:
video
Subtype name:
matroska
Required parameters:
N/A
Optional parameters:
N/A
Encoding considerations:
As per RFCs 9559 and 8794
Security considerations:
SeeSection 26 of RFC 9559.
Interoperability considerations:
Due to the extensibility of Matroska, it is possible to encounter files with unknown but valid EBML Elements. Readers should be ready to handle this case. The fixed byte order, octet boundaries, and UTF-8 usage allow for broad interoperability.
Published specification:
RFC 9559
Applications that use this media type:
FFmpeg, VLC, etc.
Fragment identifier considerations:

N/A

Additional information:


Deprecated alias names for this type:
video/x-matroska
Magic number(s):
N/A
File extension(s):
mkv
Macintosh file type code(s):
N/A
Person & email address to contact for further information:
IETF CELLAR WG (cellar@ietf.org)
Intended usage:
COMMON
Restrictions on usage:
None
Author:
IETF CELLAR WG
Change controller:
IETF

27.18.2.For Files Containing Audio Tracks with No Video Tracks

Type name:
audio
Subtype name:
matroska
Required parameters:
N/A
Optional parameters:
N/A
Encoding considerations:
As per RFCs 9559 and 8794
Security considerations:
SeeSection 26 of RFC 9559.
Interoperability considerations:
Due to the extensibility of Matroska, it is possible to encounter files with unknown but valid EBML Elements. Readers should be ready to handle this case. The fixed byte order, octet boundaries, and UTF-8 usage allow for broad interoperability.
Published specification:
RFC 9559
Applications that use this media type:
FFmpeg, VLC, etc.
Fragment identifier considerations:
N/A
Additional information:


Deprecated alias names for this type:
audio/x-matroska
Magic number(s):
N/A
File extension(s):
mka
Macintosh file type code(s):
N/A
Person & email address to contact for further information:
IETF CELLAR WG (cellar@ietf.org)
Intended usage:
COMMON
Restrictions on usage:
None
Author:
IETF CELLAR WG
Change controller:
IETF

27.18.3.For Files Containing a Stereoscopic Video Track

Type name:
video
Subtype name:
matroska-3d
Required parameters:
N/A
Optional parameters:
N/A
Encoding considerations:
As per RFCs 9559 and 8794
Security considerations:
SeeSection 26 of RFC 9559.
Interoperability considerations:
Due to the extensibility of Matroska, it is possible to encounter files with unknown but valid EBML Elements. Readers should be ready to handle this case. The fixed byte order, octet boundaries, and UTF-8 usage allow for broad interoperability.
Published specification:
RFC 9559
Applications that use this media type:
FFmpeg, VLC, etc.
Fragment identifier considerations:
N/A
Additional information:


Deprecated alias names for this type:
video/x-matroska-3d
Magic number(s):
N/A
File extension(s):
mk3d
Macintosh file type code(s):
N/A
Person & email address to contact for further information:
IETF CELLAR WG (cellar@ietf.org)
Intended usage:
COMMON
Restrictions on usage:
None
Author:
IETF CELLAR WG
Change controller:
IETF

28.References

28.1.Normative References

[CIE-1931]
Wikipedia,"CIE 1931 color space",<https://en.wikipedia.org/w/index.php?title=CIE_1931_color_space&oldid=1242811504>.
[ISO639-2]
International Organization for Standardization,"Codes for the Representation of Names of Languages",ISO 639-2,,<https://www.loc.gov/standards/iso639-2/php/code_list.php>.
[ISO9899]
International Organization for Standardization,"Information technology -- Programming languages -- C",ISO/IEC 9899:2018,,<https://www.iso.org/standard/74528.html>.
[ITU-H.273]
ITU-T,"Coding-independent code points for video signal type identification",ITU-T Recommendation H.273,,<https://www.itu.int/rec/T-REC-H.273-202309-P/en>.
[RFC1950]
Deutsch, P. andJ. Gailly,"ZLIB Compressed Data Format Specification version 3.3",RFC 1950,DOI 10.17487/RFC1950,,<https://www.rfc-editor.org/info/rfc1950>.
[RFC2119]
Bradner, S.,"Key words for use in RFCs to Indicate Requirement Levels",BCP 14,RFC 2119,DOI 10.17487/RFC2119,,<https://www.rfc-editor.org/info/rfc2119>.
[RFC5646]
Phillips, A., Ed. andM. Davis, Ed.,"Tags for Identifying Languages",BCP 47,RFC 5646,DOI 10.17487/RFC5646,,<https://www.rfc-editor.org/info/rfc5646>.
[RFC6838]
Freed, N.,Klensin, J., andT. Hansen,"Media Type Specifications and Registration Procedures",BCP 13,RFC 6838,DOI 10.17487/RFC6838,,<https://www.rfc-editor.org/info/rfc6838>.
[RFC8081]
Lilley, C.,"The "font" Top-Level Media Type",RFC 8081,DOI 10.17487/RFC8081,,<https://www.rfc-editor.org/info/rfc8081>.
[RFC8126]
Cotton, M.,Leiba, B., andT. Narten,"Guidelines for Writing an IANA Considerations Section in RFCs",BCP 26,RFC 8126,DOI 10.17487/RFC8126,,<https://www.rfc-editor.org/info/rfc8126>.
[RFC8174]
Leiba, B.,"Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words",BCP 14,RFC 8174,DOI 10.17487/RFC8174,,<https://www.rfc-editor.org/info/rfc8174>.
[RFC8794]
Lhomme, S.,Rice, D., andM. Bunkus,"Extensible Binary Meta Language",RFC 8794,DOI 10.17487/RFC8794,,<https://www.rfc-editor.org/info/rfc8794>.
[RFC9562]
Davis, K.,Peabody, B., andP. Leach,"Universally Unique IDentifiers (UUIDs)",RFC 9562,DOI 10.17487/RFC9562,,<https://www.rfc-editor.org/info/rfc9562>.

28.2.Informative References

[AVIFormat]
Microsoft Corporation,"AVI RIFF File Reference",,<https://docs.microsoft.com/en-us/windows/win32/directshow/avi-riff-file-reference>.
[Blowfish]
Schneier, B.,"The Blowfish Encryption Algorithm",,<https://www.schneier.com/academic/blowfish/>.
[BZIP2]
Seward, J.,"bzip2",,<https://sourceware.org/bzip2/>.
[DivXTrickTrack]
"Smooth FF/RW",,<https://web.archive.org/web/20101222001148/http://labs.divx.com/node/16601>.
[DivXWorldFonts]
"World Fonts",,<https://web.archive.org/web/20110214132246/http://labs.divx.com/node/16602>.
[DVD-Video]
DVD Forum,"DVD-Books: Part 3 DVD-Video Book",,<http://www.dvdforum.org/>.
[Err7189]
RFC Errata,Erratum ID 7189,RFC 8794,<https://www.rfc-editor.org/errata/eid7189>.
[Err7191]
RFC Errata,Erratum ID 7191,RFC 8794,<https://www.rfc-editor.org/errata/eid7191>.
[FIPS197]
National Institute of Standards and Technology (NIST),"Advanced Encryption Standard (AES)",FIPS PUB 197,DOI 10.6028/NIST.FIPS.197,,<https://csrc.nist.gov/publications/detail/fips/197/final>.
[FIPS46-3]
National Institute of Standards and Technology (NIST),"Data Encryption Standard (DES)",FIPS PUB 46,,<https://csrc.nist.gov/publications/detail/fips/46/3/archive/1999-10-25>.
[FourCC-RGB]
FOURCC,"RGB pixel formats",<https://web.archive.org/web/20160609214806/https://www.fourcc.org/rgb.php>.
[FourCC-YUV]
FOURCC,"YUV pixel formats",<https://web.archive.org/web/20160609214806/https://www.fourcc.org/yuv.php>.
[JPEG]
ITU-T,"INFORMATION TECHNOLOGY - DIGITAL COMPRESSION AND CODING OF CONTINUOUS-TONE STILL IMAGES - REQUIREMENTS AND GUIDELINES",ITU-T Recommendation T.81,,<https://www.w3.org/Graphics/JPEG/itu-t81.pdf>.
[libmatroska]
"libmatroska",,<https://github.com/Matroska-Org/libmatroska>.
[LZO]
Tarreau, W. andR. Rodgman,"LZO stream format as understood by Linux's LZO decompressor",,<https://www.kernel.org/doc/Documentation/lzo.txt>.
[MatroskaCodec]
Lhomme, S.,Bunkus, M., andD. Rice,"Matroska Media Container Codec Specifications",Work in Progress,Internet-Draft, draft-ietf-cellar-codec-13,,<https://datatracker.ietf.org/doc/html/draft-ietf-cellar-codec-13>.
[MatroskaTags]
Lhomme, S.,Bunkus, M., andD. Rice,"Matroska Media Container Tag Specifications",Work in Progress,Internet-Draft, draft-ietf-cellar-tags-13,,<https://datatracker.ietf.org/doc/html/draft-ietf-cellar-tags-13>.
[MCF]
"MCF specification, introduction",<http://mukoli.free.fr/mcf/>.
[MSRGB]
Microsoft Corporation,"Compression Enumeration",,<https://learn.microsoft.com/en-us/openspecs/windows_protocols/ms-wmf/4e588f70-bd92-4a6f-b77f-35d0feaf7a57>.
[MSYUV16]
Microsoft Corporation,"10-bit and 16-bit YUV Video Formats",,<https://learn.microsoft.com/en-us/windows/win32/medfound/10-bit-and-16-bit-yuv-video-formats>.
[MSYUV8]
Microsoft Corporation,"Recommended 8-Bit YUV Formats for Video Rendering",,<https://learn.microsoft.com/en-us/windows/win32/medfound/recommended-8-bit-yuv-formats-for-video-rendering>.
[RFC0959]
Postel, J. andJ. Reynolds,"File Transfer Protocol",STD 9,RFC 959,DOI 10.17487/RFC0959,,<https://www.rfc-editor.org/info/rfc959>.
[RFC2083]
Boutell, T.,"PNG (Portable Network Graphics) Specification Version 1.0",RFC 2083,DOI 10.17487/RFC2083,,<https://www.rfc-editor.org/info/rfc2083>.
[RFC3533]
Pfeiffer, S.,"The Ogg Encapsulation Format Version 0",RFC 3533,DOI 10.17487/RFC3533,,<https://www.rfc-editor.org/info/rfc3533>.
[RFC4732]
Handley, M., Ed.,Rescorla, E., Ed., andIAB,"Internet Denial-of-Service Considerations",RFC 4732,DOI 10.17487/RFC4732,,<https://www.rfc-editor.org/info/rfc4732>.
[RFC9110]
Fielding, R., Ed.,Nottingham, M., Ed., andJ. Reschke, Ed.,"HTTP Semantics",STD 97,RFC 9110,DOI 10.17487/RFC9110,,<https://www.rfc-editor.org/info/rfc9110>.
[SMB-CIFS]
Microsoft Corporation,"[MS-CIFS]: Common Internet File System (CIFS) Protocol",,<https://winprotocoldoc.blob.core.windows.net/productionwindowsarchives/MS-CIFS/%5bMS-CIFS%5d.pdf>.
[SP800-38A]
National Institute of Standards and Technology (NIST),"Recommendation for Block Cipher Modes of Operation: Methods and Techniques",DOI 10.6028/NIST.SP.800-38A,NIST Special Publication 800-38A,,<https://nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublication800-38a.pdf>.
[SP800-67]
National Institute of Standards and Technology (NIST),"Recommendation for the Triple Data Encryption Algorithm (TDEA) Block Cipher",DOI 10.6028/NIST.SP.800-67r2,NIST Special Publication 800-67,,<https://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-67r2.pdf>.
[Twofish]
Schneier, B.,Kelsey, J.,Whiting, D.,Wagner, D.,Hall, C., andN. Ferguson,"Twofish: A 128-Bit Block Cipher",,<https://www.schneier.com/academic/archives/1998/06/twofish_a_128-bit_bl.html>.
[WebM-Enc]
Galligan, F.,"WebM Encryption",,<https://www.webmproject.org/docs/webm-encryption/>.
[WebVTT]
Pieters, S.,Pfeiffer, S., Ed.,Jaegenstedt, P., andI. Hickson,"WebVTT: The Web Video Text Tracks Format",W3C Candidate Recommendation,,<https://www.w3.org/TR/2019/CR-webvtt1-20190404/>.

Appendix A.Historic Deprecated Elements

As Matroska has evolved since 2002, many parts that were considered for use in the format were neverused and often incorrectly designed. Many of the elements that were defined then are notfound in any known files but were part of public specs. DivX also had a few custom elements thatwere designed for custom features.

In this appendix, we list elements that have a known ID thatSHOULD NOT be reused to avoid collidingwith existing files. These might be reassigned by IANA in the future if there are no more IDs for a given size.A short description of what each ID was used for is included, but the text is not normative.

A.1.SilentTracks Element

type / id:
master / 0x5854
path:
\Segment\Cluster\SilentTracks
documentation:
The list of tracks that are not used in that part of the stream.It is useful when using overlay tracks for seeking or deciding what track to use.

A.2.SilentTrackNumber Element

type / id:
uinteger / 0x58D7
path:
\Segment\Cluster\SilentTracks\SilentTrackNumber
documentation:
One of the track numbers that is not used from now on in the stream.It could change later if not specified as silent in a furtherCluster.

A.3.BlockVirtual Element

type / id:
binary / 0xA2
path:
\Segment\Cluster\BlockGroup\BlockVirtual
documentation:
ABlock with no data. It must be stored in the stream at the place the realBlock would be in display order.

A.4.ReferenceVirtual Element

type / id:
integer / 0xFD
path:
\Segment\Cluster\BlockGroup\ReferenceVirtual
documentation:
TheSegment Position of the data that would otherwise be in position of the virtual block.

A.5.Slices Element

type / id:
master / 0x8E
path:
\Segment\Cluster\BlockGroup\Slices
documentation:
Contains slices description.

A.6.TimeSlice Element

type / id:
master / 0xE8
path:
\Segment\Cluster\BlockGroup\Slices\TimeSlice
documentation:
Contains extra time information about the data contained in theBlock.Being able to interpret this element is not required for playback.

A.7.LaceNumber Element

type / id:
uinteger / 0xCC
path:
\Segment\Cluster\BlockGroup\Slices\TimeSlice\LaceNumber
documentation:
The reverse number of the frame in the lace (0 is the last frame, 1 is the next to last, etc.).Being able to interpret this element is not required for playback.

A.8.FrameNumber Element

type / id:
uinteger / 0xCD
path:
\Segment\Cluster\BlockGroup\Slices\TimeSlice\FrameNumber
documentation:
The number of the frame to generate from this lace with this delay(allows for the generation of many frames from the same Block/Frame).

A.9.BlockAdditionID Element

type / id:
uinteger / 0xCB
path:
\Segment\Cluster\BlockGroup\Slices\TimeSlice\BlockAdditionID
documentation:
The ID of theBlockAdditional element (0 is the mainBlock).

A.10.Delay Element

type / id:
uinteger / 0xCE
path:
\Segment\Cluster\BlockGroup\Slices\TimeSlice\Delay
documentation:
The delay to apply to the element, expressed in Track Ticks; seeSection 11.1.

A.11.SliceDuration Element

type / id:
uinteger / 0xCF
path:
\Segment\Cluster\BlockGroup\Slices\TimeSlice\SliceDuration
documentation:
The duration to apply to the element, expressed in Track Ticks; seeSection 11.1.

A.12.ReferenceFrame Element

type / id:
master / 0xC8
path:
\Segment\Cluster\BlockGroup\ReferenceFrame
documentation:
Contains information about the last reference frame. See[DivXTrickTrack].

A.13.ReferenceOffset Element

type / id:
uinteger / 0xC9
path:
\Segment\Cluster\BlockGroup\ReferenceFrame\ReferenceOffset
documentation:
The relative offset, in bytes, from the previousBlockGroup element for this Smooth FF/RW video track to the containingBlockGroupelement. See[DivXTrickTrack].

A.14.ReferenceTimestamp Element

type / id:
uinteger / 0xCA
path:
\Segment\Cluster\BlockGroup\ReferenceFrame\ReferenceTimestamp
documentation:
The timestamp of theBlockGroup pointed to by ReferenceOffset, expressed in Track Ticks; seeSection 11.1. See[DivXTrickTrack].

A.15.EncryptedBlock Element

type / id:
binary / 0xAF
path:
\Segment\Cluster\EncryptedBlock
documentation:
Similar toSimpleBlock (seeSection 10.2),but the data inside theBlock are Transformed (encrypted and/or signed).

A.16.MinCache Element

type / id:
uinteger / 0x6DE7
path:
\Segment\Tracks\TrackEntry\MinCache
documentation:
The minimum number of frames a player should be able to cache during playback.If set to 0, the reference pseudo-cache system is not used.

A.17.MaxCache Element

type / id:
uinteger / 0x6DF8
path:
\Segment\Tracks\TrackEntry\MaxCache
documentation:
The maximum cache size necessary to store referenced frames in and the current frame.0 means no cache is needed.

A.18.TrackOffset Element

type / id:
integer / 0x537F
path:
\Segment\Tracks\TrackEntry\TrackOffset
documentation:
A value to add to theBlock's Timestamp, expressed in Matroska Ticks -- i.e., in nanoseconds; seeSection 11.1.This can be used to adjust the playback offset of a track.

A.19.CodecSettings Element

type / id:
utf-8 / 0x3A9697
path:
\Segment\Tracks\TrackEntry\CodecSettings
documentation:
A string describing the encoding setting used.

A.20.CodecInfoURL Element

type / id:
string / 0x3B4040
path:
\Segment\Tracks\TrackEntry\CodecInfoURL
documentation:
A URL to find information about the codec used.

A.21.CodecDownloadURL Element

type / id:
string / 0x26B240
path:
\Segment\Tracks\TrackEntry\CodecDownloadURL
documentation:
A URL to download information about the codec used.

A.22.CodecDecodeAll Element

type / id:
uinteger / 0xAA
path:
\Segment\Tracks\TrackEntry\CodecDecodeAll
documentation:
Set to 1 if the codec can decode potentially damaged data.

A.23.TrackOverlay Element

type / id:
uinteger / 0x6FAB
path:
\Segment\Tracks\TrackEntry\TrackOverlay
documentation:
Specify that this track is an overlay track for theTrack specified (in the u-integer).This means that when this track has a gap onSilentTracks, the overlay track should be used instead. The order of multipleTrackOverlay matters; the first one is the one that should be used.If the first one is not found, it should be the second, etc.

A.24.AspectRatioType Element

type / id:
uinteger / 0x54B3
path:
\Segment\Tracks\TrackEntry\Video\AspectRatioType
documentation:
Specifies the possible modifications to the aspect ratio.

A.25.GammaValue Element

type / id:
float / 0x2FB523
path:
\Segment\Tracks\TrackEntry\Video\GammaValue
documentation:
Gamma value.

A.26.FrameRate Element

type / id:
float / 0x2383E3
path:
\Segment\Tracks\TrackEntry\Video\FrameRate
documentation:
Number of frames per second. This value is informational only. It is intended for constant frame rate streams and should not beused for a variable frame rateTrackEntry.

A.27.ChannelPositions Element

type / id:
binary / 0x7D7B
path:
\Segment\Tracks\TrackEntry\Audio\ChannelPositions
documentation:
Table of horizontal angles for each successive channel.

A.28.TrickTrackUID Element

type / id:
uinteger / 0xC0
path:
\Segment\Tracks\TrackEntry\TrickTrackUID
documentation:
TheTrackUID of the Smooth FF/RW video in the paired EBML structure corresponding to this video track. See[DivXTrickTrack].

A.29.TrickTrackSegmentUID Element

type / id:
binary / 0xC1
path:
\Segment\Tracks\TrackEntry\TrickTrackSegmentUID
documentation:
TheSegmentUUID of theSegment containing the track identified by TrickTrackUID. See[DivXTrickTrack].

A.30.TrickTrackFlag Element

type / id:
uinteger / 0xC6
path:
\Segment\Tracks\TrackEntry\TrickTrackFlag
documentation:
Set to 1 if this video track is a Smooth FF/RW track. If set to 1,MasterTrackUID andMasterTrackSegUID should be present, andBlockGroups for this track must contain ReferenceFrame structures.Otherwise, TrickTrackUID and TrickTrackSegUID must be present if this track has a corresponding Smooth FF/RW track. See[DivXTrickTrack].

A.31.TrickMasterTrackUID Element

type / id:
uinteger / 0xC7
path:
\Segment\Tracks\TrackEntry\TrickMasterTrackUID
documentation:
TheTrackUID of the video track in the paired EBML structure that corresponds to this Smooth FF/RW track. See[DivXTrickTrack].

A.32.TrickMasterTrackSegmentUID Element

type / id:
binary / 0xC4
path:
\Segment\Tracks\TrackEntry\TrickMasterTrackSegmentUID
documentation:
TheSegmentUUID of theSegment containing the track identified by MasterTrackUID. See[DivXTrickTrack].

A.33.ContentSignature Element

type / id:
binary / 0x47E3
path:
\Segment\Tracks\TrackEntry\ContentEncodings\ContentEncoding\ContentEncryption\ContentSignature
documentation:
A cryptographic signature of the contents.

A.34.ContentSigKeyID Element

type / id:
binary / 0x47E4
path:
\Segment\Tracks\TrackEntry\ContentEncodings\ContentEncoding\ContentEncryption\ContentSigKeyID
documentation:
This is the ID of the private key that the data was signed with.

A.35.ContentSigAlgo Element

type / id:
uinteger / 0x47E5
path:
\Segment\Tracks\TrackEntry\ContentEncodings\ContentEncoding\ContentEncryption\ContentSigAlgo
documentation:
The algorithm used for the signature.

A.36.ContentSigHashAlgo Element

type / id:
uinteger / 0x47E6
path:
\Segment\Tracks\TrackEntry\ContentEncodings\ContentEncoding\ContentEncryption\ContentSigHashAlgo
documentation:
The hash algorithm used for the signature.

A.37.CueRefCluster Element

type / id:
uinteger / 0x97
path:
\Segment\Cues\CuePoint\CueTrackPositions\CueReference\CueRefCluster
documentation:
TheSegment Position of theCluster containing the referencedBlock.

A.38.CueRefNumber Element

type / id:
uinteger / 0x535F
path:
\Segment\Cues\CuePoint\CueTrackPositions\CueReference\CueRefNumber
documentation:
Number of the referencedBlock of Track X in the specifiedCluster.

A.39.CueRefCodecState Element

type / id:
uinteger / 0xEB
path:
\Segment\Cues\CuePoint\CueTrackPositions\CueReference\CueRefCodecState
documentation:
TheSegment Position of the Codec State corresponding to this referenced element.0 means that the data is taken from the initialTrackEntry.

A.40.FileReferral Element

type / id:
binary / 0x4675
path:
\Segment\Attachments\AttachedFile\FileReferral
documentation:
A binary value that a track/codec can refer to when the attachment is needed.

A.41.FileUsedStartTime Element

type / id:
uinteger / 0x4661
path:
\Segment\Attachments\AttachedFile\FileUsedStartTime
documentation:
The timestamp at which this optimized font attachment comes into context, expressed in Segment Ticks, which are based onTimestampScale. See[DivXWorldFonts].

A.42.FileUsedEndTime Element

type / id:
uinteger / 0x4662
path:
\Segment\Attachments\AttachedFile\FileUsedEndTime
documentation:
The timestamp at which this optimized font attachment goes out of context, expressed in Segment Ticks, which are based onTimestampScale. See[DivXWorldFonts].

A.43.TagDefaultBogus Element

type / id:
uinteger / 0x44B4
path:
\Segment\Tags\Tag\+SimpleTag\TagDefaultBogus
documentation:
A variant of theTagDefault element with a bogus element ID; seeSection 5.1.8.1.2.4.

Authors' Addresses

Steve Lhomme
Email:slhomme@matroska.org
Moritz Bunkus
Email:moritz@bunkus.org
Dave Rice
Email:dave@dericed.com

[8]ページ先頭

©2009-2025 Movatter.jp