[FFmpeg-devel] Filter with external image manupilation?

Moritz Barsnick barsnick at gmx.net
Wed Jul 5 12:08:43 EEST 2017


On Wed, Jul 05, 2017 at 10:41:49 +0200, Evert Vorster wrote:
> Hi there, developers on this list.

This is more of a question for ffmpeg-user, actually.

> Is it possible to pause decoding and encoding of a file with a script?

You can suspend ffmpeg with a signal. But that won't be very precise in
terms of timing.

> During the pause between the frames, we want to manipulate the extracted
> frame. This is done with other tools in a script. The manipulations is with
> a hugin template, Panotool's nona and enblend, so it's a little outside of
> what ffmpeg filters can do. (I think?)

I guess there's no such filter (yet).

> The ultimate aim of this is to avoid eating many gigabytes of disk space by
> completely expanding a input video into lossless frames.

I suggest to extract the frames to stdout using the image2pipe format,
and pipe that output to a wrapper script which (somehow) detects a
completed frame and passes it on to your processing chain. If you block
the output pipe once a complete frame has been received, ffmpeg should
pause processing; once you continue to pull data from the pipe, ffmpeg
will continue to process.

I just quickly checked by piping ffmpeg's image2pipe format to "less",
and it seems that ffmpeg only continued to process when I allowed
"less" to read more input.

Try if that works for you. The wrapper may not be trivial though.

Cheers,
Moritz


More information about the ffmpeg-devel mailing list