簡體   English   中英

ffmpeg PNG-MP4-打開輸入文件時出錯:無效的參數

[英]ffmpeg PNG - MP4 - Error opening input files: invalid argument

我將跟隨這個可視化項目一起在MP4中轉換PNG文件。

該示例代碼的唯一變化是我的時間戳以1開始。

ffmpeg -r 20 -b 20M -i example%01d.png output.mp4

這就是回報

ffmpeg version N-53055-g7b43120 Copyright (c) 2000-2013 the FFmpeg developers
built on May 14 2013 20:43:53 with llvm-gcc 4.2.1 (LLVM build 2336.11.00)
configuration: --disable-yasm
libavutil      52. 31.100 / 52. 31.100
libavcodec     55.  9.100 / 55.  9.100
libavformat    55.  7.100 / 55.  7.100
libavdevice    55.  0.100 / 55.  0.100
libavfilter     3. 67.100 /  3. 67.100
libswscale      2.  3.100 /  2.  3.100
libswresample   0. 17.102 /  0. 17.102
**Option b (video bitrate (please use -b:v)) cannot be applied to input file
example%01d.png -- you are trying to apply an input option to an output file or
vice versa. Move this option before the file it belongs to.
Error parsing options for input file example%01d.png.
Error opening input files: Invalid argument**

如果查看終端輸出,則表明FFmpeg參數錯誤,因為您將錯誤的參數傳遞給輸入文件。 由於要使用該比特率進行編碼,因此必須將bitrate參數應用於輸出文件。 將其移到正確的位置即可解決問題。

我測試了一下,這有效:

ffmpeg -r 20 -i example%01d.png -b:v 20M output.mp4

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM