From e0da59fe5447fbc08041e89081d7587e0a887e1b Mon Sep 17 00:00:00 2001 From: Jody Bruchon Date: Thu, 7 Jan 2021 12:26:50 -0500 Subject: ffmpeg: ignore extra data streams with `-dn` (fixes #2) Sometimes, video files will arrive with a timecode data stream that causes `-map 0` to error out due to the stream not being supported in the output container. These data streams generally do not matter, so tell ffmpeg to ignore them rather than choking on them. --- youtube_dlc/postprocessor/embedthumbnail.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'youtube_dlc/postprocessor/embedthumbnail.py') diff --git a/youtube_dlc/postprocessor/embedthumbnail.py b/youtube_dlc/postprocessor/embedthumbnail.py index 94e3eca98..50678669f 100644 --- a/youtube_dlc/postprocessor/embedthumbnail.py +++ b/youtube_dlc/postprocessor/embedthumbnail.py @@ -96,7 +96,7 @@ class EmbedThumbnailPP(FFmpegPostProcessor): os.rename(encodeFilename(old_thumbnail_filename), encodeFilename(thumbnail_filename)) options = [ - '-c', 'copy', '-map', '0', + '-c', 'copy', '-map', '0', '-dn', '-attach', thumbnail_filename, '-metadata:s:t', 'mimetype=image/jpeg'] self._downloader.to_screen('[ffmpeg] Adding thumbnail to "%s"' % filename) -- cgit v1.2.3