Referencing previous steps in custom FFMpeg instructions

Regarding this Twitter thread:

I would like to know if it is possible to pass previous completed steps into a custom FFMpeg command. My particular use case is in regards to my Turn web app. Currently I use Transloadit to clean up the uploads before I send them over to a custom FFMpeg serverless function I put together to do the final assembly. I was wondering if I could bring this function into FFMpeg but when I originally brought this up in 2018 by support, it did not seem possible.

The function would take two image inputs. One for the rotating disc and another for the background it sits upon. Here’s a simple version of the ‘filter_complex’ command:


In my mind, ‘disc’ and ‘background’ would be referencing previous steps somehow so I can prepare that content accordingly. This is just a dream but I would love to hear your feedback.

Hello Lee,

Sorry about the lengthy response time. When I first saw your tweet, I figured we could accommodate your use case because we have demos that use filter_complex statements. However, this is proving to be more complex than I first anticipated.

I do have an idea I have been playing around with to get this working using our watermark feature, but I’m yet to get it entirely working. The general idea is:

  • Watermark the image of the disk on top of a background to generate a single complete image.
  • Generate several rotated versions of this complete image using our rotate parameter.
  • Then create a video from the sequence of rotated images.

Thank you for patiently waiting, I’ll be sure to follow up to let you know how my investigation has gone.