• Welcome to TechPowerUp Forums, Guest! Please check out our forum guidelines for info related to our community.

ffmpeg live stream recording

Joined
Sep 28, 2020
Messages
77 (0.05/day)
Hello, i am using ffmpeg with a program that records live streams. It works great but there is 1 problem. It records in .mp4 container, which means if the program crashes for whatever reason i am left with unreadable .mp4 file that i dont know what to do, as far as i know i can do nothing. But contrary, .mkv as far as i know records in such a way that even if the program crashes i will have a usable video file. I have 2 questions:

1) Is it possible to somehow recover those .mp4 interrupted files to get the video already recorded or are they lost forever ? Handbrake and similar programs will not do anything since they say its not valid video file.

2) I know programming but i never did anything with ffmpeg, i know nothing about it. Would it be possible to edit this program in such a way that it will record .mkv instead of .mp4 ?


The source code for the program has been released and is available here:

 
Just change ".mp4" to ".mkv" in your ffmpeg command line?
 
With this program im actualy using the programs GUI, im not doing anything with command lines, it would be far to long i guess
 
have you thought about using OBS to live capture the streams?
 
Its to much work. With this program i just click on nickname and it does its magic, i can record 5 at time, it checks whos online, etc. I was just wondering how much work it would be to change .mp4 to .mkv. Though in the meanwhile i did figure out i can actualy save those recordings since i have similarly made good recording. Im using cmd commands, its a hassle and produced some error, would be great if there was a free program with gui that would do this for me. I did notice that sometimes even when stream was no longer online, it was still recording, though didnt use cpu, clearly got bugged but ffmpeg was still running. I guess i should check how to correctly stop it working so it does the meta data correctly. I just pressed ctrl + c or even just killed the process.
 
Back
Top