Thanks for some more insights!
Sorry i forgot to welcome you! - WELCOME to the forum and thank you for using ffastrans.
So if i understand correct, you want to output a HLS live stream from the recorded chunks, is that correct?
Basically, ffastrans cannot really help you here a lot as we concentrate on non-live stuff. - I see no chance for a feature request here as the base of ffastrans does not support any live stuff.
Lucky you, i was working on that topic already for some weeks, so here is some of my knowledge:
The only way that i am aware of dynamically adding input files to a single running instance of ffmpeg is to feed a m3u8 playlist.
Try it out, create a text file like this (C:\temp\mxf.m3u8 ):
Code: Select all
#EXTM3U
#EXT-X-VERSION:3
#EXT-X-MEDIA-SEQUENCE:0
#EXTINF:30,
c:\temp\1.mxf
Then start an ffmpeg instance, e.g.
Code: Select all
ffmpeg -allowed_extensions ALL -i C:\temp\mxf.m3u8 -c:v libx264 -crf 21 -preset veryfast -c:a aac -b:a 128k -ac 2 -f hls -hls_playlist_type event -hls_list_size 6 -hls_flags delete_segments c:\temp\LIVE\stream.m3u8
Then, at the end of your mxf.m3u8, append the next mxf segment,
Your mxf.m3u8 now looks like this:
Code: Select all
#EXTM3U
#EXT-X-VERSION:3
#EXT-X-MEDIA-SEQUENCE:0
#EXTINF:30,
c:\temp\1.mxf
#EXTINF:30,
c:\temp\2.mxf
You will notice, that the encoding ffmpeg instance picks up the new file and continues transcoding the live stream.
Using ffastrans, you could watch for new *.mxf chunks and append each found chunk to the mxf.m3u8 playlist using the text processor
Anyway, i never got it working this way, it is just too much effort to solve all problems, e.g. your audio WILL get async, you need to take care about missing or defect clips from the recording systems and much more.
If this is a commercial project, it will be best for you to search for ready to use solutions that you can buy instead of investing months and years on your own, this way the time to market is shorter and the final result is much more stable. E.g. did you talk to the guys from wowza?