Answer the question
In order to leave comments, you need to log in
How to create a playlist from existing short video files for hls and mpeg-dash?
Video files lasting several seconds are dynamically added to the server. The task is to organize their playback in one thread. In one of the previous questions, I was prompted about the use of HLS, and in the end I stumbled upon the nginx-rtmp module. HLS, as it turned out, is not supported by all clients, and I learned more about MPEG-DASH. But in all the examples that I looked at, there is a split into a playlist of one large video file. The question remains how to create a playlist for existing short videos, as well as when adding a new video to the server, add it to the playlist. Or maybe there is another solution to the problem?
Answer the question
In order to leave comments, you need to log in
well, how would it turn out only from javascript to switch to the next video
<script type="text/javascript">
var nextVideo = "path/of/next/video.mp4";
var videoPlayer = document.getElementById('videoPlayer');
videoPlayer.onended = function(){
videoPlayer.src = nextVideo;
}
</script>
<video id="videoPlayer" src="path/of/current/video.mp4" autoplay autobuffer controls />
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question