-
Notifications
You must be signed in to change notification settings - Fork 155
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
Defaults to 360p #184
Comments
Looking into this more, ytdl is taking the top object off of the info.formats array. Which is pretty random. Often times it's the smallest mp4 file, sometimes it's a 'webm' file. I haven't found where this decision is being made in the code yet. But that does seem to be the problem. This video for instance returns webm: https://www.youtube.com/watch?v=ifTZLtJDoaU |
item 0 is almost always itag 18, which is the best format that contains both video and audio for a given youtube link. |
Well, not really. I wrote a function to filter out streams which don't contain both audio and video, then I sorted them based off of width, with widest descending, then returned the itag off the top of the stack. The best quality version of most youtube videos, which have both audio and video, is almost always 720p. Item 0 is usually 360p mp4, and sometimes it's even webm video only (no audio). So, defaulting to item 0 is far from reliable, and it's not necessary, as it's relatively trivial to simply filter and sort for the actual desired default (highest available quality with both audio and video streams). I've thought about making a pull request for my upgrades, and I might if anyone besides me cares about this sort of thing. |
That's surprising but great! Please consider submitting a PR; a higher base resolution, if reliable, would be a great addition. |
ytdl does not default to highest quality, it defaults to 360p, and it doesn't seem to want to take any sort of parameter to tell it to do differently.
It would help if the documentation or the built in help explained how quality is supposed to specified.
Regardless, I have downloaded a number of 1080p and up videos, and they all come out as 360p.
The text was updated successfully, but these errors were encountered: