Marco Ganzo
Marco Ganzo

Reputation: 5

Can someone explain me how i can use HLS on uploading files

I'm saw a project : videojs-contrib-hls

https://github.com/videojs/videojs-contrib-hls

also found on jwplayer:

https://support.jwplayer.com/customer/portal/articles/1430240-hls-adaptive-streaming

But i didn't find any upload part. How i upload files ( or let someone upload) And after that i use the player? How it works? how i can use this from upload -> streaming?

Upvotes: 0

Views: 1470

Answers (1)

Mick
Mick

Reputation: 25471

HLS is a an adaptive bit rate streaming protocol.

These protocols involve the server having several different copies or encodings of the video at different bit rates, all broken into, for example, 2 second chunks.

The client (the device playing the video) requests the chunks from the server depending on the available bandwidth at the time. For example it might start by requesting the first 2 seconds from the lowest bitrate copy of the video and if that downloads ok then request the next 2 seconds from the next highest bitrate, and so on until it either reaches the maximum bitrate or it sees a delay downloading a chunk. If the bandwidth decreases during playback at any time it can request the next chunk from a lower bitrate.

So for you case, you need to upload the video to a server, create multiple bit rate encodings of the video, chunk them up, and then packages them in the streaming format you want (HLS in your case).

This is not trivial so it would probably be worth you looking at streaming servers and services to get a feel for whether it might be easiest for you to build on or use one of those servers/services. Some examples are:

Upvotes: 1

Related Questions