Sustainability of Digital Formats: Planning for Library of Congress Collections

Introduction | Sustainability Factors | Content Categories | Format Descriptions | Contact
Format Description Categories >> Browse Alphabetical List

Timed Text Markup Language Version 2 (TTML2)

>> Back
Table of Contents
Format Description Properties Explanation of format description terms

Identification and description Explanation of format description terms

Full name Timed Text Markup Language Version 2 (TTML2)
Description

Timed Text Markup Language Version 2 (TTML2) is an XML-based format for the interchange of timed text media, but also can be used as an authoring and distribution format. TTML2 is defined by the World Wide Web Consortium (W3C) and is specified in the Timed Text Markup Language (TTML2) (2nd Edition) W3C Recommendation Snapshot 09 March 2021 (referenced throughout this document).

TTML2 is the second version specification of the Timed Text Markup Language (TTML) W3C Recommendation standard, previously referred to as Distribution Format Exchange Profile (DFXP). TTML2 was specified by the Timed Text Working Group (TTWG) and the TTML2 W3C Recommendation First Edition was released in November 2018. See History for more information.

According to W3C Press Release, World Wide Web Consortium (W3C) to Receive Emmy ® Award for Standards Work on Accessible Video Captioning and Subtitles, January 2016, “TTML2 is the next version of TTML, published as a first public working draft in February 2015. In addition to the features introduced in IMSC1 and generally refining TTML1 features, it adds support for East Asian languages, enables stereoscopic 3D, and details the mapping to HTML and CSS.”

System Model

Per specification, TTML timed text files are designed to be used as a bidirectional interchange format for authoring systems and as a unidirectional interchange format for distribution formats. Two classes of processor are described:

  • Transformation Processors – example: authoring systems and validation processors
  • Presentation Processors – example: transcoding systems and rendering processors

TTML2 Document Instance:

A Timed Text Document Instance is a defined TTML document, per specification, “a concrete realization of a TTML document, where the concrete form is specific to the context of reference.”

Example Fragment from specification:
<tt xml:lang="" xmlns="http://www.w3.org/ns/ttml">

<head>

<metadata/>
<styling/>
<layout/>

</head>
<body/>
</tt>

Consisting of a tt (root) document element containing:

  • Header: optional, specifies document level metadata, styling definitions, and layout definitions.
    • Metadata including document title, description, and copyright information, other arbitrary information from other namespaces, i.e., information used by the processing and rendering tools.
    • Styling – may use style specification definitions that are referenced by layout and content information, i.e., desired look and feel of subtitles/captions.
    • Layout – defines one or regions where content is intended to be presented, i.e., size and location of the caption box.
  • Body: text content intermixed with references to style, layout, and timing information, the subtitles and/or captions.
    • Document Instance - organized using block and inline text elements, spatial and temporal relationships are determined by the content hierarchical organization.

TTML2 adds new definitions, profiles, elements, attributes, as well as describing forward and backward compatibility with conforming TTML1 content/processors.

The TTML2 specification defines the TTML Abstract Document Types (set of constraints that defines a class of XML Information Sets):

  • TTML Content – a TTML profile intended to be used for interchange among distribution systems. Root document element ‘tt.’
  • TTML Intermediate – used to represent TTML Content in a manner that certain information may be resolved or merged in order to simplify subsequent processing. Root document element must be ‘isd:sequence’ or ‘isd:element.’
  • TTML Profile – used for defining and communicating constraints on the support or use of TTML features or extensions. Root document element must be ‘ttp:profile.’

TTML2 specification defines the XML namespaces, profiles, and vocabulary (element/attribute catalog).

Added namespaces defined in the TTML2 specification include TT Audio, TT Intermediate Synchronic Document, and TT Resource.

TTML2 Profiles:

The specification describes TTML’s profiling sub-system and the applied requirements. Profiles have two functions: declare constraints on what and how vocabulary is used and declare content processor conditions.

  • Content profile – declares what constraints the author has applied and specified to the document instance.
  • Processor profile – declares what processing must be supported and when the processing should be aborted per the author’s requirements for the document instance.

The TTML2 specification defines the following Standard Designators:

  • DFXP Full
    • For definition see TTML1.
  • DFXP Presentation
    • For definition see TTML1.
  • DFXP Transformation
    • For definition see TTML1.
  • TTML Simple Delivery Profile for Closed Caption (SDP-US)
    • For definition see TTML Simple Delivery Profile for Closed Captions.
  • TTML2 Full
  • TTML2 Presentation
  • TTML2 Transformation

The specification defines TTML2 vocabulary, divided into two catalogs, core and extension. The core catalog defines the baseline vocabulary of TTML, in particular TTML Content. The extension catalog is a placeholder for vocabulary extensions defined by TTML.

The core catalog baseline vocabulary includes Profile, Parameter, Content, Embedded Content, Styling, Layout, Timing, Animation, and Metadata.

Added defined TTML2 elements include animate, animation, audio, chunk, data, resources, source, font, image, ttm:item, and initial.

Profile is information expressing requirements or optionality for authoring or processing.

