这个场景中,咱们能够直接利用强大的ffmpeg将本地文件,以直播的方式输出html
ffmpeg -re -stream_loop -1 -fflags +genpts -i F:\05CACHE\ss.mp4 -vcodec copy -acodec copy -strict -2 -f flv -y rtmp://demo.liveqing.com:10085/hls/marvin1311
此处的rtmp://demo.liveqing.com:10085/hls/test 是示例的推流服务地址git
运行以下:
ide
此时rtmp://demo.liveqing.com:10085/hls/marvin1311 也是播放地址oop
除了一路.net
此时流媒体服务提供了另外的两路流插件
也可使用流媒体服务提供的播放器服务
http://demo.liveqing.com:10080/LivePlayer.htmlhtm
点击下面的地址便可播放
http://demo.liveqing.com:10080/LivePlayer.html?videoUrl=rtmp://demo.liveqing.com:10085/hls/marvin1311blog