]> jfr.im git - yt-dlp.git/commitdiff
[FFmpegVideoConvertor] Add `gif` to `--recode-video`
authorpukkandan <redacted>
Mon, 19 Dec 2022 19:11:45 +0000 (00:41 +0530)
committerpukkandan <redacted>
Thu, 22 Dec 2022 20:14:20 +0000 (01:44 +0530)
README.md
yt_dlp/postprocessor/ffmpeg.py

index c0a2a420bcc2b896867e43ccf3f79afd342acdbe..440ed1934838bac8cac5368f5a22e5135acca001 100644 (file)
--- a/README.md
+++ b/README.md
@@ -893,11 +893,11 @@ ## Post-Processing Options:
                                     specific bitrate like 128K (default 5)
     --remux-video FORMAT            Remux the video into another container if
                                     necessary (currently supported: avi, flv,
-                                    mkv, mov, mp4, webm, aac, aiff, alac, flac,
-                                    m4a, mka, mp3, ogg, opus, vorbis, wav). If
-                                    target container does not support the
-                                    video/audio codec, remuxing will fail. You
-                                    can specify multiple rules; e.g.
+                                    gif, mkv, mov, mp4, webm, aac, aiff, alac,
+                                    flac, m4a, mka, mp3, ogg, opus, vorbis,
+                                    wav). If target container does not support
+                                    the video/audio codec, remuxing will fail.
+                                    You can specify multiple rules; e.g.
                                     "aac>m4a/mov>mp4/mkv" will remux aac to m4a,
                                     mov to mp4 and anything else to mkv
     --recode-video FORMAT           Re-encode the video into another format if
index 67890fc31093ba5b808672ea5b57bb99f75e72c4..069066e0c619ae926bc48fdc2aa1e887302fd1f2 100644 (file)
@@ -538,7 +538,10 @@ def run(self, information):
 
 
 class FFmpegVideoConvertorPP(FFmpegPostProcessor):
-    SUPPORTED_EXTS = (*MEDIA_EXTENSIONS.common_video, *sorted(MEDIA_EXTENSIONS.common_audio + ('aac', 'vorbis')))
+    SUPPORTED_EXTS = (
+        *sorted((*MEDIA_EXTENSIONS.common_video, 'gif')),
+        *sorted((*MEDIA_EXTENSIONS.common_audio, 'aac', 'vorbis')),
+    )
     FORMAT_RE = create_mapping_re(SUPPORTED_EXTS)
     _ACTION = 'converting'