-
Notifications
You must be signed in to change notification settings - Fork 411
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Download music without any conversion #570
Comments
Seems you can now choose to download opus files in 1.15, which should mean no conversion? |
I could be wrong here, I don't really know how to code that much, but reading the downloader plugin's util.js, looks like it just parses arguments to FFmpeg: // Presets for FFmpeg
module.exports.presets = {
"None (defaults to mp3)": undefined,
opus: {
extension: "opus",
ffmpegArgs: ["-acodec", "libopus"],
},
}; |
That is correct, libopus is the default encoding format that googlevideo uses, main fallback being aac. |
Hey guys, so it seems the opus preset solves this issue and we can close it? |
Not really. The problem with the preset is that it stills converts the audio. The program downloads the opus file from YouTube, and then it converts it to opus again locally with ffmpeg. To solve this, the ffmpeg conversion step should be skipped completely. There's another way too, to check if the source file is an opus stream, and parse arguments to ffmpeg to just copy the audio to another opus container, instead of converting. But the only reason to do this is if the conversion step is totally necessary to the way the plugin is written. The check is necessary because YouTube Music offers audio in m4a/aac with a higher quality than opus too. So a possible m4a profile would need this check too. |
Download defaults to 128kb for me. I have Youtube Premium and quality set to highest. I'd like 320kb minimum ideally. |
in #1054 opus isn't "re-converted" |
Looks like the download plugin downloads the highest bitrate audio it can find with youtube-dl and converts it to mp3 or opus with FFmpeg based on your settings, right?
So, this makes sense for mp3, but YouTube uses opus and aac, and they are lossy formats. Converting lossy to lossy is a bad practice, you are reducing the file quality 2 times (YouTube converts the upload on their side, and FFmpeg converts it again), 3 times if the uploader sent a lossy audio too. And there's no reason to convert to a format that YouTube already provides.
So, I wanted to ask for a change on this plugin: to make it download the highest bitrate opus file available and skip the conversion, preserving the original file. Then add an option to make the same thing with aac files.
The text was updated successfully, but these errors were encountered: