Skip to content
Romain Bouqueau edited this page Mar 5, 2024 · 45 revisions

Warning

GPAC's wiki has moved to wiki.gpac.io.

This github wiki will no longer be updated.

You can contribute to GPAC's documentation here.

ISOBMFF/QT demultiplexer

Register name used to load filter: mp4dmx
This filter may be automatically loaded during graph resolution.

This filter demultiplexes ISOBMF and QT files.
Input ISOBMFF/QT can be regular or fragmented, and available as files or as raw bytestream.

Track Selection

The filter can use fragment identifiers of source to select a single track for playback. The allowed fragments are:

  • #audio: only use the first audio track
  • #video: only use the first video track
  • #auxv: only use the first auxiliary video track
  • #pict: only use the first picture track
  • #text: only use the first text track
  • #trackID=VAL: only use the track with given ID
  • #itemID=VAL: only use the item with given ID
  • #ID=VAL: only use the track/item with given ID
  • #VAL: only use the track/item with given ID

Scalable Tracks

When scalable tracks are present in a file, the reader can operate in 3 modes using smode option:

  • smode=single: resolves all extractors to extract a single bitstream from a scalable set. The highest level is used
    In this mode, there is no enhancement decoder config, only a base one resulting from the merge of the layers configurations
  • smode=split: all extractors are removed and every track of the scalable set is declared. In this mode, each enhancement track has no base decoder config
    and an enhancement decoder config.
  • smode=splitx: extractors are kept in the bitstream, and every track of the scalable set is declared. In this mode, each enhancement track has a base decoder config
    (copied from base) and an enhancement decoder config. This is mostly used for DASHing content.

Warning: smode=splitx will result in extractor NAL units still present in the output bitstream, which shall only be true if the output is ISOBMFF based

Options

src (cstr): local file name of source content (only used when explicitly loading the filter)
allt (bool, default: false): load all tracks even if unknown media type
edits (enum, default: auto): do not use edit lists

  • auto: track delay and no edit list when possible
  • no: ignore edit list
  • strict: use edit list even if only signaling a delay

itt (bool, default: false): convert all items of root meta into a single PID
itemid (bool, default: true): keep item IDs in PID properties
smode (enum, default: split): load mode for scalable/tile tracks

  • split: each track is declared, extractors are removed
  • splitx: each track is declared, extractors are kept
  • single: a single track is declared (highest level for scalable, tile base for tiling)

alltk (bool, default: false): declare disabled tracks
frame_size (uint, default: 1024): frame size for raw audio samples (dispatches frame_size samples per packet)
expart (bool, default: false): expose cover art as a dedicated video PID
sigfrag (bool, default: false): signal fragment and segment boundaries of source on output packets, fails if source is not fragmented
tkid (str): declare only track based on given param

  • integer value: declares track with the given ID
  • audio: declares first audio track
  • video: declares first video track
  • 4CC: declares first track with matching 4CC for handler type

stsd (uint, default: 0): only extract sample mapped to the given sample description index (0 means extract all)
nocrypt (bool): signal encrypted tracks as non encrypted (mostly used for export)
mstore_size (uint, default: 1000000): target buffer size in bytes when reading from memory stream (pipe etc...)
mstore_purge (uint, default: 50000): minimum size in bytes between memory purges when reading from memory stream, 0 means purge as soon as possible
mstore_samples (uint, default: 50): minimum number of samples to be present before purging sample tables when reading from memory stream (pipe etc...), 0 means purge as soon as possible
strtxt (bool, default: false): load text tracks (apple/tx3g) as MPEG-4 streaming text tracks
xps_check (enum, default: auto): parameter sets extraction mode from AVC/HEVC/VVC samples

  • keep: do not inspect sample (assumes input file is compliant when generating DASH/HLS/CMAF)
  • rem: removes all inband xPS and notify configuration changes accordingly
  • auto: resolves to keep for smode=splitx (dasher mode), rem otherwise

nodata (enum, default: no): control sample data loading

  • no: regular load
  • yes: skip data loading
  • fake: allocate sample but no data copy

lightp (bool, default: false): load minimal set of properties
initseg (str): local init segment name when input is a single ISOBMFF segment

HOME » Filters

Filters Overview

General Filters Concepts
gpac General Usage
Built-in Properties

GPAC Configuration

Configuration File
Global Options
Logging

Filters Help

