필터 Boxblur에 연결되지 않은 출력이 있습니다.

필터 Boxblur에 연결되지 않은 출력이 있습니다.

2~10초 동안 이 부분을 흐리게 하고 12~20초 동안 다른 부분을 흐리게 하는 등 특정 간격에 따라 비디오의 특정 부분을 흐리게 하려고 하는데 이 작업을 수행할 수 없습니다. 지금까지 할 수 있는 명령은 다음과 같습니다.

'ffmpeg -y -i with_out_sound.mp4 -filter_complex [0:v]crop=206:169:32:121,boxblur=10:enable='between(t,2,10)'[fg];[0:v]crop=206:169:62:100,boxblur=10:enable='between(t,12,20)'[fg1];[0:v[fg]overlay=32:121:enable='between(t,2,10)'[tmp];[0:v][tmp]overlay=62:100:enable='between(t,12,20)'[tmp2]-map [tmp2] with_blur.mp4'

하지만 위의 명령을 사용하면 오류가 발생합니다.필터 Boxblur에 연결되지 않은 출력이 있습니다.

답변1

사용

ffmpeg -y -i with_out_sound.mp4 -filter_complex \
"[0:v]crop=206:169:32:121,boxblur=10:enable='between(t,2,10)'[fg]; \
 [0:v]crop=206:169:62:100,boxblur=10:enable='between(t,12,20)'[fg1]; \
 [0:v[fg]overlay=32:121:enable='between(t,2,10)'[tmp]; \
 [tmp][fg1]overlay=62:100:enable='between(t,12,20)'[tmp2]"
-map [tmp2] with_blur.mp4

첫 번째 오버레이의 결과는 두 번째 오버레이의 배경이 되어야 합니다.

fg1어디에서도 사용되지 않았기 때문에 오류가 발생했습니다 . 모든 필터 출력은 1) 인코딩을 위해 매핑되거나, 2) 다른 필터에서 사용되거나, 3) 싱크로 전송되어야 합니다.

관련 정보