Files
linux-wiki/content/deepin折腾笔记/第六章/6.10.md
2021-10-21 14:57:58 +08:00

18 lines
1.2 KiB
Markdown
Executable File
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# 6.10 Blender 视频剪辑多核渲染崩溃处置
Blender视频剪辑多核渲染崩溃的解决方案可以尝试取消Mixsound Sound选项也可以使用脚本手动连接与合并。
方法一直接将包含音频的视频连接详见群文件concat_contails_audio.sh内容如下
#!/bin/bash
for file in `find . -type f -a -name '*-*.mp4'`
do
buf=$buf"file '${file:2}'\n"
done
echo -e $buf |sed "/^$/d" |sort -t "-" -k 2n > in.txt
ffmpeg -f concat -i in.txt -c copy out.mp4
方法二:
先从Blender里渲染音频例如in.mp3如果是其它格式音频需要修改脚本它的原理是先连接视频(丢弃音频),然后再把单独渲染的音频与之合并。
将方法一脚本的最后一条命令替换成:
ffmpeg -f concat -i in.txt -c:v copy -an in.mp4
ffmpeg -i in.mp4 -i in.mp3 -c:v copy -c:a copy out.mp4
rm in.mp4
详见群文件concat_merge_audio.sh。