[FFmpeg-devel] pipeline multithreading

Daniel Oberhoff danieloberhoff at gmail.com
Tue Nov 25 10:01:43 CET 2014

Von meinem iPhone gesendet

> Am 24.11.2014 um 17:16 schrieb Reimar Döffinger <Reimar.Doeffinger at gmx.de>:
>> On Mon, Nov 24, 2014 at 12:35:58PM +0100, Daniel Oberhoff wrote:
>> inout -> filter1 -> filter2 -> output
>> some threads processing frame n in the output (i.e. encoding), other threads procesing frame n+1 in filter2, others processing frame n+2 in filter1, and yet others processing frame n+3 decoding. This way non-parallel filters can be sped up, and diminishing returns for too much striping can be avoided. With modern cpus scaling easily up to 24 hardware threads I see this as neccessary to fully utilize the hardware.
> Keep in mind the two things:
> 1) It only works for cases where many filters are used, which is not
> necessarily a common case

Also, not quite. Even just decode/encode had a pipeline depth of 2 (the decoder could decode frame n+1 while the encoder encodes frame n). Every filter deepens this more...

More information about the ffmpeg-devel mailing list