Inspect packets (inspect)
Probe source (probe)
Compositor (compositor)
ISOBMFF/QT demultiplexer (mp4dmx)
MPEG-4 BIFS decoder (bifsdec)
MPEG-4 OD decoder (odfdec)
File input (fin)
BT/XMT/X3D loader (btplay)
HTTP input (httpin)
SVG loader (svgplay)
JPG/J2K/PNG/BMP reframer (rfimg)
PNG/JPG decoder (imgdec)
ADTS reframer (rfadts)
LATM reframer (rflatm)
MP3 reframer (rfmp3)
FAAD decoder (faad)
MAD decoder (maddec)
OpenJPEG2000 decoder (j2kdec)
AC3 reframer (rfac3)
A52 decoder (a52dec)
AMR/EVRC reframer (rfamr)
OGG demultiplexer (oggdmx)
Vorbis decoder (vorbisdec)
Theora decoder (theoradec)
MPEG-2 TS demultiplexer (m2tsdmx)
UDP/TCP input (sockin)
DVB for Linux (dvbin)
OpenSVC decoder (osvcdec)
VideoToolBox decoder (vtbdec)
MediaCodec decoder (mcdec)
MPEG-4 LASeR decoder (lsrdec)
SAF demultiplexer (safdmx)
MPEG-DASH and HLS client (dashin)
CENC decryptor (cdcrypt)
CENC encryptor (cecrypt)
ISOBMFF/QT multiplexer (mp4mx)
QCP reframer (rfqcp)
H263 reframer (rfh263)
M1V/M2V/M4V reframer (rfmpgvid)
NHNT reader (nhntr)
NHML reader (nhmlr)
AVC/HEVC reframer (rfnalu)
MPEG PS demultiplexer (m2psdmx)
AVI demultiplexer (avidmx)
Subtitle loader (txtin)
TTXT/TX3G decoder (ttxtdec)
WebVTT decoder (vttdec)
TTML decoder (ttmldec)
RTP/RTSP/SDP input (rtpin)
File output (fout)
Raw AAC to LATM writer (uflatm)
ADTS writer (ufadts)
MHAS writer (ufmhas)
Media Reframer (reframer)
Stream to file (writegen)
AVC/HEVC to AnnexB writer (ufnalu)
QCP writer (writeqcp)
WebVTT unframer (ufvtt)
NHNT writer (nhntw)
NHML writer (nhmlw)
VobSub parser (vobsubdmx)
AVI multiplexer (avimx)
Audio output (aout)
M4V writer (ufm4v)
VC1 writer (ufvc1)
Audio resampler (resample)
Video output (vout)
Video crop (vcrop)
Video flip (vflip)
RAW video reframer (rfrawvid)
PCM reframer (rfpcm)
JPG encoder (jpgenc)
PNG encoder (pngenc)
Audio/Video rewinder (rewind)
Sources concatenator (flist)
MPEG-2 TS multiplexer (m2tsmx)
DASH and HLS segmenter (dasher)
HEVC tile aggregator (tileagg)
HEVC tile bitstream splitter (tilesplit)
pipe input (pin)
pipe output (pout)
GSF Multiplexer (gsfmx)
GSF demultiplexer (gsfdmx)
UDP/TCP output (sockout)
AV1/IVF/VP9 reframer (rfav1)
IVF/OBU/annexB writer (ufobu)
NVidia decoder (nvdec)
ROUTE input (routein)
RTP Streamer (rtpout)
RTSP Server (rtspout)
HTTP Server (httpout)
HEVC tile splitter (hevcsplit)
HEVC Tile merger (hevcmerge)
FLAC reframer (rfflac)
MPEH-H Audio Stream reframer (rfmhas)
ProRes reframer (rfprores)
MPEG Transport Stream splitter (tssplit)
Compressed bitstream rewriter (bsrw)
Compressed layered bitstream splitter (bssplit)
Compressed layered bitstream aggregator (bsagg)
TX3G unframer (ufttxt)
TX3G to SRT (tx3g2srt)
TX3G to WebVTT (tx3g2vtt)
TX3G to TTML (tx3g2ttml)
WebVTT to TX3G (vtt2tx3g)
SRT reframer (rfsrt)
TTML to WebVTT (ttml2vtt)
TTML to SRT (ttml2srt)
MPEG-H Audio decoder (mpeghdec)
FFMPEG demultiplexer (ffdmx)
FFMPEG decoder (ffdec)
FFMPEG AV Capture (ffavin)
FFMPEG video rescaler (ffsws)
FFMPEG encoder (ffenc)
FFMPEG multiplexer (ffmx)
FFMPEG AVFilter (ffavf)
FFMPEG BitStream filter (ffbsf)
JavaScript filter (jsf)
ROUTE output (routeout)
TrueHD reframer (rftruehd)
CryptFile input (cryptin)
CryptFile output (cryptout)
Packet timestamp rewriter (restamp)
OGG multiplexer (oggmx)
Stream unframer (unframer)
Stream to unframed format (writeuf)
UNCV decoder (uncvdec)
GHI demultiplexer (ghidmx)
EVG video rescaler (evgs)
Closed-Caption decoder (ccdec)
DekTec SDIOut (dtout)
OpenHEVC decoder (ohevcdec)
Uncompressed Video File Format Generator Utility (uncvg)
GPU texture uploader (glpush)
Thumbnail collection generator (thumbs)
Audio Video Mixer (avmix)
AV Counter Generator (avgen)

Clone this wiki locally