I want to show a logoon a video when the video starts. I already found this command :
ffmpeg -i input.mp4 -framerate 30000/1001 \
-loop 1 -i test.png -filter_complex "[1:v] fade=out:st=30:d=1:alpha=1 [ov];\
[0:v][ov] overlay=10:10 [v]" -map "[v]" -map 0:a -c:v libx264 \
-c:a copy -shortest Bigout.mp4
from How to add my logo for the first 30 seconds in a video with ffmpeg?
But the problem is my video's widths/heights are different and each time I add a logo, it does not cover the whole video. What should I do if I want to set the logo width/height to the width/height of the video ?
UPDATE After @Behroozfar Answer, I tried to use scale2ref, with the command below:
ffmpeg -i input.mp4 -framerate 30000/1001 -loop 1 -i biglogo.png -filter_complex "[1:v][0:v]scale2ref=iw/1:-1[ovrl][0v]; [0v][ovrl]overlay=0:0[v]" -map "[v] ; [1:v] fade=out:st=2:d=1:alpha=1 [ov]" -map 0:a -c:v libx264 -c:a copy -shortest Bigout.mp4
but the question is , I can't show the logo just for one second. It exists during the whole video play.