MPEG_transport_stream

MPEG transport stream

MPEG transport stream

Digital video format used for storage network transmission


MPEG transport stream (MPEG-TS, MTS) or simply transport stream (TS) is a standard digital container format for transmission and storage of audio, video, and Program and System Information Protocol (PSIP) data.[6] It is used in broadcast systems such as DVB, ATSC and IPTV.

Quick Facts Filename extension, Internet media type ...

Transport stream specifies a container format encapsulating packetized elementary streams, with error correction and synchronization pattern features for maintaining transmission integrity when the communication channel carrying the stream is degraded.

Transport streams differ from the similarly named MPEG program stream in several important ways: program streams are designed for reasonably reliable media, such as discs (like DVDs), while transport streams are designed for less reliable transmission, namely terrestrial or satellite broadcast. Further, a transport stream may carry multiple programs.

Transport stream is specified in MPEG-2 Part 1, Systems, formally known as ISO/IEC standard 13818-1 or ITU-T Rec. H.222.0.[4]

Overview

Multiple MPEG programs are combined then sent to a transmitting antenna. The receiver parses and decodes one of the streams.

A transport stream encapsulates a number of other substreams, often packetized elementary streams (PESs) which in turn wrap the main data stream using the MPEG codec or any number of non-MPEG codecs (such as AC3 or DTS audio, and MJPEG or JPEG 2000 video), text and pictures for subtitles, tables identifying the streams, and even broadcaster-specific information such as an electronic program guide. Many streams are often mixed together, such as several different television channels, or multiple angles of a movie.

Each stream is chopped into (at most) 188-byte sections and interleaved together. Due to the tiny packet size, streams can be interleaved with less latency and greater error resilience compared to program streams and other common containers such as AVI, MOV/MP4, and MKV, which generally wrap each frame into one packet. This is particularly important for videoconferencing, where large frames may introduce unacceptable audio delay.

Transport streams tend to be broadcast as constant bitrate (CBR) and filled with padding bytes when not enough data exists.[lower-alpha 1]

Elements

Packet

A network packet is the basic unit of data in a transport stream, and a transport stream is merely a sequence of packets. Each packet starts with a sync byte and a header, that may be followed with optional additional headers; the rest of the packet consists of payload. All header fields are read as big-endian. Packets are 188 bytes in length, but the communication medium may add additional information.[lower-alpha 2] The 188-byte packet size was originally chosen for compatibility with Asynchronous Transfer Mode (ATM) systems.[8][9]

More information Name, Number of bits ...
More information Name, Number of bits ...
More information Name, Number of bits ...
More information Name, Number of bits ...

Packet identifier (PID)

Each table or elementary stream in a transport stream is identified by a 13-bit packet identifier (PID). A demultiplexer extracts elementary streams from the transport stream in part by looking for packets identified by the same PID. In most applications, time-division multiplexing will be used to decide how often a particular PID appears in the transport stream.

More information Decimal, Hexadecimal ...

Programs

Transport stream has a concept of programs. Every program is described by a program map table (PMT). The elementary streams associated with that program have PIDs listed in the PMT. Another PID is associated with the PMT itself. For instance, a transport stream used in digital television might contain three programs, to represent three television channels. Suppose each channel consists of one video stream, one or two audio streams, and any necessary metadata. A receiver wishing to decode one of the three channels merely has to decode the payloads of each PID associated with its program. It can discard the contents of all other PIDs. A transport stream with more than one program is referred to as a multi-program transport stream (MPTS). A single program transport stream is referred to as a single-program transport stream (SPTS).

Program specific information

There are 4 program specific information (PSI) tables: program association (PAT), program map (PMT), conditional access (CAT), and network information (NIT). The MPEG-2 specification does not specify the format of the CAT and NIT.

PCR

To enable a decoder to present synchronized content, such as audio tracks matching the associated video, at least once each 100 ms, a program clock reference (PCR) is transmitted in the adaptation field of an MPEG-2 transport stream packet. The PID with the PCR for an MPEG-2 program is identified by the pcr_pid value in the associated PMT. The value of the PCR, when properly used, is employed to generate a system_timing_clock in the decoder. The system time clock (STC) decoder, when properly implemented, provides a highly accurate time base that is used to synchronize audio and video elementary streams. Timing in MPEG-2 references this clock. For example, the presentation time stamp (PTS) is intended to be relative to the PCR. The first 33 bits are based on a 90 kHz clock. The last 9 bits are based on a 27 MHz clock. The maximum jitter permitted for the PCR is +/- 500 ns.

Null packets

Some transmission schemes, such as those in ATSC and DVB, impose strict constant bitrate requirements on the transport stream. In order to ensure that the stream maintains a constant bitrate, a multiplexer may need to insert some additional packets. The PID 0x1FFF is reserved for this purpose. The payload of null packets is all zeroes, and the receiver is expected to ignore its contents.[15]

Use in digital video cameras

