[Libav-user] How to build video files that are valid if machine loses power before writing trailer

Ben Harper rogojin at gmail.com
Tue Aug 23 23:11:23 EEST 2022


Hi!

I'm building an open source home video monitoring system, and naturally
this needs to be able to make long recordings from the cameras, and store
them as video files. Right now I'm only supporting h264, and writing into
an MP4 file. This works perfectly, aside from the fact that if the
monitoring system loses power during recording, such that I haven't called
av_write_trailer yet, then the video file is unplayable.

Is there a way to stream to a video file such that most of it will be
playable, even if the system loses power?

Thanks,
Ben
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://ffmpeg.org/pipermail/libav-user/attachments/20220823/14c0d480/attachment.htm>


More information about the Libav-user mailing list