TSDuck: Open-source toolkit for MPEG-TS analysis and manipulation
Source: Hacker News
Introduction
The free and open-source reference framework for MPEG transport streams.
TSDuck is used in digital television and video streaming systems for test, monitoring, integration, debug, lab, demo.
Use cases
- Transport stream acquisition or transmodulation, including DVB, ATSC, ISDB, ASI and IP multicast.
- Analyze transport streams, PSI/SI signalization, bitrates, timestamps.
- On‑the‑fly transformation, extraction, or injection of content and signalization.
- Manipulation of tables and descriptors using XML, JSON or binary formats.
- Most standard tables and descriptors are supported, as defined by MPEG, DVB, ISDB, ATSC, SCTE.
- Modify, remove, rename, extract services.
- Analyze and inject SCTE 35 splice information.
- Extract or inject Multi‑Protocol Encapsulation (MPE) between TS and UDP/IP.
- Generate Electronic Program Guide (EPG), inject EIT according to ETSI TS 101 211.
- Monitor and report conditions on the stream (video and audio properties, bitrates, crypto‑periods, signalization).
- Send bitrate and ETSI TR 101 290 metrics to InfluxDB and Grafana for system monitoring.
- Monitor Inter‑packet Arrival Time (IAT) on datagram‑based networks.
- Work on live transport streams, DVB‑S/C/T, ATSC, ISDB‑S/T, ASI, IP‑TV, HTTP, HLS, SRT, RIST or offline transport‑stream files and pcap captured files.
Hardware interfaces
- Cheap DVB, ATSC or ISDB tuners (USB, PCI).
- Professional Dektec devices, ASI, modulators (USB, PCI).
- HiDes USB modulators.
- AstroMeta‑based USB modulators (formerly VATek) such as the Suntechtv U3.
- Re‑route transport streams to other applications.
- Extract specific encapsulated data (Teletext, T2‑MI, DVB‑NIP).
- Emulate a CAS head‑end using DVB SimulCrypt interfaces to and from ECMG or EMMG.
- And more…
Overview
TSDuck is developed in C++ with a modular architecture and is easy to extend through plugins. The primary design goal was to allow implementation of new features within a few hours, which is usually achieved.
TSDuck consists of a collection of command‑line tools and plugins – there is no sophisticated GUI. Each utility or plugin performs a single elementary function, but they can be combined in any order. See some sample usages.
It also provides a large library to manipulate MPEG transport streams. C++, Java, and Python developers can use language bindings.
In short, TSDuck should be understood as a general‑purpose toolbox for digital‑TV engineers, not as a specialized production application.
TSDuck is free and open source (license).
Availability
TSDuck is open source and released under the BSD license. It is portable and built/tested on Windows, Linux, macOS, and BSD systems.
Pre‑built binary packages are available for Windows, Fedora, Ubuntu, Red Hat, Debian (Intel x64 and Arm64). See the download page.
TSDuck is also available through standard package managers:
Rebuilding TSDuck, with or without its binary installers and packages, is documented here.
Support for DVB tuners, Dektec devices, HiDes modulators is available on Windows and Linux only. AstroMeta‑based modulators are supported on macOS as well as Windows and Linux.
Please report problems or ask questions using the issue tracker.
License
TSDuck is released under the terms of the 2‑Clause BSD License (also known as Simplified BSD or FreeBSD License).
Copyright (c) 2005-2026, Thierry Lelégard
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
- Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
- Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS “AS IS” AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.