diff --git a/html/index.html b/html/index.html index d2f13f1..f03fcf3 100644 --- a/html/index.html +++ b/html/index.html @@ -1,31 +1,44 @@ + - HLS Player Test - + + + + HLS Player Test + + + -

Live Stream

+

Live Stream

+
+
+ + if (Hls.isSupported()) { + var hls = new Hls(); + hls.loadSource(videoSrc); + hls.attachMedia(video); + hls.on(Hls.Events.MANIFEST_PARSED, function () { + video.play(); + }); + } else if (video.canPlayType('application/vnd.apple.mpegurl')) { + video.src = videoSrc; + video.addEventListener('loadedmetadata', function () { + video.play(); + }); + } + \ No newline at end of file