ffmpeg 可以处理来自 FMS 的 rtmp 流吗?

发布于 2024-09-06 13:57:45 字数 396 浏览 3 评论 0原文

ffmpeg -i rtmp:/vid2/recordings -acodec copy -vcodec copy -y captured.flv

ffmpeg -i rtmp://localhost/vid2/recordings -acodec copy -vcodec copy -y captured.flv

上面的命令只给我这个错误:

rtmp://localhost/vid2/recordings: no such file or directory

难道 ffmpeg 不应该能够处理 rtmp 流吗?

ffmpeg -i rtmp:/vid2/recordings -acodec copy -vcodec copy -y captured.flv

or

ffmpeg -i rtmp://localhost/vid2/recordings -acodec copy -vcodec copy -y captured.flv

The above command only give me this error:

rtmp://localhost/vid2/recordings: no such file or directory

Isn't ffmpeg supposed to be able to handle rtmp streams?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(5

沩ん囻菔务 2024-09-13 13:57:45

您使用的是 Xuggler 版本的 ffmpeg 吗?这是一个教程,解释如何使用 Xuggler ffmpeg 获取和编码 rtmp 流。

http://wiki.xuggle.com/Live_Encoding_Tutorial

Are you using the Xuggler version of ffmpeg? Here's a tutorial explaining how to obtain and encode rtmp streams with the Xuggler ffmpeg.

http://wiki.xuggle.com/Live_Encoding_Tutorial

一曲琵琶半遮面シ 2024-09-13 13:57:45

无需使用 Xuggler 的构建。 ffmpeg .6 版本确实支持 rtmp。但是,请确保您使用以下命令进行编译

--enable-librtmp

No need to use Xuggler's build. Version .6 of ffmpeg does support rtmp. However, make sure you compile with

--enable-librtmp
壹場煙雨 2024-09-13 13:57:45

ffmpeg可以捕获rtmp的流。尝试输入 1935 等端口,

ffmpeg -i rtmp://localhost:1935/live/newStream

但在执行此操作之前检查 newStream 是否存在。如果没有,请打开新的cmd并进入ffmpeg/bin文件夹

ffmpeg -i sample.avi -f flv rtmp://localhost/live/newStream

然后尝试运行第一个代码。

ffmpeg can catch the stream of rtmp. Try it with entering port like 1935

ffmpeg -i rtmp://localhost:1935/live/newStream

But before doing that check if newStream exist. If not, open new cmd and enter ffmpeg/bin folder

ffmpeg -i sample.avi -f flv rtmp://localhost/live/newStream

Then try to run first code.

谈情不如逗狗 2024-09-13 13:57:45

似乎可以(分析持续时间以消除初始延迟)

$ ffplay -analyzeduration 0 -i "rtmp://localhost/live/stream_name live=1"

请参阅http://betterlogic.com/roger/2012/08/ffmpeg-receiving-rtmp-stream-from-flash-media-server/ 有关如何流式传输的一些说明,以及。

appears it can (analyzeduration to get rid of an initial delay)

$ ffplay -analyzeduration 0 -i "rtmp://localhost/live/stream_name live=1"

See http://betterlogic.com/roger/2012/08/ffmpeg-receiving-rtmp-stream-from-flash-media-server/ for some instructions on how to stream to it, as well.

Smile简单爱 2024-09-13 13:57:45

我对 FFMPEG 也有同样的问题。

我在 FMS 上正确发布 FFMPEG 视频,并且可以在 FMS 视频播放器上看到该视频。

ffmpeg -re -i /home/videos/sample.mp4 -f flv rtmp://localhost/live/sample

现在我想创建直播。

对于这种情况,我在 linux 上的 FFMPEG 中使用此代码:

ffmpeg -re -i rtmp://localhost:1935/live/sample -vcodec copy -acodec copy -f flv     rtmp://localhost/livepkgr/sample_streamd?adbe-live-event=sample_event

通过使用此语法,我得到相同的错误:

Closing connection: NetStream.Play.StreamNotFound
rtmp://localhost:1935/live/sample: Operation not permitt

I have same problem with FFMPEG.

I publish video from FFMPEG on FMS correctly and I can see that on the FMS video player.

ffmpeg -re -i /home/videos/sample.mp4 -f flv rtmp://localhost/live/sample

Now I would like to create live stream.

For this case I use this code in the FFMPEG on linux:

ffmpeg -re -i rtmp://localhost:1935/live/sample -vcodec copy -acodec copy -f flv     rtmp://localhost/livepkgr/sample_streamd?adbe-live-event=sample_event

By use this syntax I get same error:

Closing connection: NetStream.Play.StreamNotFound
rtmp://localhost:1935/live/sample: Operation not permitt
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文