ffserver.conf 8.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345
  1. # Port on which the server is listening. You must select a different
  2. # port from your standard http web server if it is running on the same
  3. # computer.
  4. Port 8090
  5. # Address on which the server is bound. Only useful if you have
  6. # several network interfaces.
  7. BindAddress 0.0.0.0
  8. # Number of simultaneous requests that can be handled. Since FFServer
  9. # is very fast, it is more likely that you will want to leave this high
  10. # and use MaxBandwidth, below.
  11. MaxClients 1000
  12. # This the maximum amount of kbit/sec that you are prepared to
  13. # consume when streaming to clients
  14. MaxBandwidth 1000
  15. # Access Log file (uses standard Apache log file format)
  16. # '-' is the standard output
  17. CustomLog -
  18. # Suppress that if you want to launch ffserver as a daemon
  19. NoDaemon
  20. ##################################################################
  21. # Definition of the live feeds. Each live feed contains one video
  22. # and/or audio sequence coming from an ffmpeg encoder or another
  23. # ffserver. This sequence may be encoded simultaneously with several
  24. # codecs at several resolutions.
  25. <Feed feed1.ffm>
  26. # You must use 'ffmpeg' to send a live feed to ffserver. In this
  27. # example, you can type:
  28. #
  29. # ffmpeg http://localhost:8090/feed1.ffm
  30. # ffserver can also do time shifting. It means that it can stream any
  31. # previously recorded live stream. The request should contain:
  32. # "http://xxxx?date=[YYYY-MM-DDT][[HH:]MM:]SS[.m...]".You must specify
  33. # a path where the feed is stored on disk. You also specify the
  34. # maximum size of the feed (100M bytes here). Default:
  35. # File=/tmp/feed_name.ffm FileMaxSize=5M
  36. File /tmp/feed1.ffm
  37. FileMaxSize 200K
  38. # You could specify
  39. # ReadOnlyFile /saved/specialvideo.ffm
  40. # This marks the file as readonly and it will not be deleted or updated
  41. # Specify launch in order to start ffmpeg automatically
  42. #Launch
  43. # Only allow connections from localhost to the feed
  44. ACL allow 127.0.0.1
  45. </Feed>
  46. ##################################################################
  47. # Now you can define each stream which will be generated from the
  48. # original audio and video stream. Each format has a filename (here
  49. # 'test1.mpg'). FFServer will send this stream when answering a
  50. # request containing this filename.
  51. <Stream test1.mpg>
  52. # coming from live feed 'feed1'
  53. Feed feed1.ffm
  54. # Format of the stream : you can choose among:
  55. # mpeg : MPEG1 multiplexed video and audio
  56. # mpegvideo : only MPEG1 video
  57. # mp2 : MPEG2 audio (use AudioCodec to select layer 2 and 3 codec)
  58. # ogg : Ogg format (Vorbis audio codec)
  59. # rm : Real Networks compatible stream. Multiplexed audio and video.
  60. # ra : Real Networks compatible stream. Audio only.
  61. # mpjpeg : Multipart JPEG (works with Netscape without any plugin)
  62. # jpeg : Generate a single JPEG image.
  63. # asf : ASF compatible streaming (Windows Media Player format).
  64. # swf : Macromedia flash(tm) compatible stream
  65. # avi : AVI format (open divx video, mpeg audio sound)
  66. # master : special ffmpeg stream used to duplicate a server
  67. Format mpeg
  68. # Bitrate for the audio stream. Codecs usually support only a few
  69. # different bitrates.
  70. AudioBitRate 32
  71. # Number of audio channels : 1 = mono, 2 = stereo
  72. AudioChannels 1
  73. # Sampling frequency for audio. When using low bitrates, you should
  74. # lower this frequency to 22050 or 11025. The supported frequencies
  75. # depend on the selected audio codec.
  76. AudioSampleRate 44100
  77. # Bitrate for the video stream.
  78. VideoBitRate 64
  79. # Ratecontrol buffer size
  80. VideoBufferSize 40
  81. # Number of frames per second
  82. VideoFrameRate 3
  83. # Size of the video frame : WxH (default: 160x128)
  84. # The following abbreviation are defined : sqcif, qcif, cif, 4cif
  85. VideoSize 160x128
  86. # transmit only intra frames (useful for low bitrates, but kills frame rate)
  87. #VideoIntraOnly
  88. # If non intra only, an intra frame is transmitted every VideoGopSize
  89. # frames Video synchronization can only begin at an I frames.
  90. VideoGopSize 12
  91. # More MPEG4 parameters
  92. # VideoHighQuality
  93. # Video4MotionVector
  94. # Choose your codecs:
  95. #AudioCodec mp2
  96. #VideoCodec mpeg1video
  97. # Suppress audio
  98. #NoAudio
  99. # Suppress video
  100. #NoVideo
  101. #VideoQMin 3
  102. #VideoQMax 31
  103. # Set this to the number of seconds backwards in time to start. Note that
  104. # most players will buffer 5-10 seconds of video, and also you need to allow
  105. # for a key frame to appear in the data stream.
  106. #PreRoll 15
  107. # ACL:
  108. # You can allow ranges of addresses (or single addresses)
  109. #ACL ALLOW <first address> <last address>
  110. # You can deny ranges of addresses (or single addresses)
  111. #ACL DENY <first address> <last address>
  112. # You can repeat the ACL allow/deny as often as you like. It is on a per
  113. # stream basis. The first match defines the action. If there are no matches,
  114. # then the default is the inverse of the last ACL statement.
  115. #
  116. # Thus 'ACL allow localhost' only allows access from localhost.
  117. # 'ACL deny 1.0.0.0 1.255.255.255' would deny the whole of network 1 and
  118. # allow everybody else.
  119. </Stream>
  120. ##################################################################
  121. # Example streams
  122. # Multipart JPEG
  123. #<Stream test.mjpg>
  124. #Feed feed1.ffm
  125. #Format mpjpeg
  126. #VideoFrameRate 2
  127. #VideoIntraOnly
  128. #NoAudio
  129. #</Stream>
  130. # Single JPEG
  131. #<Stream test.jpg>
  132. #Feed feed1.ffm
  133. #Format jpeg
  134. #VideoFrameRate 2
  135. #VideoIntraOnly
  136. ##VideoSize 352x240
  137. #NoAudio
  138. #</Stream>
  139. # Flash
  140. #<Stream test.swf>
  141. #Feed feed1.ffm
  142. #Format swf
  143. #VideoFrameRate 2
  144. #VideoIntraOnly
  145. #NoAudio
  146. #</Stream>
  147. # ASF compatible
  148. <Stream test.asf>
  149. Feed feed1.ffm
  150. Format asf
  151. VideoFrameRate 15
  152. VideoSize 352x240
  153. VideoBitRate 256
  154. VideoBufferSize 40
  155. VideoGopSize 30
  156. AudioBitRate 64
  157. StartSendOnKey
  158. </Stream>
  159. # MP3 audio
  160. #<Stream test.mp3>
  161. #Feed feed1.ffm
  162. #Format mp2
  163. #AudioCodec mp3
  164. #AudioBitRate 64
  165. #AudioChannels 1
  166. #AudioSampleRate 44100
  167. #NoVideo
  168. #</Stream>
  169. # Ogg Vorbis audio
  170. #<Stream test.ogg>
  171. #Feed feed1.ffm
  172. #Title "Stream title"
  173. #AudioBitRate 64
  174. #AudioChannels 2
  175. #AudioSampleRate 44100
  176. #NoVideo
  177. #</Stream>
  178. # Real with audio only at 32 kbits
  179. #<Stream test.ra>
  180. #Feed feed1.ffm
  181. #Format rm
  182. #AudioBitRate 32
  183. #NoVideo
  184. #NoAudio
  185. #</Stream>
  186. # Real with audio and video at 64 kbits
  187. #<Stream test.rm>
  188. #Feed feed1.ffm
  189. #Format rm
  190. #AudioBitRate 32
  191. #VideoBitRate 128
  192. #VideoFrameRate 25
  193. #VideoGopSize 25
  194. #NoAudio
  195. #</Stream>
  196. ##################################################################
  197. # A stream coming from a file : you only need to set the input
  198. # filename and optionnally a new format. Supported conversions:
  199. # avi -> asf
  200. #<Stream file.rm>
  201. #File "/usr/local/httpd/htdocs/tlive.rm"
  202. #NoAudio
  203. #</Stream>
  204. #<Stream file.asf>
  205. #File "/usr/local/httpd/htdocs/test.asf"
  206. #NoAudio
  207. #Author "Me"
  208. #Copyright "Super MegaCorp"
  209. #Title "Test stream from disk"
  210. #Comment "Test comment"
  211. #</Stream>
  212. ##################################################################
  213. # RTSP examples
  214. #
  215. # You can access to this stream with the RTSP URL:
  216. # rtsp://localhost:5454/test1-rtsp.mpg
  217. #
  218. # A non standard RTSP redirector is also created. Its URL is:
  219. # http://localhost:8090/test1-rtsp.rtsp
  220. #<Stream test1-rtsp.mpg>
  221. #Format rtp
  222. #File "/usr/local/httpd/htdocs/test1.mpg"
  223. #</Stream>
  224. ##################################################################
  225. # SDP/multicast examples
  226. #
  227. # If you want to send your stream in multicast, you must set the
  228. # multicast address with MulticastAddress. The port and the TTL can
  229. # also be set.
  230. #
  231. # An SDP file is automatically generated by ffserver by adding the
  232. # 'sdp' extension to the stream name (here
  233. # http://localhost:8090/test1-sdp.sdp). You should usually give this
  234. # file to your player to play the stream.
  235. #
  236. # The 'NoLoop' option can be used to avoid looping when the stream is
  237. # terminated.
  238. #<Stream test1-sdp.mpg>
  239. #Format rtp
  240. #File "/usr/local/httpd/htdocs/test1.mpg"
  241. #MulticastAddress 224.124.0.1
  242. #MulticastPort 5000
  243. #MulticastTTL 16
  244. #NoLoop
  245. #</Stream>
  246. ##################################################################
  247. # Special streams
  248. # Server status
  249. <Stream stat.html>
  250. Format status
  251. # Only allow local people to get to the status
  252. ACL allow localhost
  253. ACL allow 192.168.0.0 192.168.255.255
  254. #FaviconURL http://pond1.gladstonefamily.net:8080/favicon.ico
  255. </Stream>
  256. # Redirect index.html to the appropriate site
  257. <Redirect index.html>
  258. URL http://www.ffmpeg.org/
  259. </Redirect>