Transport Stream was originally designed for broadcast. Later it was adapted for use with digital video cameras, recorders and players by adding a 4-byte timecode (TC) field to the standard 188-byte packets, resulting in a 192-byte packet.[16][17] This is what is informally called M2TS stream, commonly found in HDV cameras. The Blu-ray Disc Association calls it "BDAV MPEG-2 transport stream".[16] JVC called it TOD[lower-alpha 3] when used in HDD-based camcorders like GZ-HD7.[18][19] The timecode allows quick access to any part of the stream either from a media player, or from a non-linear video editing system.[20] It is also used to synchronize video streams from several cameras in a multiple-camera setup.

Use in Blu-ray

Blu-ray Disc video titles authored with menu support are in the Blu-ray Disc Movie (BDMV) format and contain audio, video, and other streams in a BDAV container, which is based on the MPEG-2 transport stream format.[21][22] Blu-ray Disc video uses these modified MPEG-2 transport streams, compared to DVD's program streams that don't have the extra transport overhead.

There is also the BDAV (Blu-ray Disc Audio/Visual) format, the consumer-oriented alternative to the BDMV format used for movie releases. The BDAV format is used on Blu-ray Disc recordable for audio/video recording.[22][lower-alpha 4] Blu-ray Disc employs the MPEG-2 transport stream recording method. This enables transport streams of a BDAV converted digital broadcast to be recorded as they are with minimal alteration of the packets.[17] It also enables simple stream cut style editing of a BDAV converted digital broadcast that is recorded as is and where the data can be edited just by discarding unwanted packets from the stream. Although it is quite natural, a function for high-speed and easy-to-use retrieval is built in.[17][24]

See also

Notes

  1. The Blu-ray format does not require CBR.
  2. Forward error correction is added by ISDB & DVB (16 bytes) and ATSC (20 bytes),[7] while the M2TS format prefixes packets with a 4-byte copyright and timestamp tag.
  3. Possibly an abbreviation for "Transport stream on disc".
  4. Filename extension .m2ts is used on Blu-ray Disc video files which contain an incompatible BDAV MPEG-2 transport stream due to the four additional octets added to every packet.[16][23]

References

  1. "TVNT.net - Le forum de la TNT • [Topic Unique] Akira DHB-B31HDR - Double tuner enregistreur TNT HD - MKV - DIVX - DTS : Les adaptateurs pour recevoir la TNT gratuite en SD ou HD". www.tvnt.net.
  2. "mpeg2TransportStream". Apple Developer Documentation. Apple Inc.
  3. MPEG-2 Encoding Family (Full draft). Sustainability of Digital Formats. Washington, D.C.: Library of Congress. 14 February 2012. Retrieved 13 December 2021. Licenses pertain to tools and not to streams or files per se.
  4. "MPEG-2 Transport Stream". AfterDawn.com. Retrieved 8 June 2010.
  5. "ATSC transmission". Broadcastengineering.com. 20 June 2005. Retrieved 17 May 2012.
  6. "MPEG Systems FAQ". Mpeg.chiariglione.org. Retrieved 17 May 2012.
  7. "ATSC MPEG Transport Stream Monitor". Tek.com. Retrieved 17 May 2012.
  8. "TSReader". Coolstf.com. 7 April 2008. Archived from the original on 27 March 2010. Retrieved 17 May 2012.
  9. "Standards – DVB" (PDF). Dvb.org. Archived from the original (PDF) on 13 March 2011. Retrieved 11 September 2012.
  10. Fairhurst, Gorry. "MPEG-2 Transmission". Archived from the original on 13 August 2017. Retrieved 30 November 2018.
  11. "5.1.3 Coding of PID and table_id fields". Digital Video Broadcasting (DVB); Specification for Service Information (SI) in DVB systems (PDF). EN. Vol. 300 468 (v1.13.1 ed.). 2012. p. 20. Retrieved 13 October 2016. {{cite book}}: |website= ignored (help)
  12. A Guide to MPEG Fundamentals and Protocol Analysis (PDF), Tektronix, p. 37, retrieved 23 April 2020
  13. BD ROM – Audio Visual Application Format Specifications (PDF), Blu-ray Disc Association, March 2005, pp. 15–16, archived from the original (PDF) on 3 November 2020, retrieved 26 July 2009
  14. BD-RE – Audiovisual Application Format Specification for BD-RE 2.1 (PDF), Blu-ray Disc Association, March 2008, archived from the original (PDF) on 6 February 2009
  15. "How MPEG-TS works". Forum.videohelp.com. Retrieved 17 May 2012.[self-published source?]
  16. Afterdawn.com Glossary – BD-MV (Blu-ray Movie) and BDAV container Archived 18 February 2009 at the Wayback Machine, Retrieved on 26 July 2009
  17. Afterdawn.com Glossary – BDAV container, Retrieved on 26 July 2009
  18. Videohelp.com What is Blu-ray Disc and HD DVD? Archived 24 December 2009 at the Wayback Machine, Retrieved on 26 July 2009
  19. Blu-ray Disc Association (August 2004) Blu-ray Disc Format, White paper (PDF) Page 22, Retrieved on 28 July 2009

Share this article:

This article uses material from the Wikipedia article MPEG_transport_stream, and is written by contributors. Text is available under a CC BY-SA 4.0 International License; additional terms may apply. Images, videos and audio are available under their respective licenses.