Browse code

Document udp protocol.

Based on a patch by Aviad Rozenhek aviadr1 @ reverse(moc.liamg).

Originally committed as revision 25192 to svn://svn.ffmpeg.org/ffmpeg/trunk

Stefano Sabatini authored on 2010/09/25 19:16:15
Showing 1 changed files
... ...
@@ -225,4 +225,47 @@ Trasmission Control Protocol.
225 225
 
226 226
 User Datagram Protocol.
227 227
 
228
+The required syntax for a UDP url is:
229
+@example
230
+udp://@var{hostname}:@var{port}[?@var{options}]
231
+@end example
232
+
233
+@var{options} contains a list of &-seperated options of the form @var{key}=@var{val}.
234
+Follow the list of supported options.
235
+
236
+@table @option
237
+
238
+@item buffer_size=@var{size}
239
+set the UDP buffer size in bytes
240
+
241
+@item localport=@var{port}
242
+override the local UDP port to bind with
243
+
244
+@item pkt_size=@var{size}
245
+set the size in bytes of UDP packets
246
+
247
+@item reuse=@var{1|0}
248
+explicitly allow or disallow reusing UDP sockets
249
+
250
+@item ttl=@var{ttl}
251
+set the time to live value (for multicast only)
252
+@end table
253
+
254
+Some usage examples of the udp protocol with @file{ffmpeg} follow.
255
+
256
+To stream over UDP to a remote endpoint:
257
+@example
258
+ffmpeg -i @var{input} -f @var{format} udp://@var{hostname}:@var{port}
259
+@end example
260
+
261
+To stream in mpegts format over UDP using 188 sized UDP packets, using a large input buffer:
262
+@example
263
+ffmpeg -i @var{input} -f mpegts udp://@var{hostname}:@var{port}?pkt_size=188&buffer_size=65535
264
+@end example
265
+
266
+To receive over UDP from a remote endpoint:
267
+@example
268
+ffmpeg -i udp://[@var{multicast-address}]:@var{port}
269
+@end example
270
+
228 271
 @c man end PROTOCOLS