ffmpeg rtmp 流媒体
我已经连接了 Red5 oflaDemo 并且工作正常
当我尝试使用 ffmpeg 来rtmp 流 flv 文件时,我收到了这个错误
root@zzz-OptiPlex-170L:~# ffmpeg -re -i '/usr/share/red5/webapps/oflaDemo/streams
/avatar.flv' -vcodec libx264 -acodec copy -ab 128.k -ac 2 -ar 44100 -r 25
-s 320x240 -vb 660.k -preset slow -f flv 'rtmp://localhost/oflaDemo/streamTest'
Output #0, flv, to 'rtmp://localhost/oflaDemo/streamTest':
Metadata:
encoder : Lavf53.24.2
Stream #0:0: Video: h264 ([7][0][0][0] / 0x0007), yuv420p, 320x240, q=-1--1, 660 kb/s, 1k tbn, 25 tbc
Stream #0:1: Audio: mp3 ([2][0][0][0] / 0x0002), 11025 Hz, mono, 16 kb/s
Stream mapping:
Stream #0:0 -> #0:0 (flv -> libx264)
Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for help
frame= 15 fps= 0 q=0.0 size= 0kB time=00:00:00.00 bitrate= 0.0kbits/s
frame= 27 fps= 26 q=0.0 size= 0kB time=00:00:00.00 bitrate= 0.0kbits/s
frame= 40 fps= 26 q=0.0 size= 0kB time=00:00:00.00 bitrate= 0.0kbits/s
frame= 52 fps= 24 q=27.0 size= 7kB time=00:00:00.-4 bitrate=-1362.0kbits
I have Red5 oflaDemo Connected and working fine
When I try to rtmp stream flv file with ffmpeg I am getting this errors
root@zzz-OptiPlex-170L:~# ffmpeg -re -i '/usr/share/red5/webapps/oflaDemo/streams
/avatar.flv' -vcodec libx264 -acodec copy -ab 128.k -ac 2 -ar 44100 -r 25
-s 320x240 -vb 660.k -preset slow -f flv 'rtmp://localhost/oflaDemo/streamTest'
Output #0, flv, to 'rtmp://localhost/oflaDemo/streamTest':
Metadata:
encoder : Lavf53.24.2
Stream #0:0: Video: h264 ([7][0][0][0] / 0x0007), yuv420p, 320x240, q=-1--1, 660 kb/s, 1k tbn, 25 tbc
Stream #0:1: Audio: mp3 ([2][0][0][0] / 0x0002), 11025 Hz, mono, 16 kb/s
Stream mapping:
Stream #0:0 -> #0:0 (flv -> libx264)
Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for help
frame= 15 fps= 0 q=0.0 size= 0kB time=00:00:00.00 bitrate= 0.0kbits/s
frame= 27 fps= 26 q=0.0 size= 0kB time=00:00:00.00 bitrate= 0.0kbits/s
frame= 40 fps= 26 q=0.0 size= 0kB time=00:00:00.00 bitrate= 0.0kbits/s
frame= 52 fps= 24 q=27.0 size= 7kB time=00:00:00.-4 bitrate=-1362.0kbits
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
嗯,
-ab 128.k
和-vb 660.k
中不应该有句点,而且它只是-b
,而不是-vb
...或者我错过了什么?如果您使用-acodec copy
我不知道如何指定-ab
音频比特率或-ar
...这可能会工作得更好:
Well,
-ab 128.k
and-vb 660.k
shouldn't have periods in them, and also its just-b
, not-vb
... or am I missing something? And if you use-acodec copy
I don't see how you can specify an-ab
audio bitrate or-ar
either...This might work better: