Target duration is the length of each segment, in seconds. Note that
hlssink will only start a new segment on a key frame, so if you want 3
second long segments, your encoder should produce a key frame (at least)
every 3 seconds. It is unrelated to the other two parameters (except
that a longer duration means fewer files will be produced).
Playlist length is how many files will be named in the playlist file, so
how much "history" is made available to the browser/player. Old segments
will be dropped from the playlist (which is rewritten every time a new
segment is produced) to keep the size of the playlist file down.
Alternatively, you can let it grow forever so anyone can jump into the
stream and seek back to the beginning.
Max-files is, as the documentation states, how many files will be kept
on disk: if set to 10, once segments 1, 2, 3... 10 have been written,
the oldest one will be deleted and you'll have segments 2 through 11 on
disk. So, max-files needs to at least cover the length of the playlist.
If you only need the segment files while the stream is live, you don't
need much more than that. However, you may want to keep the files around
for later (nonlive) playback.
HTH,
Michiel
On 17-12-2020 19:50, manas_mandal wrote:
> i would like to know what is significance of target-duration, playlist-length
> and max-files properties is there any link between target-duration and
> max-files on hls content? how these properties affects the output hlssink
>
> Regards
> Manas
>
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel