]> git.bitcoin.ninja Git - youtube-dl/commitdiff
[ffmpeg] Fix embedding subtitles (#9063)
authorWang Jun Tham <bouncerox@gmail.com>
Sat, 23 Apr 2016 16:08:02 +0000 (00:08 +0800)
committerWang Jun Tham <bouncerox@gmail.com>
Sat, 23 Apr 2016 16:08:02 +0000 (00:08 +0800)
Changed command line parameters for ffmpeg when embedding subtitles.
Changed to ‘-map 0:v -c:v copy -map 0:a -c:a copy’

youtube_dl/postprocessor/ffmpeg.py

index 1793a878cb57b60ab7e59cb55f17eb4127c32f92..ca2d401f87e2594bce5b18c1be18491ce0815fd5 100644 (file)
@@ -363,8 +363,10 @@ class FFmpegEmbedSubtitlePP(FFmpegPostProcessor):
         input_files = [filename] + sub_filenames
 
         opts = [
-            '-map', '0',
-            '-c', 'copy',
+            '-map', '0:v',
+            '-c:v', 'copy',
+            '-map', '0:a',
+            '-c:a', 'copy',
             # Don't copy the existing subtitles, we may be running the
             # postprocessor a second time
             '-map', '-0:s',