Advertisement
Guest User

ffmpeg_mpegts

a guest
Oct 19th, 2012
175
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 6.03 KB | None | 0 0
  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.  
  6. # Address on which the server is bound. Only useful if you have
  7. # several network interfaces.
  8. BindAddress 0.0.0.0
  9.  
  10. # Number of simultaneous HTTP connections that can be handled. It has
  11. # to be defined *before* the MaxClients parameter, since it defines the
  12. # MaxClients maximum limit.
  13. MaxHTTPConnections 2000
  14.  
  15. # Number of simultaneous requests that can be handled. Since FFServer
  16. # is very fast, it is more likely that you will want to leave this high
  17. # and use MaxBandwidth, below.
  18. MaxClients 1000
  19.  
  20. # This the maximum amount of kbit/sec that you are prepared to
  21. # consume when streaming to clients.
  22. MaxBandwidth 1000
  23.  
  24. # Access log file (uses standard Apache log file format)
  25. # '-' is the standard output.
  26. CustomLog -
  27.  
  28. # Suppress that if you want to launch ffserver as a daemon.
  29. NoDaemon
  30.  
  31.  
  32. ##################################################################
  33. # Definition of the live feeds. Each live feed contains one video
  34. # and/or audio sequence coming from an ffmpeg encoder or another
  35. # ffserver. This sequence may be encoded simultaneously with several
  36. # codecs at several resolutions.
  37.  
  38. <Feed feed1.ffm>
  39.  
  40. # You must use 'ffmpeg' to send a live feed to ffserver. In this
  41. # example, you can type:
  42. #
  43. # ffmpeg http://localhost:8090/feed1.ffm
  44.  
  45. # ffserver can also do time shifting. It means that it can stream any
  46. # previously recorded live stream. The request should contain:
  47. # "http://xxxx?date=[YYYY-MM-DDT][[HH:]MM:]SS[.m...]".You must specify
  48. # a path where the feed is stored on disk. You also specify the
  49. # maximum size of the feed, where zero means unlimited. Default:
  50. # File=/tmp/feed_name.ffm FileMaxSize=5M
  51. File /tmp/feed1.ffm
  52. FileMaxSize 5M
  53.  
  54. # You could specify
  55. # ReadOnlyFile /saved/specialvideo.ffm
  56. # This marks the file as readonly and it will not be deleted or updated.
  57.  
  58. # Specify launch in order to start ffmpeg automatically.
  59. # First ffmpeg must be defined with an appropriate path if needed,
  60. # after that options can follow, but avoid adding the http:// field
  61. Launch ffmpeg -r 15 -s 640x480 -f video4linux2 -i /dev/video0
  62.  
  63. # Only allow connections from localhost to the feed.
  64. ACL allow 127.0.0.1
  65.  
  66. </Feed>
  67.  
  68.  
  69. ##################################################################
  70. # Now you can define each stream which will be generated from the
  71. # original audio and video stream. Each format has a filename (here
  72. # 'test1.mpg'). FFServer will send this stream when answering a
  73. # request containing this filename.
  74.  
  75. <Stream test1.mpg>
  76.  
  77. # coming from live feed 'feed1'
  78. Feed feed1.ffm
  79.  
  80. # Format of the stream : you can choose among:
  81. # mpeg       : MPEG-1 multiplexed video and audio
  82. # mpegvideo  : only MPEG-1 video
  83. # mp2        : MPEG-2 audio (use AudioCodec to select layer 2 and 3 codec)
  84. # ogg        : Ogg format (Vorbis audio codec)
  85. # rm         : RealNetworks-compatible stream. Multiplexed audio and video.
  86. # ra         : RealNetworks-compatible stream. Audio only.
  87. # mpjpeg     : Multipart JPEG (works with Netscape without any plugin)
  88. # jpeg       : Generate a single JPEG image.
  89. # asf        : ASF compatible streaming (Windows Media Player format).
  90. # swf        : Macromedia Flash compatible stream
  91. # avi        : AVI format (MPEG-4 video, MPEG audio sound)
  92. Format mpegts
  93.  
  94. # Bitrate for the audio stream. Codecs usually support only a few
  95. # different bitrates.
  96. AudioBitRate 32
  97.  
  98. # Number of audio channels: 1 = mono, 2 = stereo
  99. AudioChannels 1
  100.  
  101. # Sampling frequency for audio. When using low bitrates, you should
  102. # lower this frequency to 22050 or 11025. The supported frequencies
  103. # depend on the selected audio codec.
  104. AudioSampleRate 44100
  105.  
  106. # Bitrate for the video stream
  107. VideoBitRate 100
  108.  
  109. # Ratecontrol buffer size
  110. VideoBufferSize 80000
  111.  
  112. # Number of frames per second
  113. VideoFrameRate 15
  114.  
  115. # Size of the video frame: WxH (default: 160x128)
  116. # The following abbreviations are defined: sqcif, qcif, cif, 4cif, qqvga,
  117. # qvga, vga, svga, xga, uxga, qxga, sxga, qsxga, hsxga, wvga, wxga, wsxga,
  118. # wuxga, woxga, wqsxga, wquxga, whsxga, whuxga, cga, ega, hd480, hd720,
  119. # hd1080
  120. VideoSize 640x480
  121.  
  122. # Transmit only intra frames (useful for low bitrates, but kills frame rate).
  123. #VideoIntraOnly
  124.  
  125. # If non-intra only, an intra frame is transmitted every VideoGopSize
  126. # frames. Video synchronization can only begin at an intra frame.
  127. VideoGopSize 12
  128.  
  129. # More MPEG-4 parameters
  130. # VideoHighQuality
  131. # Video4MotionVector
  132.  
  133. # Choose your codecs:
  134. #AudioCodec mp2
  135. #VideoCodec mpeg1video
  136. AudioCodec vorbis
  137. VideoCodec mpeg2video
  138.  
  139. # Suppress audio
  140. #NoAudio
  141.  
  142. # Suppress video
  143. #NoVideo
  144.  
  145. VideoQMin 1
  146. VideoQMax 5
  147.  
  148. # Set this to the number of seconds backwards in time to start. Note that
  149. # most players will buffer 5-10 seconds of video, and also you need to allow
  150. # for a keyframe to appear in the data stream.
  151. Preroll 0
  152.  
  153. # ACL:
  154.  
  155. # You can allow ranges of addresses (or single addresses)
  156. #ACL ALLOW <first address> <last address>
  157.  
  158. # You can deny ranges of addresses (or single addresses)
  159. #ACL DENY <first address> <last address>
  160.  
  161. # You can repeat the ACL allow/deny as often as you like. It is on a per
  162. # stream basis. The first match defines the action. If there are no matches,
  163. # then the default is the inverse of the last ACL statement.
  164. #
  165. # Thus 'ACL allow localhost' only allows access from localhost.
  166. # 'ACL deny 1.0.0.0 1.255.255.255' would deny the whole of network 1 and
  167. # allow everybody else.
  168.  
  169. </Stream>
  170.  
  171.  
  172. ##################################################################
  173. # Example streams
  174. ##################################################################
  175. # Special streams
  176.  
  177. # Server status
  178.  
  179. <Stream stat.html>
  180. Format status
  181.  
  182. # Only allow local people to get the status
  183. ACL allow localhost
  184. ACL allow 192.168.0.0 192.168.255.255
  185.  
  186. #FaviconURL http://pond1.gladstonefamily.net:8080/favicon.ico
  187. </Stream>
  188.  
  189.  
  190. # Redirect index.html to the appropriate site
  191.  
  192. <Redirect index.html>
  193. URL http://www.ffmpeg.org/
  194. </Redirect>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement