4 Protocols are configured elements in FFmpeg which allow to access
5 resources which require the use of a particular protocol.
7 When you configure your FFmpeg build, all the supported protocols are
8 enabled by default. You can list all available ones using the
9 configure option "--list-protocols".
11 You can disable all the protocols using the configure option
12 "--disable-protocols", and selectively enable a protocol using the
13 option "--enable-protocol=@var{PROTOCOL}", or you can disable a
14 particular protocol using the option
15 "--disable-protocol=@var{PROTOCOL}".
17 The option "-protocols" of the ff* tools will display the list of
20 A description of the currently available protocols follows.
24 Physical concatenation protocol.
26 Allow to read and seek from many resource in sequence as if they were
29 An URL accepted by this protocol has the syntax:
31 concat:@var{URL1}|@var{URL2}|...|@var{URLN}
34 where @var{URL1}, @var{URL2}, ..., @var{URLN} are the urls of the
35 resource to be concatenated, each one possibly specifying a distinct
38 For example to read a sequence of files @file{split1.mpeg},
39 @file{split2.mpeg}, @file{split3.mpeg} with @file{ffplay} use the
42 ffplay concat:split1.mpeg\|split2.mpeg\|split3.mpeg
45 Note that you may need to escape the character "|" which is special for
52 Allow to read from or read to a file.
54 For example to read from a file @file{input.mpeg} with @file{ffmpeg}
57 ffmpeg -i file:input.mpeg output.mpeg
60 The ff* tools default to the file protocol, that is a resource
61 specified with the name "FILE.mpeg" is interpreted as the URL
70 HTTP (Hyper Text Transfer Protocol).
74 MMS (Microsoft Media Server) protocol over TCP.
80 Computes the MD5 hash of the data to be written, and on close writes
81 this to the designated output or stdout if none is specified. It can
82 be used to test muxers without writing an actual file.
86 # Write the MD5 hash of the encoded AVI file in the file output.avi.md5.
87 ffmpeg -i input.flv -f avi -y md5:output.avi.md5
89 # Write the MD5 hash of the encoded AVI file to stdout.
90 ffmpeg -i input.flv -f avi -y md5:
93 Note that some formats (typically MOV) require the output protocol to
94 be seekable, so they will fail with the MD5 output protocol.
98 UNIX pipe access protocol.
100 Allow to read and write from UNIX pipes.
102 The accepted syntax is:
107 @var{number} is the number corresponding to the file descriptor of the
108 pipe (e.g. 0 for stdin, 1 for stdout, 2 for stderr). If @var{number}
109 is not specified, by default the stdout file descriptor will be used
110 for writing, stdin for reading.
112 For example to read from stdin with @file{ffmpeg}:
114 cat test.wav | ffmpeg -i pipe:0
115 # ...this is the same as...
116 cat test.wav | ffmpeg -i pipe:
119 For writing to stdout with @file{ffmpeg}:
121 ffmpeg -i test.wav -f avi pipe:1 | cat > test.avi
122 # ...this is the same as...
123 ffmpeg -i test.wav -f avi pipe: | cat > test.avi
126 Note that some formats (typically MOV), require the output protocol to
127 be seekable, so they will fail with the pipe output protocol.
131 Real-Time Messaging Protocol.
133 The Real-Time Messaging Protocol (RTMP) is used for streaming multimeā
134 dia content across a TCP/IP network.
136 The required syntax is:
138 rtmp://@var{server}[:@var{port}][/@var{app}][/@var{playpath}]
141 The accepted parameters are:
145 The address of the RTMP server.
148 The number of the TCP port to use (by default is 1935).
151 It is the name of the application to access. It usually corresponds to
152 the path where the application is installed on the RTMP server
153 (e.g. @file{/ondemand/}, @file{/flash/live/}, etc.).
156 It is the path or name of the resource to play with reference to the
157 application specified in @var{app}, may be prefixed by "mp4:".
161 For example to read with @file{ffplay} a multimedia resource named
162 "sample" from the application "vod" from an RTMP server "myserver":
164 ffplay rtmp://myserver/vod/sample
167 @section rtmp, rtmpe, rtmps, rtmpt, rtmpte
169 Real-Time Messaging Protocol and its variants supported through
172 Requires the presence of the librtmp headers and library during
173 configuration. You need to explicitely configure the build with
174 "--enable-librtmp". If enabled this will replace the native RTMP
177 This protocol provides most client functions and a few server
178 functions needed to support RTMP, RTMP tunneled in HTTP (RTMPT),
179 encrypted RTMP (RTMPE), RTMP over SSL/TLS (RTMPS) and tunneled
180 variants of these encrypted types (RTMPTE, RTMPTS).
182 The required syntax is:
184 @var{rtmp_proto}://@var{server}[:@var{port}][/@var{app}][/@var{playpath}] @var{options}
187 where @var{rtmp_proto} is one of the strings "rtmp", "rtmpt", "rtmpe",
188 "rtmps", "rtmpte", "rtmpts" corresponding to each RTMP variant, and
189 @var{server}, @var{port}, @var{app} and @var{playpath} have the same
190 meaning as specified for the RTMP native protocol.
191 @var{options} contains a list of space-separated options of the form
194 See the librtmp manual page (man 3 librtmp) for more information.
196 For example, to stream a file in real-time to an RTMP server using
199 ffmpeg -re -i myfile -f flv rtmp://myserver/live/mystream
202 To play the same stream using @file{ffplay}:
204 ffplay "rtmp://myserver/live/mystream live=1"
213 Trasmission Control Protocol.
217 User Datagram Protocol.