Como usar a lista de arquivos Concat com o complexo de filtros

0

Na minha página, estou usando o ffmpeg para criar vídeos a partir de um arquivo de texto dinâmico que contém uma lista de caminhos para minhas imagens.

    ffmpeg concat version 1.0
    file 'path/to/file1.jpg'
    file 'path/to/file2.jpg'
    file 'path/to/file3.jpg'
    file 'path/to/file4.jpg'
    etc.

Agora estou tentando usar GL Transitions com o FFMPEG. Eu já instalei FFMPEG-GL-TRANSITIONS e estou tentando usá-lo com o ffmpeg assim -

ffmpeg -safe 0 -f concat -i paths.txt -c:v libx264 \
-vf "scale=1280:720:force_original_aspect_ratio=decrease,pad=1280:720:(ow-iw)/2:(oh-ih)/2,gltransition" \
-vsync vfr -pix_fmt yuv420p -movflags +faststart -y output.mp4 2>&1

Mas isso me dá os seguintes erros -

Simple filtergraph 'scale=1280:720:force_original_aspect_ratio=decrease,pad=1280:720:(ow-iw)/2:(oh-ih)/2,gltransition' was expected to have exactly 1 input and 1 output. However, it had >1 input(s) and 1 output(s). Please adjust, or use a complex filtergraph (-filter_complex) instead.
Error reinitializing filters!
Failed to inject frame into filter network: Invalid argument
Error while processing the decoded data for stream #0:0
Conversion failed!

Se eu usar o seguinte comando -

ffmpeg -safe 0 -f concat -i paths.txt -c:v libx264 \
-vf "scale=1280:720:force_original_aspect_ratio=decrease,pad=1280:720:(ow-iw)/2:(oh-ih)/2" -filter_complex gltransition -vsync vfr -pix_fmt yuv420p -movflags +faststart -y output.mp4 2>&1

Eu recebo este erro -

    Input #0, concat, from '/paths.txt': Duration: N/A, start: 0.000000,
 bitrate: N/A Stream #0:0: Video: mjpeg, yuvj420p(pc, bt470bg/unknown/unknown),
 432x768 [SAR 1:1 DAR 9:16], 25 tbr, 25 tbn, 25 tbc Cannot find a matching 
stream for unlabeled input pad 1 on filter Parsed_gltransition_0

Eu também tentei remover -vf do comando e recebi o mesmo erro -

ffmpeg -safe 0 -f concat -i paths.txt -c:v libx264 \
-filter_complex gltransition -vsync vfr -pix_fmt yuv420p -movflags +faststart -y output.mp4 2>&1

Meus arquivos são dinâmicos e podem ter até 40 deles, portanto não posso usar o outro método de concat. Alguma idéia de como fazer isso funcionar? Obrigado.

    
por Rich 06.07.2018 / 20:15

0 respostas

Tags