我想讓videoJs與實時流一起工作我有一個包含rtmp直播流的鏈接。
http://www.iptv-player.com/index.php?fdb=1&title=%20+JIMTV%20%20&stream=rtmp%3A%2F%2Frtmp.jim.stream.vmmacdn.be%2Fvmma-jim-rtmplive-live%2Fjim
和玩家本身有一個鏈接是:
RTMP://rtmp.jim.stream.vmmacdn.be/vmma-jim-rtmplive-live/jim
目前我只是試圖讓直播在videoJs播放器上播放我已經獲得了本地視頻的工作內容,無法理解如何讓直播工作。
這裏是我的東西我迄今爲止VideoJs與直播流
<!DOCTYPE html>
<html>
<head>
<title>Video.js | HTML5 Video Player</title>
<!-- Chang URLs to wherever Video.js files will be hosted -->
<link href="video-js.css" rel="stylesheet" type="text/css">
<!-- video.js must be in the <head> for older IEs to work. -->
<script src="video.js"></script>
<!-- Unless using the CDN hosted version, update the URL to the Flash SWF -->
<script>
videojs.options.flash.swf = "video-js.swf";
</script>
</head>
<body>
<video id="example_video_1" class="video-js vjs-default-skin" controls preload="none" width="640" height="264"
poster="http://www.pageresource.com/wallpapers/wallpaper/bleach-ichigo-mugetsu-here-size-original_215405.jpg"
data-setup="{}">
<
<source src="http://www.iptv-player.com/index.php?fdb=1&title=%20+JIMTV%20%20&stream=rtmp%3A%2F%2Frtmp.jim.stream.vmmacdn.be%2Fvmma-jim-rtmplive-live%2Fjim" type='video/mp4' />
<!--<track kind="captions" src="demo.captions.vtt" srclang="en" label="English"></track>--><!-- Tracks need an ending tag thanks to IE9 -->
<!--<track kind="subtitles" src="demo.captions.vtt" srclang="en" label="English"></track>--><!-- Tracks need an ending tag thanks to IE9 -->
</video>
</body>
</html>
我已經試過了應用程序/ x-mpegurl」它只是打破了玩家。如果我在類型爲「rtmp/flv」時按下播放按鈕,播放器就會中斷。 –