I'm trying to do some analysis of image-based subtitles by outputting them as a sequence of PNGs to a pipe. My command line looks like this:
ffmpeg -y -i $INPUTFILE -f lavfi -i color=c=black:s=1920x1080 -filter_complex "[1:v][0:s:5]overlay[v]" -shortest -map "[v]" -c:v png -f image2pipe - | pike subspng.pike
In theory, -shortest should mean that the stream stops at the shortest input, which would be roughly seven minutes of input file. Instead, my script receives an infinite sequence of black frames after the last frame of subtitles, until I send FFMPEG a SIGINT. Placing -shortest before -filter_complex has the same effect.
Is there a different way to force the filtering to stop at the end of the input file?
EDIT: Using the shortest=1 flag on the overlay filter also doesn't help, even in combination with -shortest.