linux – Gstreamer tcpserversink v0.10 vs 1.0和HTML5视频标签
发布时间:2020-12-14 00:34:37 所属栏目:Linux 来源:网络整理
导读:我在我的网站中嵌入了 HTML5视频标签,源代码是gstreamer流. 我有一个关于gst 0.10的管道: gst-launch-0.10 -v videotestsrc ! theoraenc ! oggmux ! queue ! tcpserversink port=8080 sync-method=2 我可以通过vlc连接到这个流,如下所示: vlc tcp://localh
我在我的网站中嵌入了
HTML5视频标签,源代码是gstreamer流.
我有一个关于gst 0.10的管道: gst-launch-0.10 -v videotestsrc ! theoraenc ! oggmux ! queue ! tcpserversink port=8080 sync-method=2 我可以通过vlc连接到这个流,如下所示: vlc tcp://localhost:8080 我还可以在HTML5视频标记中使用该网址,并按预期显示视频. 现在我尝试为gst 1.0调整它: gst-launch-1.0 -v videotestsrc ! theoraenc ! oggmux ! queue ! tcpserversink port=8080 sync-method=2 我再次使用vlc连接到流,但我不能在视频标签中使用此流. 这让我发疯,我把管道剥离到最低限度,我不明白为什么它不起作用. 为什么它适用于旧的gst和vlc,而不是视频标签中的新gst? 解决方法
让我告诉你这是一个有趣的问题.经过几个小时的鬼混,我仍然无法找到适合我的Windows 8.1盒子的解决方案.
我有一些运气流.ogg: gst-launch-1.0 -v videotestsrc is-live=true ! clockoverlay shaded-background=true font-desc="Sans 38" ! theoraenc ! oggmux ! tcpserversink host=127.0.0.1 port=8080 但正确显示流仍然是一个挑战. 这是我正在使用的html文件: <html> <title>A simple HTML5 video test</title> </html> <body> <video autoplay controls width=320 height=240> <source src="http://localhost:8080" type="video/ogg"> You browser doesn't support element <code>video</code>. </video> </body> >谷歌浏览器38.0.2125.122显示流但几秒钟后停止(不知道原因); 尽管VLC正确播放,但我对.mp4流没有运气: gst-launch-1.0 videotestsrc is-live=true ! clockoverlay shaded-background=true font-desc="Sans 38" ! x264enc ! mpegtsmux ! queue ! tcpserversink host=127.0.0.1 port=8080 在测试期间启用/禁用了卡巴斯基反病毒和IIS.在禁用IIS后,我在Google Chrome上取得了一些成功. (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |