[FFmpeg-user] Hardening ffmpeg stream download?
Carl Zwanzig
cpz at tuunq.com
Thu Jun 9 22:00:39 EEST 2022
On 6/9/2022 10:25 AM, Bo Berglund wrote:
> Is there some way to let ffmpeg write the mpeg or ts stream to disk and then
> immediately feed it to itself as an input to create the mp4?
The "keep it simple" principle applies-
Unless disk space is a big issue and you need the output immediately after
recording, use a temp file for this and convert after the download*
completes (as driven by your script). It'll be much easier all around and
more tolerant of errors. If you choose to re-encode while downloading, you
can run into the problem that the re-encoder catches up to the download and
ends (the circular buffer problem).
*if saving in the downloaded codec, there's no added conversion overhead or
quality loss.
Later,
z!
More information about the ffmpeg-user
mailing list