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

Denis Ivanov denisx.ivanov at gmail.com
Tue Aug 23 23:16:29 EEST 2022


Yes, use fragmented MP4. That way you will eventually lose small part of
the video at the end.

On Tue, Aug 23, 2022, 23:11 Ben Harper <rogojin at gmail.com> wrote:

> 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
> _______________________________________________
> Libav-user mailing list
> Libav-user at ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/libav-user
>
> To unsubscribe, visit link above, or email
> libav-user-request at ffmpeg.org with subject "unsubscribe".
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://ffmpeg.org/pipermail/libav-user/attachments/20220823/59f09cb2/attachment.htm>


More information about the Libav-user mailing list