HTTP Live Streaming HLS Tutorial for Beginners
>> YOUR LINK HERE: ___ http://youtube.com/watch?v=rPNr0-mNTFY
http live streaming (hls) • http live streaming example • http live streaming a practical guide • apache http live streaming • HTTP Live Streaming (HLS) is a standard for streaming video and audio over the internet. It allows you to stream video in high quality, with smooth playback and minimal buffering, even on devices with limited bandwidth or processing power. • Unlike other video streaming formats, HLS uses a technique called adaptive bitrate streaming, which adjusts the quality of the video in real time based on your internet connection and device capabilities. This means that you can watch a video in high quality, with minimal buffering, even if your internet connection is not very fast. • HLS is widely supported by media players and browsers on Apple devices, such as iPhones, iPads, and Macs. It also supports encryption using the AES-128 cipher, which is widely used to protect video content from unauthorized access. • Overall, HLS is a convenient and efficient way to watch video content over the internet, with smooth playback and high-quality audio and video, even on devices with limited bandwidth or processing power. • In this video, I tried to make viewers understand the basic workflow of HTTP Live Streaming also known as HLS. If you are an absolute beginner in video streaming and wanna start somewhere in 2024, this video is for you. • There are other protocols for video streaming including MPEG dash, RTSP, RTMP, cmaf, etc, HLS is one of the most popular ones. It's an adaptive bitrate streaming protocol over HTTP, which means the video quality will adjust based on the internet speed, as we see on youtube, and it's over HTTP, so no farewell disturbance • Watching the video, you will understand how HTTP live streaming works in about 5 minutes. To make easy these things, I used 1 mp4 video with FFmpeg on the apache server on my local host. • Here are the summarized steps of how HLS works: • A video is encoded and divided into small chunks, called segments. • A manifest file is created that lists the segments and their locations on a server. • A client device, such as a smartphone or smart TV, connects to the server and requests the manifest file. • The server sends the manifest file to the client's device. • The client device downloads and plays back the segments in real time, as they are received from the server. • If the internet connection slows down or becomes unstable, the HLS player on the client device will automatically switch to a lower-quality version of the video to avoid buffering or stuttering. • FFmpeg is used to convert the video according to the HLS protocol standard defined by Apple. the following command is used to convert/segment the video to hls compatible ts format and to generate the master m3u8 playlist file. • ffmpeg -i test.mp4 -hls_time 10 -hls_playlist_type vod -hls_segment_filename video_segments_%0d.ts hls_master_for_test.m3u8 • Then the generated files are placed on the apache server and accessed the master m3u8 file from the browser to play the video. The magic of HLS is that the m3u8 master playlist is basically a text file. • To learn more about the protocol, please follow the link below: https://tools.ietf.org/html/rfc8216 • HLS videos are typically played by MSE players like hls.js for web and Exo player or shaka player for android. Not supported in HTML by default. Safari and Microsoft Edge support hls videos without any add-ons. • I am interested to make more videos on live streaming, let me know in the comment the topic or area I should focus on. thanks for taking the time to watch my videos. • MPEG DASH Explained: • MPEG-DASH Streaming Explained for Beg... • HLS vs Dash comparison: • MPEG DASH vs HLS Streaming • Timestamps: • 0:00 - Chapter 1: What is HTTP Live Streaming (0:45) • 0:45 - Chapter 2: Preparing HLS Playlist File (m3u8) (1:37) • 2:22 - Chapter 3: Understanding FFmpeg Command (0:53) • 3:15 - Chapter 4: Serving HLS from Apache Server (1:19) • 4:34 - Chapter 5: Playing from a Browser (0:38) • 5:12 - Chapter 6: Playing through VLC (0:20) • 5:32 - Chapter 7: Outro (0:40) • 🙌 Enjoyed this video? Consider supporting my work! Buy me a coffee ☕ and help fuel more educational content on video compression, FFmpeg, Java, Spring Boot, and much more. Your support means the world to me! • 💖 Support Me on Buy Me a Coffee: https://www.buymeacoffee.com/monirzaman
#############################
