[FFmpeg-user] How do I decode once and pass frames to multiple destinations

Michael Koch astroelectronic at t-online.de
Thu Dec 3 13:02:06 EET 2020


Am 03.12.2020 um 11:57 schrieb Simon Brown:
> I have used ffmpeg for a number of different things, including decoding
> streams, transcoding format, encoding streams, etc.  It's a wonderful
> tool.  Now I want to design something that can do three things at the same
> time, eg
> a) display a stream on a monitor,
> b) send the raw video out on a different medium and
> c) scale and re-encode that video to restream out of the unit.
>
> I can do all 3 of these things individually, and therefore I can do all 3
> of these things by running 3 instances of ffmpeg, but at that point my
> system is decoding the stream 3 times and I really don't want to spend the
> CPU power doing that.
>
> So is it possible to just decode the stream once, and then send it to HDMI,
> scaler, etc. ?

this wiki page might help:
https://trac.ffmpeg.org/wiki/Creating%20multiple%20outputs

Michael



More information about the ffmpeg-user mailing list