mirror of
https://github.com/ytdl-org/youtube-dl
synced 2024-12-22 20:20:09 +09:00
[postprocessor/ffmpeg] Allow options for mp3
Why? Options like `preferredquality` are ignored when postprocessing mp3s. What? Remove `mp3` from the list of `filecodec` values to check for in the "lossless" condition unless `preferredquality` is unspecified.
This commit is contained in:
parent
86e3cf5e58
commit
e8bebe0b03
@ -284,7 +284,10 @@ class FFmpegExtractAudioPP(FFmpegPostProcessor):
|
|||||||
acodec = 'copy'
|
acodec = 'copy'
|
||||||
extension = 'm4a'
|
extension = 'm4a'
|
||||||
more_opts = ['-bsf:a', 'aac_adtstoasc']
|
more_opts = ['-bsf:a', 'aac_adtstoasc']
|
||||||
elif filecodec in ['aac', 'flac', 'mp3', 'vorbis', 'opus']:
|
elif (
|
||||||
|
filecodec in ['aac', 'flac', 'vorbis', 'opus'] or
|
||||||
|
(filecodec == 'mp3' and self._preferredquality is None)
|
||||||
|
):
|
||||||
# Lossless if possible
|
# Lossless if possible
|
||||||
acodec = 'copy'
|
acodec = 'copy'
|
||||||
extension = filecodec
|
extension = filecodec
|
||||||
|
Loading…
Reference in New Issue
Block a user