<div dir="ltr">Makes sense. So currently I'm trying to have all the playlists in a separate pipeline since that prevents me from writing a lot of duplicate code. Is there any drawback to having each resolution on a separate pipeline instead of using tee and doing everything in just one pipeline?<div><br></div><div>Thanks!</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Jul 2, 2021 at 12:50 PM Michiel Konstapel <<a href="mailto:michiel@aanmelder.nl">michiel@aanmelder.nl</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On 26-06-2021 22:05, Samyak via gstreamer-devel wrote:<br>
> Hey,<br>
> I am trying to serve HLS content with adaptive bitrate streaming <br>
> using GStreamer. I know GStreamer has hlssink2 but I wonder if there's a <br>
> way for gstreamer to generate a primary manifest like described here: <br>
> <a href="https://developer.apple.com/documentation/http_live_streaming/example_playlists_for_http_live_streaming/creating_a_primary_playlist" rel="noreferrer" target="_blank">https://developer.apple.com/documentation/http_live_streaming/example_playlists_for_http_live_streaming/creating_a_primary_playlist</a> <br>
> <<a href="https://developer.apple.com/documentation/http_live_streaming/example_playlists_for_http_live_streaming/creating_a_primary_playlist" rel="noreferrer" target="_blank">https://developer.apple.com/documentation/http_live_streaming/example_playlists_for_http_live_streaming/creating_a_primary_playlist</a>>. <br>
> I am using gstreamer to transcode the input stream into multiple <br>
> resolutions and bitrates so is there a way to give this all to hlssink <br>
> so that it will generate the segments for all the resolutions that I am <br>
> serving as well as make the appropriate manifests? Also, is there any <br>
> way to force key frames to be 2 seconds apart?<br>
> <br>
> Thanks!<br>
<br>
I don't think gstreamer can generate the primary playlist. However, the <br>
format is quite simple, and it doesn't change while the stream is <br>
running, so it's fairly easy to generate that file yourself and link to <br>
the dynamically generated ones. If you want multiple bit rates, you have <br>
to set up separate encoder and hlssink(2) branches yourself.<br>
<br>
hlssink2 will by default request key frames at segment boundaries <br>
(send-keyframe-requests) so if there is an encoder upstream, it should <br>
emit a key frame, allowing hlssink2 to start a new segment. The <br>
target-duration property determines the desired segment duration, so <br>
that's the interval at which it will request key frames.<br>
<br>
Cheers,<br>
Michiel<br>
</blockquote></div>