Hello. I try to use ffmpeg and ffserver, but failed already many times. I have mpeg2video+mp2 http-stream (streamed from DVB by getstream) which I should convert to FLV for streaming to any flash player. At first I start ffserver with following options:
Port 8090 BindAddress 0.0.0.0 MaxHTTPConnections 2000 MaxClients 1000 MaxBandwidth 2000 CustomLog - NoDaemon <Feed feed1.ffm> File /tmp/feed1.ffm FileMaxSize 10M ACL allow 127.0.0.1 </Feed> <Stream test.flv> Feed feed1.ffm Format flv AudioBitRate 256 AudioChannels 2 AudioSampleRate 44100 AudioCodec adpcm_swf AVOptionAudio flags +global_header VideoCodec flv VideoSize 640x480 VideoBitRate 561 VideoBufferSize 256 AVOptionVideo flags +global_header </Stream> <Stream stat.html> Format status ACL allow localhost ACL allow 192.168.0.0 192.168.255.255 </Stream> Server starts sometimes writing "Mon Jun 7 13:20:21 2010 Codec bitrates do not match for stream 1". Next command in other tab (both adresses only local) $ ./ffmpeg -i http://tv2.mega.net.kz:8080/ntv -vcodec flv -b 561k -s 640x480 -acodec adpcm_swf -ab 256k -ar 44100 -ac 2 -f flv http://localhost:8090/feed1.ffm OK, it starts, and ffserver writes "*time* 127.0.0.1 - - [POST] "/feed1.ffm HTTP/1.1" 200 2380". Then I try to play this stream: $ ffplay http://localhost:8090/test.flv FFplay version SVN-r0.5.1-4:0.5.1-1ubuntu1 /--/ configuration: --//-- //--// [flv @ 0x9dce6a0]Could not find codec parameters (Video: flv, 561 kb/s) ... and nothing in console. Mplayer writes about an end of file. If I run ffmpeg without "-f flv" then ffmpeg writes: //--// [mpeg2video @ 0xa852700]mpeg_decode_postinit() failure Last message repeated 2 times [mpegts @ 0xa84b510]max_analyze_duration reached [mpegts @ 0xa84b510]Estimating duration from bitrate, this may be inaccurate Input #0, mpegts, from 'http://tv2.mega.net.kz:8080/ntv': Duration: N/A, start: 5963.286456, bitrate: 54528 kb/s Program 13 Stream #0.0[0x12d]: Video: mpeg2video, yuv420p, 720x576 [PAR 16:15 DAR 4:3], 54272 kb/s, 25.21 fps, 25 tbr, 90k tbn, 50 tbc Stream #0.1[0x12e]: Audio: mp2, 48000 Hz, 2 channels, s16, 256 kb/s Stream #0.2[0x12f]: Data: [6][0][0][0] / 0x0006 [scale @ 0xa9cbaf0]w:720 h:576 fmt:yuv420p -> w:640 h:480 fmt:yuv420p flags:0xa0000004 [flv @ 0xac53230][Eval @ 0xbf9219ac]undefined constant or missing ( [flv @ 0xac53230]Error parsing rc_eq "" Output #0, ffm, to 'http://localhost:8090/feed1.ffm': Stream #0.0: Audio: adpcm_swf, 44100 Hz, 2 channels, s16, 256 kb/s Stream #0.1: Video: flv, yuv420p, 640x480, q=2-31, 561 kb/s, 1000k tbn, 5 tbc Stream mapping: Stream #0.1 -> #0.0 Stream #0.0 -> #0.1 Error while opening encoder for output stream #0.1 - maybe incorrect parameters such as bit_rate, rate, width or height This is a final configuration, earlier I'd tried to use many others configurations, variants, chains... I'd fished out a lot of bugs while trying to run the chain. I use last version of ffmpeg downloaded from http://www.ffmpeg.org/releases/ffmpeg-checkout-snapshot.tar.bz2 What do I wrong? Why I have a trouble? _______________________________________________ ffserver-user mailing list ffserver-user@mplayerhq.hu https://lists.mplayerhq.hu/mailman/listinfo/ffserver-user