Opened 3 years ago

Last modified 3 years ago

#5945 open defect

Lavfi & filter_complex ignore fps filter

Reported by: LordHDL Owned by:
Priority: minor Component: documentation
Version: git-master Keywords: overlay
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

Summary: When using the fps filter with -lavfi or -filter_complex it will be ignored and use the default 25 FPS for the output video.
How to reproduce: Specify fps for a video stream.

ffmpeg -loop 1 -i ~/Desktop/FP2.tiff -i ~/Desktop/fp.mov -lavfi \
"[1:v]fps=60[video]; \
 [0:v][video]overlay=50:200:shortest=1[final]" \
-map "[final]" -map 1:a -c:v ffv1 -level 3 -c:a copy ~/Desktop/filtergraph.nut

Attachments (1)

filtergraph (8.6 KB) - added by LordHDL 3 years ago.

Download all attachments as: .zip

Change History (5)

Changed 3 years ago by LordHDL

comment:1 Changed 3 years ago by Cigaes

You are changing the framerate on the secondary input of the overlay filter. This is useless, overlay syncs on its primary input by default, the framerate of the secondary input is not used. What you observe seems the correct behaviour.

Also, full console output missing.

comment:2 Changed 3 years ago by LordHDL

Full console output is in the file I had attached.

The following command worked for me:

ffmpeg -y -loop 1 -i ~/Desktop/FP2.tiff -i ~/Desktop/fp.mov -i ~/Desktop/fp.mov -lavfi \
"[0:v]fps=60[bg]; \
[bg][1:v]overlay=10:(main_h/2)-(overlay_h/2):format=rgb[v1]; \
[v1][2:v]overlay=460:(main_h/2)-(overlay_h/2):shortest=1:format=rgb[final]" \
-map "[final]" -map 1:a -map 2:a -c:v ffv1 -level 3 -c:a copy ~/Desktop/filtergraph.nut

This method seems to set the frame rate for everything as a whole. Is there any way to control each video overlay's frame rate individually without reencoding them first?

comment:3 Changed 3 years ago by LordHDL

Post duplicated.

Last edited 3 years ago by LordHDL (previous) (diff)

comment:4 Changed 3 years ago by cehoyos

  • Component changed from avfilter to documentation
  • Keywords overlay added
  • Priority changed from normal to minor
  • Status changed from new to open

The ticket indicates that the sentence The first input is the "main" video on which the second input is overlaid. in the documentation can be improved.

Note: See TracTickets for help on using tickets.