[pp/EmbedThumbnail] Support `m4v` (#7583)

Authored by: Neurognostic
pull/7586/head
Neurognostic 1 year ago committed by GitHub
parent 2cfe221fbb
commit 8a4cd12c8f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -114,7 +114,7 @@ class EmbedThumbnailPP(FFmpegPostProcessor):
self._report_run('ffmpeg', filename) self._report_run('ffmpeg', filename)
self.run_ffmpeg(filename, temp_filename, options) self.run_ffmpeg(filename, temp_filename, options)
elif info['ext'] in ['m4a', 'mp4', 'mov']: elif info['ext'] in ['m4a', 'mp4', 'm4v', 'mov']:
prefer_atomicparsley = 'embed-thumbnail-atomicparsley' in self.get_param('compat_opts', []) prefer_atomicparsley = 'embed-thumbnail-atomicparsley' in self.get_param('compat_opts', [])
# Method 1: Use mutagen # Method 1: Use mutagen
if not mutagen or prefer_atomicparsley: if not mutagen or prefer_atomicparsley:
@ -213,7 +213,7 @@ class EmbedThumbnailPP(FFmpegPostProcessor):
temp_filename = filename temp_filename = filename
else: else:
raise EmbedThumbnailPPError('Supported filetypes for thumbnail embedding are: mp3, mkv/mka, ogg/opus/flac, m4a/mp4/mov') raise EmbedThumbnailPPError('Supported filetypes for thumbnail embedding are: mp3, mkv/mka, ogg/opus/flac, m4a/mp4/m4v/mov')
if success and temp_filename != filename: if success and temp_filename != filename:
os.replace(temp_filename, filename) os.replace(temp_filename, filename)

Loading…
Cancel
Save