最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

javascript - How to put applicationx-mpegURL in source in videojs - Stack Overflow

programmeradmin3浏览0评论

I'm not JavaScript guy but I have project with js and plugin VIDEOJS (Video.js v4.6.4 Copyright 2014 Brightcove, Inc. .js/blob/master/).

I recived an error:

video.dev.js:1384 VIDEOJS: ERROR: (CODE:4 MEDIA_ERR_SRC_NOT_SUPPORTED) The video could not be loaded, either because the server or network failed or because the format is not supported.

I know that solved of this problem can be put: <source src="video/test.m3u8" type="application/x-mpegURL">. but my question is, how to do this.

I'm not JavaScript guy but I have project with js and plugin VIDEOJS (Video.js v4.6.4 Copyright 2014 Brightcove, Inc. https://github./videojs/video.js/blob/master/).

I recived an error:

video.dev.js:1384 VIDEOJS: ERROR: (CODE:4 MEDIA_ERR_SRC_NOT_SUPPORTED) The video could not be loaded, either because the server or network failed or because the format is not supported.

I know that solved of this problem can be put: <source src="video/test.m3u8" type="application/x-mpegURL">. but my question is, how to do this.

Share Improve this question asked Jul 7, 2017 at 9:45 KaiKai 5934 gold badges8 silver badges15 bronze badges
Add a ment  | 

1 Answer 1

Reset to default 5

Original, but now outdated answer:

For browsers without native HLS support you need the videojs-contrib-hls plugin: http://videojs.github.io/videojs-contrib-hls/

As of Video.js v7, HLS is supported by default and does not require anything additional in the default build. HLS playback is either native (Safari, iOS) or Video.js's Media Source Extensions playback engine https://github./videojs/http-streaming, which replaced videojs-contrib-hls.

发布评论

评论列表(0)

  1. 暂无评论