我无法弄清楚如何从VLC播放RTMP流。我可以通过Flash播放器在网上查看它没有问题。我通过firebug找到了关于流的信息:
<data>
<smilRoot>
<body>
<switchItem id="0-BO-18166" base="rtmp://wcdn101.nacevi.cz/ct-vod/_definst_?id=HRr8GUgv1FcCBzw1-01&publisher=lss" begin="0" duration="134" clipBegin="0" type="recorded" stat="ProjectId=3;ApplicationId=4;NodeId=9">
<video src="mp4:iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_720p.mp4" system-bitrate="3500" label="720p" enabled="true" />
<video src="mp4:iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_576p.mp4" system-bitrate="2000" label="576p" enabled="true" />
<video src="mp4:iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_404p.mp4" system-bitrate="1000" label="404p" enabled="true" />
<video src="mp4:iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_288p.mp4" system-bitrate="500" label="288p" enabled="true" />
</switchItem>
</body>
</smilRoot>
</data>
我试图使用rtmpdump,vlc及其组合播放404p流。我不太确定如何粘贴URL,但我尝试了所有我能想到的组合。我试过的一些例子:
rtmp://wcdn101.nacevi.cz:1935/ct-vod/_defins.t_?id=HRraUUgv1FKF42a-02&publisher=lss/mp4:iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_404p.mp4
rtmp://wcdn101.nacevi.cz:1935/ct-vod/_defins.t_?id=HRraUUgv1FKF42a-02&publisher=lss?mp4:iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_404p.mp4
rtmp://wcdn101.nacevi.cz:1935/ct-vod/_defins.t_?id=HRraUUgv1FKF42a-02&publisher=lss/?mp4:iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_404p.mp4
rtmp://wcdn101.nacevi.cz:1935/ct-vod/_defins.t_?id=HRraUUgv1FKF42a-02&publisher=lss/iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_404p.mp4
rtmp://wcdn101.nacevi.cz:1935/ct-vod/_defins.t_?id=HRraUUgv1FKF42a-02&publisher=lss?iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_404p.mp4
rtmp://wcdn101.nacevi.cz:1935/ct-vod/_defins.t_?id=HRraUUgv1FKF42a-02&publisher=lss/?iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_404p.mp4
这是rtpdump所说的:
$ rtmpdump -v -r "rtmp://wcdn101.nacevi.cz:1935/ct-vod/_defins.t_?id=HRraUUgv1FKF42a-02&publisher=lss/mp4:iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_404p.mp4"
RTMPDump v2.4
(c) 2010 Andrej Stepanchuk, Howard Chu, The Flvstreamer Team; license: GPL
WARNING: You haven't specified an output file (-o filename), using stdout
Connecting ...
INFO: Connected...
ERROR: Closing connection: NetStream.Play.StreamNotFound
VLC不断抛出错误:
[00007f7918008088] avio access error: Failed to open rtmp://wcdn101.nacevi.cz:1935/ct-vod/_defins.t_?id=HRraUUgv1FKF42a-02&publisher=lss/mp4:iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_404p.mp4: Unknown error 833925547
顺便说一句,我用wireshark嗅探了RTMP数据包,通信看起来像这样:
>..K..O...@...p.....>pb....#../.R.yj...VE`..i.?...Z.....0....'{~.....#.Q.4!.L.Ee."j.....<.(.........+....0K...~.......x. ...r.-.%O...4[d.........D.|L.
........,..bv.D..............K..MDg./w..:...t.../.R?...^d6...g...].4.....p.?fd9.2.C..._...V../...1z,....EB..ffS`=g...+....I1;...*P...)....S...iS...............connect.?..........app..4ct-vod/_definst_?id=HRs8fcCPpFaC6ea-02&publisher=lss..flashVer...LNX 11,2,202,406..swfUrl..Thttp://i.mgct.ceskatelevize.cz/global/swf/player/player_1.45.19c.swf?version=1.45.19c..tcUrl..Rrtmp://wcdn101.nacevi.cz:1935/ct-vod/_defi.nst_?id=HRs8fcCPpFaC6ea-02&publisher=lss..fpad....capabilities.@m........audioCodecs.@.........videoCodecs.@o.......
videoFuncti.on.?.........pageUrl...http://www.ceskatelevize.cz..objectEncoding.@.......................&%..............&%..................................................._result.?..........fmsVer...FMS/3,5,7,7009..capabilities.@?........mode.?.............level...status..code...NetConnection.Connect.Success..description...Connection succeeded...data.......version..
3,5,7,7009.....clientid.A..L8.....objectEncoding.@.............m.........&%....t............createStream.@........................_result.@.........?.......B.....
...........C.....[.....FCSubscribe............?mp4:iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_404p.mp4...............
onFCSubscribe...........
...level.
status.code.)NetStream.Play.Start.description..%FCSubscribe to stream iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_404p.mp4..clientid.A..L8.......{..f.........play............?mp4:iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_404p.mp4..........A.[...............................onStatus.............level...status..code...NetStream.Play.Reset..description..RPlaying and resetting iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_404p.mp4...clientid.A..L8..........................................E..........onStatus.............level...status..code...NetStream.Play.Start..description..LStarted playing iVysilani/2014/10/08/KristynaLiskaBokCT-081014-MP4_404p.mp4...clientid.A..L8....
我确信我做错了什么,有人能给我一个如何播放这个流的提示吗?
答案 0 :(得分:1)
我一直想用VLC播放RTMP流而没有成功,并且得到了和你一样的错误。
Unknown error 833925547
以及rtmpdump
我也得到ERROR: Closing connection: NetStream.Play.StreamNotFound
我使用的是VLC 2.1.6,它附带了Ubuntu 14.04和相应版本的rtmpdump。
所以,碰巧我把rtmp url给了一个使用Windows操作系统的朋友和一个使用Mac OS的朋友。他们都没有问题地打开我的网址。
VLC可能会在Linux上使用一些被破坏的后端(即rtmpdump)。
我想我必须为VLC提交一个错误,我确实将Ubuntu 14.04中的2.1.6 VLC升级到2.2.1 - 它再次无效。我自己尝试了一个Windows(2.2.1),它打开了!
到目前为止,我目前的状况如下:
Ubuntu 14.04
VLC 2.1.6 - CANNOT OPEN the rtmp that I provide (myself)
VLC 2.2.1 - CANNOT OPEN the rtmp that I provide (myself)
Windows
VLC 2.1.5 - OPENS WITHOUT PROBLEM the rtmp I provide (my friend)
VLC 2.2.1 - OPENS WITHOUT PROBLEM the rtmp I provide (myself)
Mac OS
VLC 2.2.1 - OPENS WITHOUT PROBLEM the rtmp I provide (my friend)