mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2025-09-03 00:25:08 +00:00
Allow images
formats
Necessary for #343. * They are identified by `vcodec=acodec='none'` * These formats show as the worst in `-F` * Any postprocessor that expects audio/video will be skipped * `b*` and all related selectors will skip such formats * This commit also does not add any selector for downloading such formats. They have to be explicitly requested by the `format_id`. Implementation of a selector is left for when #389 is resolved
This commit is contained in:
@ -16,6 +16,7 @@ try:
|
||||
except ImportError:
|
||||
has_mutagen = False
|
||||
|
||||
from .common import PostProcessor
|
||||
from .ffmpeg import (
|
||||
FFmpegPostProcessor,
|
||||
FFmpegThumbnailsConvertorPP,
|
||||
@ -62,6 +63,7 @@ class EmbedThumbnailPP(FFmpegPostProcessor):
|
||||
def _report_run(self, exe, filename):
|
||||
self.to_screen('%s: Adding thumbnail to "%s"' % (exe, filename))
|
||||
|
||||
@PostProcessor._restrict_to(images=False)
|
||||
def run(self, info):
|
||||
filename = info['filepath']
|
||||
temp_filename = prepend_extension(filename, 'temp')
|
||||
|
Reference in New Issue
Block a user