Question: HLS delivery #3728
Replies: 6 comments
-
Definitely need more information. What's your configuration file look like? Also, are you able to play it from a browser? (this would use video.js or maybe hls.js) What endpoint are you trying to connect to? |
Beta Was this translation helpful? Give feedback.
-
Hi, see my config below, I use this to recieve an RTMP stream from OBS, transcode into three qualities and then play over HLS in a browser:
This config produces HLS playlists (.m3u8) and video fragments (.ts) inside /var/www/video/[app]/ You would stream over RTMP using the below settings:
Your web server should serve the directory
You can load these playlists using a video player that supports HLS. In iOS the HLS also supports a Master Playlist which points to the other three playlists and will auto-select one based on pre-determined bandwidth. SRS can't generate this Master Playlist currently but you can serve one statically, this is what it would look like:
|
Beta Was this translation helpful? Give feedback.
-
Hi, thanks for your example @Baa14453 it works really well :) I would like to inject a custom master playlist into OvenPlayer but I don't understand how I can do it. Like SRS can't generate this master playlist with the bandwidth info, how can I bypass it and inject my custom master playlist like in your example? |
Beta Was this translation helpful? Give feedback.
-
Assuming your streamkey or app name never changes (.e.g you always use the same URL when you stream), then you can just create a static master playlist and serve it from a web-server, then tell OvenPlayer to load the Master Playlist as a source e.g. Create
In OvenPlayer, point the source to your master playlist: |
Beta Was this translation helpful? Give feedback.
-
Wow that's great, it works perfectly :) Thank you for this quick response and the detailed explanations |
Beta Was this translation helpful? Give feedback.
-
👍 @Baa14453 Thanks. |
Beta Was this translation helpful? Give feedback.
-
Hello I want to use RTMP to publish stream and HLS for delivery but I could not figure it out. I tried transcoding rtmp with ffmpeg but I could not play it for example on an iphone.
Can someone help me to publish by rtmp and deliver with HLS?
Beta Was this translation helpful? Give feedback.
All reactions