Reputation: 362
I have an m3u8 streaming url that I need to play it in and android HTML5 application. I can play the stream in VLC on both computer and mobile, but I cannot stream it with html5 video player.
<video width="640" height="360">
<source type="application/x-mpegURL" src="http://myfile.m3u8" />
</video>
Upvotes: 1
Views: 3031
Reputation: 362
The best solution is using this cordova plugin to stream the url using the native mobile player https://github.com/nchutchind/cordova-plugin-streaming-media
Upvotes: 1
Reputation: 607
The HTML5 video player can only play .mp4 or .webm. In addition, .m3u8 is not a video file, it is a plain text file used describe where media files are located.
You need to parse the .m3u8 file, get the URLs of the videos and play those with the HTML video player.
Upvotes: 0