Inputs, outputs, and transports
Choose source_type or sink_type for the media plugin, and choose the transport
through its URL. RTMP uses the flv type with an rtmp:// or rtmps:// URL; SRT has its own
srt type; RIST is MPEG-TS, so it uses mpegts with a rist:// URL.
| Type | Input | Output | Transport or purpose | Requirements / example |
|---|---|---|---|---|
flv | Yes | Yes | RTMP/RTMPS, FLV output | Compatible encoded tracks; RTMP proxy. |
srt | Yes | Yes | MPEG-TS over SRT | Caller, listener or rendezvous in URL options. See SRT. |
mpegts | Yes | Yes | MPEG-TS over UDP, RTP, TCP, RIST or SRT | RIST; SRT proxy. |
rtsp | Yes | No | RTSP/RTSPS pull from cameras and servers | See RTSP. |
file | Yes | No | Local media file input | Mount the file; realtime_pacing = true for live-rate playback; quickstart. |
hls | Yes | Yes | Input: HTTP/HTTPS/file playlists. Output: filesystem or S3-compatible storage | Output writes media; it does not create an HTTP playback server. Recording. |
moq | Yes | Yes | WebTransport or WebSocket | Matching endpoint, channel/namespace, transport mode and credentials. See below. |
vindral_ws | Yes | Yes | Vindral media over WebSocket | As a sink, publish to https://lb.cdn.vindral.com/api/edge/publish-url/YOUR_STREAM_KEY. As a source, use the playback URL supplied for your channel. |
decklink_sdk | Yes | Yes | SDI/HDMI, and ST 2110 on DeckLink IP cards, through the Blackmagic DeckLink SDK | Host driver, libDeckLinkAPI.so and devices; DeckLink. |
decklink | Yes | Yes | SDI through FFmpeg | Kept for existing configurations; use decklink_sdk for new ones. |
ndi | Yes | Yes | NDI receive and send | NDI runtime and discovery networking; NDI. |
test-signal | Yes | No | Built-in clock, bars and tone | No requirements; test signal. |
image | Yes | No | Repeated still-image frames | Local image and frame rate; source reference. |
browser | Yes | No | Web-page video and optional audio | CEF-enabled image; browser source. |
A type exists only when its library is present. SRT and RIST depend on the
FFmpeg build in the image (the bundled images include both); NDI and the
DeckLink SDK are loaded from the host at startup. When a library is missing, a task
of that type does not start and retries every reconnect_delay_ms, and the log names the
type (NoTaskInstance("<type>")). Check the image variant against
Validation.
Codec availability depends on the encoder/plugin build and destination. H.264 video with AAC audio is the starting point for the portable examples. A proxy preserves codecs: it cannot make an incompatible input playable by changing the URL or container alone. Additional codecs require compatible ingest, packaging, and playback support across the full path.
SRT
The srt source and sink carry MPEG-TS over SRT. They behave exactly like
mpegts with an srt:// URL, which also remains valid; existing configurations
need no change. Choose the role in the URL or as options:
[[sources]]
id = "contribution"
source_type = "srt"
protocol_options = { url = "srt://0.0.0.0:9000?mode=listener&latency=120000" }
[[sinks]]
id = "to-vindral"
sink_type = "srt"
source_ids = ["encode"]
[sinks.protocol_options]
url = "srt://srt.global.cdn.vindral.com:3333?streamid=#!::r=YOUR_STREAM_KEY,m=publish"
Options can be given in the URL query or as separate keys in protocol_options.
Packager sets none of them itself; the libsrt defaults in the image apply.
| Option | Default | Meaning |
|---|---|---|
mode | caller | caller connects to the peer; listener waits on the given port; rendezvous connects both ways. |
latency | libsrt default (120 ms) | Receiver buffer, in microseconds: 120000 is 120 ms. Set it on both peers. |
streamid | Unset | Identifier sent to the remote server; Vindral ingest uses it for the stream key and mode. |
passphrase | Unset | Encryption passphrase of at least 10 characters. Both peers must use the same one. pbkeylen selects 16, 24 or 32-byte keys. |
pkt_size | 1316 (7 TS packets) | Payload size. |
connect_timeout | 3000 | Caller connection timeout, in milliseconds. |
listen_timeout | Infinite | How long a listener waits for a caller, in microseconds. |
timeout | Packager's rw_timeout (5 s) | Read/write timeout, in microseconds. |
Numeric options in protocol_options use the typed form, for example
latency = { type = "int", value = 200000 }, or go in the URL query. Option names
that the protocol does not know are ignored silently, so check the spelling when a
setting seems to have no effect.
A listener accepts one peer at a time. Expose its port as UDP
(-p 9000:9000/udp). Monitor SRT tasks with the source and sink packet and byte
counters in Monitoring. An SRT stream that
stops delivering data fails its read after 5 seconds, and the task reconnects after
reconnect_delay_ms.
RIST
RIST carries MPEG-TS, so it uses the mpegts source and sink with a rist:// URL.
rist://@0.0.0.0:5000 listens; rist://receiver.example:5000 sends to a peer. It
is available in images whose FFmpeg includes librist, which the bundled images do.
[[sources]]
id = "rist-in"
source_type = "mpegts"
[sources.protocol_options]
url = "rist://@0.0.0.0:5000"
rist_profile = "main"
buffer_size = { type = "int", value = 1000 }
[[sinks]]
id = "rist-out"
sink_type = "mpegts"
source_ids = ["rist-in"]
[sinks.protocol_options]
url = "rist://receiver.example:5002"
rist_profile = "main"
buffer_size = { type = "int", value = 1000 }
| Option | Default | Meaning |
|---|---|---|
rist_profile | main | simple, main or advanced. Must match the peer. |
buffer_size | librist default | Retransmission buffer, in milliseconds (0–30000). |
pkt_size | 1316 | Payload size. |
secret | Unset | Pre-shared encryption secret (main profile). |
encryption | 0 | Key size: 128 or 256. |
fifo_size | librist default | Receive FIFO size, a power of 2. |
overrun_nonfatal | 0 | Input only: keep running when the FIFO overruns instead of failing the read. |
rist:// cannot be used with packager start --source; write a configuration file.
RTSP
The rtsp source pulls a stream from an IP camera or RTSP server. It is input
only; Packager is not an RTSP server. Put credentials in the URL and
percent-encode reserved characters: rtsp://user:pa%[email protected]:554/stream1.
rtsps:// uses TLS.
version = "3"
[api]
bind = "0.0.0.0:4040"
[[sources]]
id = "camera"
source_type = "rtsp"
connect_timeout_ms = 10_000
idle_timeout_ms = 10_000
protocol_options = { url = "rtsp://YOUR_CAMERA:554/stream1" }
demuxer_options = { rtsp_transport = "tcp" }
[[transcoders]]
id = "camera-output"
source_ids = ["camera"]
[[transcoders.tracks]]
id = "video"
type = "video"
passthrough = true
track_selector = { type = "track-kind", kind = "video", is_required = true }
[[transcoders.tracks]]
id = "audio"
type = "audio"
track_selector = { type = "track-kind", kind = "audio", is_required = false }
[[transcoders.tracks.renditions]]
id = "audio-aac"
codec = "aac"
bit_rate = 128_000
[[sinks]]
id = "srt"
sink_type = "srt"
source_ids = ["camera-output"]
protocol_options = { url = "srt://0.0.0.0:3434?mode=listener" }
This passes H.264 or H.265 camera video through and converts the camera's audio (G.711 PCMU/PCMA, AAC or other) to AAC. The audio selector is optional, so a camera without audio also works. For other video codecs, add a video rendition.
Option (demuxer_options) | Packager default | Meaning |
|---|---|---|
rtsp_transport | Unset | tcp pins interleaved TCP; udp needs the negotiated UDP ports open between camera and Packager. |
rtsp_flags | prefer_tcp | Try TCP first, fall back to UDP. |
timeout | 30000000 (30 s) | Socket timeout, in microseconds. 0 disables it. |
The task timeouts (connect_timeout_ms, idle_timeout_ms) are in milliseconds and
apply as well; with the values above, the 10-second task timeout acts before the
30-second socket timeout. For a camera that pauses its stream, raise both. An RTSP
stream does not loop: when it ends, the source reconnects after
reconnect_delay_ms. To try a camera quickly, run
packager start --source 'rtsp://…' --sink '…' (Run without a config file).
For a camera published to Vindral Live, see IP camera to Vindral Live.
MoQ transport selection
Set protocol_options.transport_mode explicitly when using WebSocket:
[[sources]]
id = "moq-input"
source_type = "moq"
[sources.protocol_options]
url = "wss://YOUR_MOQ_HOST/voq/subscribe?id=YOUR_STREAM_KEY"
channel_id = "YOUR_CHANNEL_ID"
transport_mode = "websocket"
The source defaults to webtransport; lookup selects based on the resolved
URL scheme. namespace, when supplied, takes precedence over a namespace
derived from channel_id. Use the endpoint and authentication parameters
provided by your deployment; a WebSocket subscribe URL is not interchangeable
with a publish URL.
Download moq-subscribe.toml for a complete MoQ-to-SRT pipeline. Replace the endpoint and channel values and expose UDP 10000 for the SRT listener. The example passes encoded tracks through; use H.264/AAC media compatible with the MPEG-TS output and receiving player. Connect the SRT receiver after starting Packager.
# Vindral Bridge Packager example
# Subscribe to a MoQ stream and send it on over SRT without transcoding.
version = "3"
[[sources]]
id = "input"
source_type = "moq"
[sources.protocol_options]
url = "wss://YOUR_MOQ_HOST/voq/subscribe?id=YOUR_STREAM_KEY"
channel_id = "YOUR_CHANNEL_ID"
transport_mode = "websocket"
[[sinks]]
id = "srt"
sink_type = "srt"
source_ids = ["input"]
wait_for_all_sources = true
protocol_options = { url = "srt://0.0.0.0:10000?mode=listener&latency=120000" }
HLS ingest
Download hls-input.toml, replace its input playlist URL, and expose UDP 10000 to forward it over SRT. Use an H.264/AAC playlist for this passthrough example and connect the SRT receiver.
# Vindral Bridge Packager example
# Pull an HLS stream and send it on over SRT without transcoding.
version = "3"
[[sources]]
id = "input"
source_type = "hls"
protocol_options = { url = "https://YOUR_HLS_HOST/live/master.m3u8" }
[[sinks]]
id = "srt"
sink_type = "srt"
source_ids = ["input"]
wait_for_all_sources = true
protocol_options = { url = "srt://0.0.0.0:10000?mode=listener&latency=120000" }
Transport options and timeouts
Task timeouts such as connect_timeout_ms are separate from FFmpeg protocol
options such as rw_timeout. Use the option types and units accepted by the
selected transport. SRT listener/caller mode, encryption, and latency options
must also match the peer. Verify available options in the FFmpeg build supplied
with your Packager image rather than copying unrelated protocol settings.