From a75f412b828ac26cb17a1e6d7522df7b6bb480a5 Mon Sep 17 00:00:00 2001 From: Sam <100737234+sam01102@users.noreply.github.com> Date: Wed, 2 Mar 2022 15:42:21 +0800 Subject: [PATCH 1/2] [update] Update 633 link (#1401) --- .github/ISSUE_TEMPLATE/bug-report.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/bug-report.yaml b/.github/ISSUE_TEMPLATE/bug-report.yaml index 1cee16c..9849493 100644 --- a/.github/ISSUE_TEMPLATE/bug-report.yaml +++ b/.github/ISSUE_TEMPLATE/bug-report.yaml @@ -11,7 +11,7 @@ body: ## 感谢您愿意填写错误回报! ## 以下是一些注意事项,请务必阅读让我们能够更容易处理 - ### ❗ | 确定没有相同问题的ISSUE已被提出. (教程: https://github.com/Mrs4s/go-cqhttp/issues/633) + ### ❗ | 确定没有相同问题的ISSUE已被提出. (教程: https://forums.go-cqhttp.org/t/topic/141) ### 🌎| 请准确填写环境信息 ### ❔ | 打开DEBUG模式复现,并提供出现问题前后至少 10 秒的完整日志内容。请自行删除日志内存在的个人信息及敏感内容。 ### ⚠ | 如果涉及内存泄漏/CPU占用异常请打开DEBUG模式并下载pprof性能分析. @@ -24,7 +24,7 @@ body: attributes: label: 请确保您已阅读以上注意事项,并勾选下方的确认框。 options: - - label: "我已经仔细阅读上述教程和 [\"提问前需知\"](https://github.com/Mrs4s/go-cqhttp/issues/633)" + - label: "我已经仔细阅读上述教程和 [\"提问前需知\"](https://forums.go-cqhttp.org/t/topic/141)" required: true - label: "我已经使用 [dev分支版本](https://github.com/Mrs4s/go-cqhttp/actions/workflows/ci.yml) 测试过,问题依旧存在。" required: true From fb33d93b311557d4115e22c216109fcb656d6873 Mon Sep 17 00:00:00 2001 From: ishkong <19740260+ishkong@users.noreply.github.com> Date: Mon, 28 Mar 2022 13:00:29 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=F0=9F=91=BD=EF=B8=8F=20Update=20ffrmpeg=20?= =?UTF-8?q?screenshot=20command?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Ref: https://trac.ffmpeg.org/wiki/Create%20a%20thumbnail%20image%20every%20X%20seconds%20of%20the%20video Force a screenshot of the 0th second of the video --- global/codec.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/global/codec.go b/global/codec.go index 223c533..6a5f088 100644 --- a/global/codec.go +++ b/global/codec.go @@ -43,6 +43,6 @@ func EncodeMP4(src string, dst string) error { // -y 覆盖文件 // ExtractCover 获取给定视频文件的Cover func ExtractCover(src string, target string) error { - cmd := exec.Command("ffmpeg", "-i", src, "-y", "-r", "1", "-f", "image2", target) + cmd := exec.Command("ffmpeg", "-i", src, "-y", "-ss", "0", "-frames:v", "1", target) return errors.Wrap(cmd.Run(), "extract video cover failed") }