-
Notifications
You must be signed in to change notification settings - Fork 526
sockout
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.
Register name used to load filter: sockout
This filter may be automatically loaded during graph resolution.
This filter handles generic output sockets (mono-directional) in blocking mode only.
The filter can work in server mode, waiting for source connections, or in client mode, directly connecting to a server.
In server mode, the filter can be instructed to keep running at the end of the stream.
In server mode, the default behavior is to keep input packets when no more clients are connected; this can be adjusted though the kp option, however there is no realtime regulation of how fast packets are dropped.
If your sources are not real time, consider adding a real-time scheduler in the chain (cf reframer filter), or set the send rate option.
- UDP sockets are used for destinations URLs formatted as
udp://NAME
- TCP sockets are used for destinations URLs formatted as
tcp://NAME
- UDP unix domain sockets are used for destinations URLs formatted as
udpu://NAME
- TCP unix domain sockets are used for destinations URLs formatted as
tcpu://NAME
When ports are specified in the URL and the default option separators are used (see gpac -h doc
), the URL must either:
- have a trailing '/', e.g.
udp://localhost:1234/[:opts]
- use
gpac
escape, e.g.udp://localhost:1234[:gpac:opts]
The socket output can be configured to drop or revert packet order for test purposes.
A window size in packets is specified as the drop/revert fraction denominator, and the index of the packet to drop/revert is given as the numerator/
If the numerator is 0, a packet is randomly chosen in that window.
Example
:pckd=4/10
This drops every 4th packet of each 10 packet window.
Example
:pckr=0/100
This reverts the send order of one random packet in each 100 packet window.
dst (cstr): URL of destination
sockbuf (uint, default: 65536): block size used to read file
port (uint, default: 1234): default port if not specified
ifce (cstr): default multicast interface
ext (str): file extension of pipe data
mime (str): mime type of pipe data
listen (bool, default: false): indicate the output socket works in server mode
maxc (uint, default: +I): max number of concurrent connections
ka (bool, default: false): keep socket alive if no more connections
kp (bool, default: true): keep packets in queue if no more clients
start (dbl, default: 0.0): set playback start offset. A negative value means percent of media duration with -1 equal to duration
speed (dbl, default: 1.0): set playback speed. If negative and start is 0, start is set to -1
rate (uint, default: 0): set send rate in bps, disabled by default (as fast as possible)
pckr (frac, default: 0/0): reverse packet every N
pckd (frac, default: 0/0): drop packet every N
ttl (uint, default: 0, minmax: 0-127): multicast TTL
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)