将带有Alpha的.mov转换为带有ffmpeg的alpha的.webm时出现错误"使用auto_alt_ref进行透明度编码不起作用"

Tho*_*TTP 13 video alpha ffmpeg mov webm

我试图将带有alpha透明度的.mov文件转换为.webm文件,并一直在关注此主题寻求帮助:将带有Alpha的mov转换为带有Alpha的VP9 Webm使用ffmpeg

我一直在使用的命令行是

ffmpeg -r 24/1 -i Desktop/Skel_Walk_1.mov -c:v libvpx -pix_fmt yuva420p Desktop/Skel_Walk_1.webm
Run Code Online (Sandbox Code Playgroud)

但是,当我去运行命令时,它会出现2个错误

Transparency encoding with auto_alt_ref does not work
Run Code Online (Sandbox Code Playgroud)

Error initializing output stream 0:0 -- Error while opening encoder for output stream #0:0 
- maybe incorrect parameters such as bit_rate, rate, width or height
Run Code Online (Sandbox Code Playgroud)

我不太清楚这里的问题是什么,有什么建议,我很困惑!

Tho*_*TTP 29

我想我可能已经解决了这个问题,-auto-alt-ref 0在输出修复此问题之前添加!!

工作指挥

ffmpeg -i Desktop/Skel_Walk_1.mov -c:v libvpx -pix_fmt yuva420p -auto-alt-ref 0 Desktop/Skel_Walk_1.webm
Run Code Online (Sandbox Code Playgroud)

  • @AugustBjornberg 在命令中使用“libvpx-vp9”而不是“libvpx”。这将保留阿尔法 (3认同)