Parameter is either essential or of significant importance for interpreting TTML Content.

Content specifies the structure and principal content.

Embedded Content is arbitrary content data or external reference embedded, audio, data, font, or image.

Styling has an extended library of visual styling attributes, additional audio styling attributes and Ruby styling.

Uses of TTML2:

W3C’s Draft Community Group Report, Proposal for an Exchange Format to Support Audio Description, May 2022, defines TTML2 as “A Markup Language designed for the storage and delivery of Timed Text, as defined in [TTML2] primarily used in the television industry. TTML is used for authoring, transcoding and exchanging timed text information and for delivering captions, subtitles, and other metadata for television material repurposed for the Web or, more generally, the Internet.”

Production phase Primarily middle state for the delivery of captions and subtitles online, but also developed for the purpose of authoring, transcoding, and exchanging time text information.
Relationship to other formats
    Defined via XML, Extensible Markup Language (XML)
    May contain CSS, Cascading Style Sheet (CSS) Markup.

CSS style specification syntax is mapped to XML by use of attributes defined in the TT Style Namespace.

Vocabulary Derivation - TTML element vocabulary items are based on the syntactic and/or semantic model defined by the reference CSS2, CSS3.

    May contain XHTML 1.0, Extensible HyperText Markup Language (XHTML).

Vocabulary Derivation - TTML element vocabulary items are based on the syntactic and/or semantic model defined by the reference XHTML 1.0.

    May contain SVG 1.1, Scalable Vector Graphics (SVG) File Format Family.

Vocabulary Derivation - TTML element vocabulary items are based on the syntactic and/or semantic model defined by the reference SVG 1.1.

    May contain MPEG 7-5, Multimedia Content Description Interface (MPEG 7-5).

Not described separately on this website at this time.

Vocabulary Derivation - TTML element vocabulary items are based on the syntactic and/or semantic model defined by the reference MPEG 7-5.

ISO/IEC 15938-1:2002 Information technology — Multimedia content description interface — Part 1: Systems.

    May contain XSL 1.1, Extensible Stylesheet Language (XSL) Version 1.1.

Not described separately on this website at this time.

Vocabulary Derivation - TTML element vocabulary items are based on the syntactic and/or semantic model defined by the reference XSL 1.1.

Extensible Stylesheet Language (XSL) Version 1.1.

    Has earlier version TTML1, Timed Text Markup Language (TTML), Version 2 (TTML2). The Timed Text Markup Language (TTML) Version 1, also referred to as TTML1.
Vocabulary Derivation TTML element vocabulary items are based on the syntactic and/or semantic model defined by the reference TTML1.
    Component of DVB-SUB, Digital Video Broadcasting; Subtitling systems (DVB-SUB). Per standard, the document "specifies the transport of TTML subtitle streams in DVB MPEG-2 transport streams, based on the MPEG-2 system described in ISO/IEC 13818-1...The present document provides syntax for delivery of TTML subtitle streams over MPEG-2 transport stream, and is based on EBU-TT-D compatible with the IMSC1 Text Profile of W3C TTML." See TTML1 for more information on the W3C's IMSC1 Text Profile.

Local use Explanation of format description terms

LC experience or existing holdings Likely exists in LC collections but not separately documented.
LC preference The Library of Congress has not defined format preferences for caption or subtitle files for moving image works in the Recommended Formats Statement.

Sustainability factors Explanation of format description terms

Disclosure Open standard and fully documented. Timed Text Markup Language 2 (TTML2) is a W3C Recommendation which is considered Web standard.
    Documentation Timed Text Markup Language 2 (TTML2) (2nd Edition) | W3C Candidate Recommendation Snapshot 09 March 2021, is the most current specification and is maintained by the W3C’s Timed Text Working Group (TTWG). The mission of TTWG is “to develop W3C Recommendations for media online captioning by developing and maintaining new versions of the Timed Text Markup Language (TTML).”
Adoption

According to Richard Lane in TTML – The XML Standard Adopted by Top Media Brands, November 2022, “TTML2, the second major revision of the language, was finalised on November 8, 2018. It has been adopted widely in the television industry, including by Society of Motion Picture and Television Engineers (SMPTE), European Broadcasting Union (EBU), Advanced Television Systems Committee (ATSC), Digital Video Broadcasting (DVB), Hybrid Broadcast Broadband TV (HbbTV) and Moving Picture Experts Group (MPEG). Several profiles and extensions of the language have been developed since the standard was published."

See TTML1

Comments welcome.

    Licensing and patents

See TTML1

Transparency

See TTML1

Self-documentation

According to the TTML2 documentation, “This specification does not define any presentation semantics for metadata; therefore, a conformant presentation processor may ignore all metadata matter... Note: Although this specification does not ascribe any presentation semantics to metadata, a superset profile of this specification may do so, in which case any metadata dependent presentation semantics defined by such a profile is considered outside the scope of this specification.”

See TTML1

Comments welcome.

External dependencies

See TTML1

Comments welcome.

Technical protection considerations

TTML2 specification Security and Privacy Considerations: “When [XML 1.0] is used as the concrete encoding of a timed text document instance, the security considerations specified by [XML Media Types] and [XML Guidelines] apply.”

See TTML1

Comments welcome.


Quality and functionality factors Explanation of format description terms

Text
Normal rendering

See TTML1

Comments welcome.

Integrity of document structure

See TTML1

Comments welcome.

Integrity of layout and display

TTML2 specification defines the added element font and the font resource that contains font information, such as glyph mapping data, glyph metrics, and/or other mapping/rendering process data.

Font styling attributes includes family, kerning, selection strategy, shear, size, style, variant, weight, letter spacing, ruby styling, and more.

Per TTML2, “Note: Authors are advised to use subset fonts wherever possible. A subset font is a syntactically valid font resource that removes unreferenced glyphs and unreferenced glyph metrics. In general, a subset font is tied to a specific document, since it may have been generated based on the actual character content of that document.”

See TTML1.

Comments welcome.

Support for mathematics, formulae, etc.

See TTML1.

Comments welcome.

Functionality beyond normal rendering

TTML2 specification defines two new animation elements, animate and animation, along with TTML1 set element. “The animate element expresses a series of changes (animations) to be applied (targeted) to one or more style property attributes of associated elements...The animation element is a container element used to group out-of-line animation (must specify an xml:id attribute) matter, including metadata that apples to animation matter...Semantics for the set and animate elements are based upon that defined by SVG 1.1, which, in turn, is based upon SMIL 3.0.”

TTML2 specification defines a new audio element and an audio resource containing coded and unencoded audio samples, as well as editable attributes gain, pan, pitch, and speak. TTML2’s #speech feature supports an optional speech synthesis component of content processors, which synthesizes audio speech rendered from text content.

See TTML1.

Comments welcome.


File type signifiers and format identifiers Explanation of format description terms

Tag Value Note
Filename extension ttml
Per specification.
See https://www.w3.org/TR/ttml1/#media-types-registration.
Filename extension dfxp
Per specification, previous drafts referred to TTML as DFXP (Distribution Format Exchange Profile), the term is retained for historical reasons in certain contexts, such as profiles and designators.See https://www.w3.org/TR/ttml1/#media-types-registration. TTML's Wikipedia page lists this as an extension.

According to Rudolf Boogerman in How to Create Captions/Subtitles for Video and Audio in WebVTT, SRT, DFXP Format, Updated March 2019, users can “save the file with an .dfxp extension, like mycaption.dfxp, but you also may use mycaption.xml since this basically is a XML file.” See Notes for more file extension information found.

Comments welcome.
Filename extension xml
TTML's Wikipedia page lists this as an extension.

According to Rudolf Boogerman in How to Create Captions/Subtitles for Video and Audio in WebVTT, SRT, DFXP Format, Updated March 2019, users can “save the file with an .dfxp extension, like mycaption.dfxp, but you also may use mycaption.xml since this basically is a XML file.” See Notes for more file extension information found.

Comments welcome.
Internet Media Type See note.  The mediatype was removed from the TTML2 specification, https://www.w3.org/TR/ttml1/#media-types-registration. See TTML1. Comments welcome.
Mac OS file type See related format.  See TTML1
Pronom PUID See note.  PRONOM has no corresponding entry as of April 2023.
Wikidata Title ID Q25339304
Wikidata entry for Timed Text Markup Language. See https://www.wikidata.org/wiki/Q25339304. Wikidata does not specify a version of TTML.

Notes Explanation of format description terms

General

Per the specification, MediaType Registration appendix has been removed from the TTML2 specification.

W3C TTML2 GitHub Issues Forum, user Plehegar commented on November 4, 2015, “When Issue-351 has been completed, add a Media Type Registration Annex to TTML2 that reflects the updated registration, similar to what’s in Annex C of TTML1.” User Skynavga replied October 29, 2016, “It has been decided that the registration annex will not be included in TTML2.”

No other Media Type Registration information was found at this time.

-

Timed Text Working Group website lists a “TTML3” under Recommendation Track Specification Repositories with a link to W3C’s GitHub page, but the README.md (February 2022) states, “IMPORTANT: Development of Timed Text Markup Language 3 (TTML3) is currently suspended.”

History

TTML2 is the second version of the Timed Text Markup Language, having its first working draft published in 2015 and its first W3C Candidate Recommendation specification released in March of 2018.

Timed Text Markup Language 2 (TTML2) (2nd Edition) | W3C Candidate Recommendation Snapshot 09 March 2021, is the most current specification and is maintained by the W3C’s Timed Text Working Group (TTWG).

-

TTML specification states, “In previous drafts of this specification, TTML was referred to as DFXP (Distribution Format Exchange Profile). This latter term is retained for historical reasons in certain contexts, such as profile names and designators.”

-

Participating Organizations of the Timed Text Working Group (TTWG) include: Adobe, Apple Inc., Brightcove, British Broadcasting Corporation, ERICSSON, Google LLC, Igalia, Kodansha, Publishers, Ltd., MovieLabs, Mux, and Netflix.


Format specifications Explanation of format description terms


Useful references

URLs


Last Updated: 05/18/2023