Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add HLS replay of streams #4032

Open
dams92210 opened this issue Dec 11, 2024 · 0 comments
Open

Add HLS replay of streams #4032

dams92210 opened this issue Dec 11, 2024 · 0 comments

Comments

@dams92210
Copy link

Describe the feature

Actually in the config file the HLS segments of a stream can be recorded in a folder (hlsDirectory) . But as soon as the stream has ended, there is no possibility to replay this HLS stream.

It would be great to add a feature so that a client application could implement a DVR functionnality on recorded HLS streams, a bit like the youtube live feature.

In detail:

  • Adding an hlsDVR: yes / no parameters would add the possibility to keep all needed files of the HLS stream:
    • record all m3u8 files generated in memory (index, video and audio tracks) in the hlsDirectory folder
    • keep all segments files in the hlsDirectory folder instead of being wipeout as soon as input stream has ended.
  • Adding an hlsDVRAddress: ip_port parameters would add the possibility to replay the stream, just by serving the recorded files as an http(s) server on this port address.

Example:
A stream called myStream is recorded in the [hlsDirectory]/myStream folder. Then accessing to [ip_of_mediamtxserver]:[hlsDVRAddress]/myStream/index.m3u8 with HLSjs would replay the stream.

Why this request and not using the existing record/playback feature?
The record / playback existing features does not solves the "immediate replay in multiple languages" of a stream. The record needs to be remuxed as multiple audio tracks is only supported with the experimental features flags depending on each navigator.
So I don't think this would compete with the actual record/playback feature.

Did I try to solve this myself?
Yes, I am trying to implement a grab of all segments and all m3u8 files but this is far from ideal in terms of ressources needed.

What can be the drawbacks?
If a stream is relaunched with same name, then it would override the existing files, but that an expected use case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant