You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

893 lines
26KB

  1. \input texinfo @c -*- texinfo -*-
  2. @settitle ffserver Documentation
  3. @titlepage
  4. @center @titlefont{ffserver Documentation}
  5. @end titlepage
  6. @top
  7. @contents
  8. @chapter Synopsis
  9. ffserver [@var{options}]
  10. @chapter Description
  11. @c man begin DESCRIPTION
  12. @command{ffserver} is a streaming server for both audio and video.
  13. It supports several live feeds, streaming from files and time shifting
  14. on live feeds. You can seek to positions in the past on each live
  15. feed, provided you specify a big enough feed storage.
  16. @command{ffserver} is configured through a configuration file, which
  17. is read at startup. If not explicitly specified, it will read from
  18. @file{/etc/ffserver.conf}.
  19. @command{ffserver} receives prerecorded files or FFM streams from some
  20. @command{ffmpeg} instance as input, then streams them over
  21. RTP/RTSP/HTTP.
  22. An @command{ffserver} instance will listen on some port as specified
  23. in the configuration file. You can launch one or more instances of
  24. @command{ffmpeg} and send one or more FFM streams to the port where
  25. ffserver is expecting to receive them. Alternately, you can make
  26. @command{ffserver} launch such @command{ffmpeg} instances at startup.
  27. Input streams are called feeds, and each one is specified by a
  28. @code{<Feed>} section in the configuration file.
  29. For each feed you can have different output streams in various
  30. formats, each one specified by a @code{<Stream>} section in the
  31. configuration file.
  32. @chapter Detailed description
  33. @command{ffserver} works by forwarding streams encoded by
  34. @command{ffmpeg}, or pre-recorded streams which are read from disk.
  35. Precisely, @command{ffserver} acts as an HTTP server, accepting POST
  36. requests from @command{ffmpeg} to acquire the stream to publish, and
  37. serving HTTP clients GET requests with the stream media content.
  38. A feed is an @ref{FFM} stream created by @command{ffmpeg}, and sent to
  39. a port where @command{ffserver} is listening.
  40. Each feed is identified by a unique name, corresponding to the name
  41. of the resource published on @command{ffserver}, and is configured by
  42. a dedicated @code{Feed} section in the configuration file.
  43. The feed publish URL is given by:
  44. @example
  45. http://@var{ffserver_ip_address}:@var{http_port}/@var{feed_name}
  46. @end example
  47. where @var{ffserver_ip_address} is the IP address of the machine where
  48. @command{ffserver} is installed, @var{http_port} is the port number of
  49. the HTTP server (configured through the @option{Port} option), and
  50. @var{feed_name} is the name of the corresponding feed defined in the
  51. configuration file.
  52. Each feed is associated to a file which is stored on disk. This stored
  53. file is used to allow to send pre-recorded data to a player as fast as
  54. possible when new content is added in real-time to the stream.
  55. A "live-stream" or "stream" is a resource published by
  56. @command{ffserver}, and made accessible through the HTTP protocol to
  57. clients.
  58. A stream can be connected to a feed, or to a file. In the first case,
  59. the published stream is forwarded from the corresponding feed
  60. generated by a running instance of @command{ffmpeg}, in the second
  61. case the stream is read from a pre-recorded file.
  62. Each stream is identified by a unique name, corresponding to the name
  63. of the resource served by @command{ffserver}, and is configured by
  64. a dedicated @code{Stream} section in the configuration file.
  65. The stream access URL is given by:
  66. @example
  67. http://@var{ffserver_ip_address}:@var{http_port}/@var{stream_name}[@var{options}]
  68. @end example
  69. @var{stream_name} is the name of the corresponding stream defined in
  70. the configuration file. @var{options} is a list of options specified
  71. after the URL which affects how the stream is served by
  72. @command{ffserver}.
  73. In case the stream is associated to a feed, the encoding parameters
  74. must be configured in the stream configuration. They are sent to
  75. @command{ffmpeg} when setting up the encoding. This allows
  76. @command{ffserver} to define the encoding parameters used by
  77. the @command{ffmpeg} encoders.
  78. The @command{ffmpeg} @option{override_ffserver} commandline option
  79. allows to override the encoding parameters set by the server.
  80. Multiple streams can be connected to the same feed.
  81. For example, you can have a situation described by the following
  82. graph:
  83. @example
  84. _________ __________
  85. | | | |
  86. ffmpeg 1 -----| feed 1 |-----| stream 1 |
  87. \ |_________|\ |__________|
  88. \ \
  89. \ \ __________
  90. \ \ | |
  91. \ \| stream 2 |
  92. \ |__________|
  93. \
  94. \ _________ __________
  95. \ | | | |
  96. \| feed 2 |-----| stream 3 |
  97. |_________| |__________|
  98. _________ __________
  99. | | | |
  100. ffmpeg 2 -----| feed 3 |-----| stream 4 |
  101. |_________| |__________|
  102. _________ __________
  103. | | | |
  104. | file 1 |-----| stream 5 |
  105. |_________| |__________|
  106. @end example
  107. @anchor{FFM}
  108. @section FFM, FFM2 formats
  109. FFM and FFM2 are formats used by ffserver. They allow storing a wide variety of
  110. video and audio streams and encoding options, and can store a moving time segment
  111. of an infinite movie or a whole movie.
  112. FFM is version specific, and there is limited compatibility of FFM files
  113. generated by one version of ffmpeg/ffserver and another version of
  114. ffmpeg/ffserver. It may work but it is not guaranteed to work.
  115. FFM2 is extensible while maintaining compatibility and should work between
  116. differing versions of tools. FFM2 is the default.
  117. @section Status stream
  118. @command{ffserver} supports an HTTP interface which exposes the
  119. current status of the server.
  120. Simply point your browser to the address of the special status stream
  121. specified in the configuration file.
  122. For example if you have:
  123. @example
  124. <Stream status.html>
  125. Format status
  126. # Only allow local people to get the status
  127. ACL allow localhost
  128. ACL allow 192.168.0.0 192.168.255.255
  129. </Stream>
  130. @end example
  131. then the server will post a page with the status information when
  132. the special stream @file{status.html} is requested.
  133. @section How do I make it work?
  134. As a simple test, just run the following two command lines where INPUTFILE
  135. is some file which you can decode with ffmpeg:
  136. @example
  137. ffserver -f doc/ffserver.conf &
  138. ffmpeg -i INPUTFILE http://localhost:8090/feed1.ffm
  139. @end example
  140. At this point you should be able to go to your Windows machine and fire up
  141. Windows Media Player (WMP). Go to Open URL and enter
  142. @example
  143. http://<linuxbox>:8090/test.asf
  144. @end example
  145. You should (after a short delay) see video and hear audio.
  146. WARNING: trying to stream test1.mpg doesn't work with WMP as it tries to
  147. transfer the entire file before starting to play.
  148. The same is true of AVI files.
  149. @section What happens next?
  150. You should edit the ffserver.conf file to suit your needs (in terms of
  151. frame rates etc). Then install ffserver and ffmpeg, write a script to start
  152. them up, and off you go.
  153. @section What else can it do?
  154. You can replay video from .ffm files that was recorded earlier.
  155. However, there are a number of caveats, including the fact that the
  156. ffserver parameters must match the original parameters used to record the
  157. file. If they do not, then ffserver deletes the file before recording into it.
  158. (Now that I write this, it seems broken).
  159. You can fiddle with many of the codec choices and encoding parameters, and
  160. there are a bunch more parameters that you cannot control. Post a message
  161. to the mailing list if there are some 'must have' parameters. Look in
  162. ffserver.conf for a list of the currently available controls.
  163. It will automatically generate the ASX or RAM files that are often used
  164. in browsers. These files are actually redirections to the underlying ASF
  165. or RM file. The reason for this is that the browser often fetches the
  166. entire file before starting up the external viewer. The redirection files
  167. are very small and can be transferred quickly. [The stream itself is
  168. often 'infinite' and thus the browser tries to download it and never
  169. finishes.]
  170. @section Tips
  171. * When you connect to a live stream, most players (WMP, RA, etc) want to
  172. buffer a certain number of seconds of material so that they can display the
  173. signal continuously. However, ffserver (by default) starts sending data
  174. in realtime. This means that there is a pause of a few seconds while the
  175. buffering is being done by the player. The good news is that this can be
  176. cured by adding a '?buffer=5' to the end of the URL. This means that the
  177. stream should start 5 seconds in the past -- and so the first 5 seconds
  178. of the stream are sent as fast as the network will allow. It will then
  179. slow down to real time. This noticeably improves the startup experience.
  180. You can also add a 'Preroll 15' statement into the ffserver.conf that will
  181. add the 15 second prebuffering on all requests that do not otherwise
  182. specify a time. In addition, ffserver will skip frames until a key_frame
  183. is found. This further reduces the startup delay by not transferring data
  184. that will be discarded.
  185. @section Why does the ?buffer / Preroll stop working after a time?
  186. It turns out that (on my machine at least) the number of frames successfully
  187. grabbed is marginally less than the number that ought to be grabbed. This
  188. means that the timestamp in the encoded data stream gets behind realtime.
  189. This means that if you say 'Preroll 10', then when the stream gets 10
  190. or more seconds behind, there is no Preroll left.
  191. Fixing this requires a change in the internals of how timestamps are
  192. handled.
  193. @section Does the @code{?date=} stuff work.
  194. Yes (subject to the limitation outlined above). Also note that whenever you
  195. start ffserver, it deletes the ffm file (if any parameters have changed),
  196. thus wiping out what you had recorded before.
  197. The format of the @code{?date=xxxxxx} is fairly flexible. You should use one
  198. of the following formats (the 'T' is literal):
  199. @example
  200. * YYYY-MM-DDTHH:MM:SS (localtime)
  201. * YYYY-MM-DDTHH:MM:SSZ (UTC)
  202. @end example
  203. You can omit the YYYY-MM-DD, and then it refers to the current day. However
  204. note that @samp{?date=16:00:00} refers to 16:00 on the current day -- this
  205. may be in the future and so is unlikely to be useful.
  206. You use this by adding the ?date= to the end of the URL for the stream.
  207. For example: @samp{http://localhost:8080/test.asf?date=2002-07-26T23:05:00}.
  208. @c man end
  209. @chapter Options
  210. @c man begin OPTIONS
  211. @include fftools-common-opts.texi
  212. @section Main options
  213. @table @option
  214. @item -f @var{configfile}
  215. Read configuration file @file{configfile}. If not specified it will
  216. read by default from @file{/etc/ffserver.conf}.
  217. @item -n
  218. Enable no-launch mode. This option disables all the @code{Launch}
  219. directives within the various @code{<Feed>} sections. Since
  220. @command{ffserver} will not launch any @command{ffmpeg} instances, you
  221. will have to launch them manually.
  222. @item -d
  223. Enable debug mode. This option increases log verbosity, and directs
  224. log messages to stdout. When specified, the @option{CustomLog} option
  225. is ignored.
  226. @end table
  227. @chapter Configuration file syntax
  228. @command{ffserver} reads a configuration file containing global
  229. options and settings for each stream and feed.
  230. The configuration file consists of global options and dedicated
  231. sections, which must be introduced by "<@var{SECTION_NAME}
  232. @var{ARGS}>" on a separate line and must be terminated by a line in
  233. the form "</@var{SECTION_NAME}>". @var{ARGS} is optional.
  234. Currently the following sections are recognized: @samp{Feed},
  235. @samp{Stream}, @samp{Redirect}.
  236. A line starting with @code{#} is ignored and treated as a comment.
  237. Name of options and sections are case-insensitive.
  238. @section ACL syntax
  239. An ACL (Access Control List) specifies the address which are allowed
  240. to access a given stream, or to write a given feed.
  241. It accepts the folling forms
  242. @itemize
  243. @item
  244. Allow/deny access to @var{address}.
  245. @example
  246. ACL ALLOW <address>
  247. ACL DENY <address>
  248. @end example
  249. @item
  250. Allow/deny access to ranges of addresses from @var{first_address} to
  251. @var{last_address}.
  252. @example
  253. ACL ALLOW <first_address> <last_address>
  254. ACL DENY <first_address> <last_address>
  255. @end example
  256. @end itemize
  257. You can repeat the ACL allow/deny as often as you like. It is on a per
  258. stream basis. The first match defines the action. If there are no matches,
  259. then the default is the inverse of the last ACL statement.
  260. Thus 'ACL allow localhost' only allows access from localhost.
  261. 'ACL deny 1.0.0.0 1.255.255.255' would deny the whole of network 1 and
  262. allow everybody else.
  263. @section Global options
  264. @table @option
  265. @item Port @var{port_number}
  266. @item RTSPPort @var{port_number}
  267. Set TCP port number on which the HTTP/RTSP server is listening. You
  268. must select a different port from your standard HTTP web server if it
  269. is running on the same computer.
  270. If not specified, no corresponding server will be created.
  271. @item BindAddress @var{ip_address}
  272. @item RTSPBindAddress @var{ip_address}
  273. Set address on which the HTTP/RTSP server is bound. Only useful if you
  274. have several network interfaces.
  275. @item MaxHTTPConnections @var{n}
  276. Set number of simultaneous HTTP connections that can be handled. It
  277. has to be defined @emph{before} the @option{MaxClients} parameter,
  278. since it defines the @option{MaxClients} maximum limit.
  279. Default value is 2000.
  280. @item MaxClients @var{n}
  281. Set number of simultaneous requests that can be handled. Since
  282. @command{ffserver} is very fast, it is more likely that you will want
  283. to leave this high and use @option{MaxBandwidth}.
  284. Default value is 5.
  285. @item MaxBandwidth @var{kbps}
  286. Set the maximum amount of kbit/sec that you are prepared to consume
  287. when streaming to clients.
  288. Default value is 1000.
  289. @item CustomLog @var{filename}
  290. Set access log file (uses standard Apache log file format). '-' is the
  291. standard output.
  292. If not specified @command{ffserver} will produce no log.
  293. In case the commandline option @option{-d} is specified this option is
  294. ignored, and the log is written to standard output.
  295. @item NoDaemon
  296. Set no-daemon mode. This option is currently ignored since now
  297. @command{ffserver} will always work in no-daemon mode, and is
  298. deprecated.
  299. @end table
  300. @section Feed section
  301. A Feed section defines a feed provided to @command{ffserver}.
  302. Each live feed contains one video and/or audio sequence coming from an
  303. @command{ffmpeg} encoder or another @command{ffserver}. This sequence
  304. may be encoded simultaneously with several codecs at several
  305. resolutions.
  306. A feed instance specification is introduced by a line in the form:
  307. @example
  308. <Feed FEED_FILENAME>
  309. @end example
  310. where @var{FEED_FILENAME} specifies the unique name of the FFM stream.
  311. The following options are recognized within a Feed section.
  312. @table @option
  313. @item File @var{filename}
  314. @item ReadOnlyFile @var{filename}
  315. Set the path where the feed file is stored on disk.
  316. If not specified, the @file{/tmp/FEED.ffm} is assumed, where
  317. @var{FEED} is the feed name.
  318. If @option{ReadOnlyFile} is used the file is marked as read-only and
  319. it will not be deleted or updated.
  320. @item Truncate
  321. Truncate the feed file, rather than appending to it. By default
  322. @command{ffserver} will append data to the file, until the maximum
  323. file size value is reached (see @option{FileMaxSize} option).
  324. @item FileMaxSize @var{size}
  325. Set maximum size of the feed file in bytes. 0 means unlimited. The
  326. postfixes @code{K} (2^10), @code{M} (2^20), and @code{G} (2^30) are
  327. recognized.
  328. Default value is 5M.
  329. @item Launch @var{args}
  330. Launch an @command{ffmpeg} command when creating @command{ffserver}.
  331. @var{args} must be a sequence of arguments to be provided to an
  332. @command{ffmpeg} instance. The first provided argument is ignored, and
  333. it is replaced by a path with the same dirname of the @command{ffserver}
  334. instance, followed by the remaining argument and terminated with a
  335. path corresponding to the feed.
  336. When the launched process exits, @command{ffserver} will launch
  337. another program instance.
  338. In case you need a more complex @command{ffmpeg} configuration,
  339. e.g. if you need to generate multiple FFM feeds with a single
  340. @command{ffmpeg} instance, you should launch @command{ffmpeg} by hand.
  341. This option is ignored in case the commandline option @option{-n} is
  342. specified.
  343. @item ACL @var{spec}
  344. Specify the list of IP address which are allowed or denied to write
  345. the feed. Multiple ACL options can be specified.
  346. @end table
  347. @section Stream section
  348. A Stream section defines a stream provided by @command{ffserver}, and
  349. identified by a single name.
  350. The stream is sent when answering a request containing the stream
  351. name.
  352. A stream section must be introduced by the line:
  353. @example
  354. <Stream STREAM_NAME>
  355. @end example
  356. where @var{STREAM_NAME} specifies the unique name of the stream.
  357. The following options are recognized within a Stream section.
  358. Encoding options are marked with the @emph{encoding} tag, and they are
  359. used to set the encoding parameters, and are mapped to libavcodec
  360. encoding options. Not all encoding options are supported, in
  361. particular it is not possible to set encoder private options. In order
  362. to override the encoding options specified by @command{ffserver}, you
  363. can use the @command{ffmpeg} @option{override_ffserver} commandline
  364. option.
  365. Only one of the @option{Feed} and @option{File} options should be set.
  366. @table @option
  367. @item Feed @var{feed_name}
  368. Set the input feed. @var{feed_name} must correspond to an existing
  369. feed defined in a @code{Feed} section.
  370. When this option is set, encoding options are used to setup the
  371. encoding operated by the remote @command{ffmpeg} process.
  372. @item File @var{filename}
  373. Set the filename of the pre-recorded input file to stream.
  374. When this option is set, encoding options are ignored and the input
  375. file content is re-streamed as is.
  376. @item Format @var{format_name}
  377. Set the format of the output stream.
  378. Must be the name of a format recognized by FFmpeg. If set to
  379. @samp{status}, it is treated as a status stream.
  380. @item InputFormat @var{format_name}
  381. Set input format. If not specified, it is automatically guessed.
  382. @item Preroll @var{n}
  383. Set this to the number of seconds backwards in time to start. Note that
  384. most players will buffer 5-10 seconds of video, and also you need to allow
  385. for a keyframe to appear in the data stream.
  386. Default value is 0.
  387. @item StartSendOnKey
  388. Do not send stream until it gets the first key frame. By default
  389. @command{ffserver} will send data immediately.
  390. @item MaxTime @var{n}
  391. Set the number of seconds to run. This value set the maximum duration
  392. of the stream a client will be able to receive.
  393. A value of 0 means that no limit is set on the stream duration.
  394. @item ACL @var{spec}
  395. Set ACL for the stream.
  396. @item DynamicACL @var{spec}
  397. @item RTSPOption @var{option}
  398. @item MulticastAddress @var{address}
  399. @item MulticastPort @var{port}
  400. @item MulticastTTL @var{integer}
  401. @item NoLoop
  402. @item FaviconURL @var{url}
  403. Set favicon (favourite icon) for the server status page. It is ignored
  404. for regular streams.
  405. @item Author @var{value}
  406. @item Comment @var{value}
  407. @item Copyright @var{value}
  408. @item Title @var{value}
  409. Set metadata corresponding to the option. All these options are
  410. deprecated in favor of @option{Metadata}.
  411. @item Metadata @var{key} @var{value}
  412. Set metadata value on the output stream.
  413. @item NoAudio
  414. @item NoVideo
  415. Suppress audio/video.
  416. @item AudioCodec @var{codec_name} (@emph{encoding,audio})
  417. Set audio codec.
  418. @item AudioBitRate @var{rate} (@emph{encoding,audio})
  419. Set bitrate for the audio stream in kbits per second.
  420. @item AudioChannels @var{n} (@emph{encoding,audio})
  421. Set number of audio channels.
  422. @item AudioSampleRate @var{n} (@emph{encoding,audio})
  423. Set sampling frequency for audio. When using low bitrates, you should
  424. lower this frequency to 22050 or 11025. The supported frequencies
  425. depend on the selected audio codec.
  426. @item AVOptionAudio @var{option} @var{value} (@emph{encoding,audio})
  427. Set generic option for audio stream.
  428. @item AVPresetAudio @var{preset} (@emph{encoding,audio})
  429. Set preset for audio stream.
  430. @item VideoCodec @var{codec_name} (@emph{encoding,video})
  431. Set video codec.
  432. @item VideoBitRate @var{n} (@emph{encoding,video})
  433. Set bitrate for the video stream in kbits per second.
  434. @item VideoBitRateRange @var{range} (@emph{encoding,video})
  435. Set video bitrate range.
  436. A range must be specified in the form @var{minrate}-@var{maxrate}, and
  437. specifies the @option{minrate} and @option{maxrate} encoding options
  438. expressed in kbits per second.
  439. @item VideoBitRateRangeTolerance @var{n} (@emph{encoding,video})
  440. Set video bitrate tolerance in kbits per second.
  441. @item PixelFormat @var{pixel_format} (@emph{encoding,video})
  442. Set video pixel format.
  443. @item Debug @var{integer} (@emph{encoding,video})
  444. Set video @option{debug} encoding option.
  445. @item Strict @var{integer} (@emph{encoding,video})
  446. Set video @option{strict} encoding option.
  447. @item VideoBufferSize @var{n} (@emph{encoding,video})
  448. Set ratecontrol buffer size, expressed in KB.
  449. @item VideoFrameRate @var{n} (@emph{encoding,video})
  450. Set number of video frames per second.
  451. @item VideoSize (@emph{encoding,video})
  452. Set size of the video frame, must be an abbreviation or in the form
  453. @var{W}x@var{H}. See @ref{video size syntax,,the Video size section
  454. in the ffmpeg-utils(1) manual,ffmpeg-utils}.
  455. Default value is @code{160x128}.
  456. @item VideoIntraOnly (@emph{encoding,video})
  457. Transmit only intra frames (useful for low bitrates, but kills frame rate).
  458. @item VideoGopSize @var{n} (@emph{encoding,video})
  459. If non-intra only, an intra frame is transmitted every VideoGopSize
  460. frames. Video synchronization can only begin at an intra frame.
  461. @item VideoTag @var{tag} (@emph{encoding,video})
  462. Set video tag.
  463. @item VideoHighQuality (@emph{encoding,video})
  464. @item Video4MotionVector (@emph{encoding,video})
  465. @item BitExact (@emph{encoding,video})
  466. Set bitexact encoding flag.
  467. @item IdctSimple (@emph{encoding,video})
  468. Set simple IDCT algorithm.
  469. @item Qscale @var{n} (@emph{encoding,video})
  470. Enable constant quality encoding, and set video qscale (quantization
  471. scale) value, expressed in @var{n} QP units.
  472. @item VideoQMin @var{n} (@emph{encoding,video})
  473. @item VideoQMax @var{n} (@emph{encoding,video})
  474. Set video qmin/qmax.
  475. @item VideoQDiff @var{integer} (@emph{encoding,video})
  476. Set video @option{qdiff} encoding option.
  477. @item LumiMask @var{float} (@emph{encoding,video})
  478. @item DarkMask @var{float} (@emph{encoding,video})
  479. Set @option{lumi_mask}/@option{dark_mask} encoding options.
  480. @item AVOptionVideo @var{option} @var{value} (@emph{encoding,video})
  481. Set generic option for video stream.
  482. @item AVPresetVideo @var{preset} (@emph{encoding,video})
  483. Set preset for video stream.
  484. @var{preset} must be the path of a preset file.
  485. @end table
  486. @subsection Server status stream
  487. A server status stream is a special stream which is used to show
  488. statistics about the @command{ffserver} operations.
  489. It must be specified setting the option @option{Format} to
  490. @samp{status}.
  491. @section Redirect section
  492. A redirect section specifies where to redirect the requested URL to
  493. another page.
  494. A redirect section must be introduced by the line:
  495. @example
  496. <Redirect NAME>
  497. @end example
  498. where @var{NAME} is the name of the page which should be redirected.
  499. It only accepts the option @option{URL}, which specify the redirection
  500. URL.
  501. @chapter Stream examples
  502. @itemize
  503. @item
  504. Multipart JPEG
  505. @example
  506. <Stream test.mjpg>
  507. Feed feed1.ffm
  508. Format mpjpeg
  509. VideoFrameRate 2
  510. VideoIntraOnly
  511. NoAudio
  512. Strict -1
  513. </Stream>
  514. @end example
  515. @item
  516. Single JPEG
  517. @example
  518. <Stream test.jpg>
  519. Feed feed1.ffm
  520. Format jpeg
  521. VideoFrameRate 2
  522. VideoIntraOnly
  523. VideoSize 352x240
  524. NoAudio
  525. Strict -1
  526. </Stream>
  527. @end example
  528. @item
  529. Flash
  530. @example
  531. <Stream test.swf>
  532. Feed feed1.ffm
  533. Format swf
  534. VideoFrameRate 2
  535. VideoIntraOnly
  536. NoAudio
  537. </Stream>
  538. @end example
  539. @item
  540. ASF compatible
  541. @example
  542. <Stream test.asf>
  543. Feed feed1.ffm
  544. Format asf
  545. VideoFrameRate 15
  546. VideoSize 352x240
  547. VideoBitRate 256
  548. VideoBufferSize 40
  549. VideoGopSize 30
  550. AudioBitRate 64
  551. StartSendOnKey
  552. </Stream>
  553. @end example
  554. @item
  555. MP3 audio
  556. @example
  557. <Stream test.mp3>
  558. Feed feed1.ffm
  559. Format mp2
  560. AudioCodec mp3
  561. AudioBitRate 64
  562. AudioChannels 1
  563. AudioSampleRate 44100
  564. NoVideo
  565. </Stream>
  566. @end example
  567. @item
  568. Ogg Vorbis audio
  569. @example
  570. <Stream test.ogg>
  571. Feed feed1.ffm
  572. Metadata title "Stream title"
  573. AudioBitRate 64
  574. AudioChannels 2
  575. AudioSampleRate 44100
  576. NoVideo
  577. </Stream>
  578. @end example
  579. @item
  580. Real with audio only at 32 kbits
  581. @example
  582. <Stream test.ra>
  583. Feed feed1.ffm
  584. Format rm
  585. AudioBitRate 32
  586. NoVideo
  587. </Stream>
  588. @end example
  589. @item
  590. Real with audio and video at 64 kbits
  591. @example
  592. <Stream test.rm>
  593. Feed feed1.ffm
  594. Format rm
  595. AudioBitRate 32
  596. VideoBitRate 128
  597. VideoFrameRate 25
  598. VideoGopSize 25
  599. </Stream>
  600. @end example
  601. @item
  602. For stream coming from a file: you only need to set the input filename
  603. and optionally a new format.
  604. @example
  605. <Stream file.rm>
  606. File "/usr/local/httpd/htdocs/tlive.rm"
  607. NoAudio
  608. </Stream>
  609. @end example
  610. @example
  611. <Stream file.asf>
  612. File "/usr/local/httpd/htdocs/test.asf"
  613. NoAudio
  614. Metadata author "Me"
  615. Metadata copyright "Super MegaCorp"
  616. Metadata title "Test stream from disk"
  617. Metadata comment "Test comment"
  618. </Stream>
  619. @end example
  620. @end itemize
  621. @c man end
  622. @include config.texi
  623. @ifset config-all
  624. @ifset config-avutil
  625. @include utils.texi
  626. @end ifset
  627. @ifset config-avcodec
  628. @include codecs.texi
  629. @include bitstream_filters.texi
  630. @end ifset
  631. @ifset config-avformat
  632. @include formats.texi
  633. @include protocols.texi
  634. @end ifset
  635. @ifset config-avdevice
  636. @include devices.texi
  637. @end ifset
  638. @ifset config-swresample
  639. @include resampler.texi
  640. @end ifset
  641. @ifset config-swscale
  642. @include scaler.texi
  643. @end ifset
  644. @ifset config-avfilter
  645. @include filters.texi
  646. @end ifset
  647. @end ifset
  648. @chapter See Also
  649. @ifhtml
  650. @ifset config-all
  651. @url{ffserver.html,ffserver},
  652. @end ifset
  653. @ifset config-not-all
  654. @url{ffserver-all.html,ffserver-all},
  655. @end ifset
  656. the @file{doc/ffserver.conf} example,
  657. @url{ffmpeg.html,ffmpeg}, @url{ffplay.html,ffplay}, @url{ffprobe.html,ffprobe},
  658. @url{ffmpeg-utils.html,ffmpeg-utils},
  659. @url{ffmpeg-scaler.html,ffmpeg-scaler},
  660. @url{ffmpeg-resampler.html,ffmpeg-resampler},
  661. @url{ffmpeg-codecs.html,ffmpeg-codecs},
  662. @url{ffmpeg-bitstream-filters.html,ffmpeg-bitstream-filters},
  663. @url{ffmpeg-formats.html,ffmpeg-formats},
  664. @url{ffmpeg-devices.html,ffmpeg-devices},
  665. @url{ffmpeg-protocols.html,ffmpeg-protocols},
  666. @url{ffmpeg-filters.html,ffmpeg-filters}
  667. @end ifhtml
  668. @ifnothtml
  669. @ifset config-all
  670. ffserver(1),
  671. @end ifset
  672. @ifset config-not-all
  673. ffserver-all(1),
  674. @end ifset
  675. the @file{doc/ffserver.conf} example, ffmpeg(1), ffplay(1), ffprobe(1),
  676. ffmpeg-utils(1), ffmpeg-scaler(1), ffmpeg-resampler(1),
  677. ffmpeg-codecs(1), ffmpeg-bitstream-filters(1), ffmpeg-formats(1),
  678. ffmpeg-devices(1), ffmpeg-protocols(1), ffmpeg-filters(1)
  679. @end ifnothtml
  680. @include authors.texi
  681. @ignore
  682. @setfilename ffserver
  683. @settitle ffserver video server
  684. @end ignore
  685. @bye