Auto insert fps filter as adapter for overlay filter inputs with different framerates
|Reported by:||annorax||Owned by:|
|Version:||git-master||Keywords:||fps overlay filter|
|Blocking:||Reproduced by developer:||no|
|Analyzed by developer:||no|
Now that the fps filter has been added (you're my heroes for adding it), it would be great if an fps filter would be auto-inserted before the overlay filter, where framerate conversion is required if the framerates of the two input vary (the way a scale filter is often auto-inserted wherever it's required).
To do this, whenever an overlay filter is used in a filter chain, the framerate of each of its inputs should be detected (using the same function used by ffprobe to populate the avg_frame_rate property), then insert an fps filter to upsample the input with the lower framerate to match the framerate of the other one.
Currently I do this manually: run ffprobe on each video file before performing an overlay, then insert an fps filter between the lower-fps file and the overlay filter. This means 3 procedure calls. It would be great if it could all be done in 1.