aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex <alexta69@gmail.com>2022-12-24 08:43:00 +0200
committerGitHub <noreply@github.com>2022-12-24 08:43:00 +0200
commita0fcef8dbc8b05f060aacab7d320788b12ade0c4 (patch)
tree1ba98eaec25ae4334c1ff877ff772b4558cd56c1
parentupgrade dependencies; add troubleshooting section to README (diff)
parentconvert thumbnail to jpg before embed #188 (diff)
downloadmetube-a0fcef8dbc8b05f060aacab7d320788b12ade0c4.tar.gz
metube-a0fcef8dbc8b05f060aacab7d320788b12ade0c4.tar.bz2
metube-a0fcef8dbc8b05f060aacab7d320788b12ade0c4.zip
Merge pull request #207 from PikuZheng/patch-1
convert thumbnail to jpg before embed #188
-rw-r--r--app/dl_formats.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/app/dl_formats.py b/app/dl_formats.py
index 316d5df..5936b35 100644
--- a/app/dl_formats.py
+++ b/app/dl_formats.py
@@ -67,6 +67,7 @@ def get_opts(format: str, quality: str, ytdl_opts: dict) -> dict:
"preferredquality": 0 if quality == "best" else quality,
})
opts["writethumbnail"] = True
+ opts["postprocessors"].append({"key": "FFmpegThumbnailsConvertor", "format": "jpg", "when": "before_dl"})
opts["postprocessors"].append({"key": "FFmpegMetadata"})
opts["postprocessors"].append({"key": "EmbedThumbnail"})
bgstack15