“过滤器体积具有未连接的输出” FFMPEG

发布于 2025-01-13 21:09:38 字数 734 浏览 4 评论 0原文

我看过有关此问题的其他帖子,但似乎没有一个标志适用于我的。这是 bash 脚本的一部分,用于运行命令并在出现错误(例如断开连接时)时重新运行脚本。

cmd="ffmpeg \
    -stream_loop -1 -re -thread_queue_size 256 -i "$VIDEO" \
    -stream_loop -1 -re -thread_queue_size 256 -i "$AUDIO" \
    -re -thread_queue_size 256 -i "$AUDIO" \
    -filter_complex \
    "[1:a]volume=0.0[a1]; \
    [aout]" -map 0:v:0 -map "[aout]" \
    -vcodec libx264 -pix_fmt yuv420p -preset $QUAL -r $FPS -g $(($FPS * 2)) -b:>
    -acodec aac -ac 2 -ar 44100 -threads 0 -b:a $AB \
    -f flv -rtmp_live live $URL/$KEY"

until $cmd ; do
        echo "restarting ffmpeg command..."
        sleep 2
done

然后当我运行 bash 脚本时出现错误,它会不断重新启动

Filter volume has an unconnected output

I've looked at other posts about this but none of the flags seem to work with mine. Here is part of the bash script that runs the command and re-runs the script when there's an error, like when it disconnects.

cmd="ffmpeg \
    -stream_loop -1 -re -thread_queue_size 256 -i "$VIDEO" \
    -stream_loop -1 -re -thread_queue_size 256 -i "$AUDIO" \
    -re -thread_queue_size 256 -i "$AUDIO" \
    -filter_complex \
    "[1:a]volume=0.0[a1]; \
    [aout]" -map 0:v:0 -map "[aout]" \
    -vcodec libx264 -pix_fmt yuv420p -preset $QUAL -r $FPS -g $(($FPS * 2)) -b:>
    -acodec aac -ac 2 -ar 44100 -threads 0 -b:a $AB \
    -f flv -rtmp_live live $URL/$KEY"

until $cmd ; do
        echo "restarting ffmpeg command..."
        sleep 2
done

Then it keeps restarting when I run the bash script with the error

Filter volume has an unconnected output

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文