-
Notifications
You must be signed in to change notification settings - Fork 887
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
Filter out WebM DASH formats #3105
Filter out WebM DASH formats #3105
Conversation
That was very interesting. Also, very concise. |
"I'm also considering adding an option to filter out unwanted formats from the DASH manifest and download function, which is why this is a WIP." |
I considered opening a feature request for it but then realised that it's probably a pretty niche to us thing, so I just implemented it in FreeTube, however if he thinks it's going to be useful enough, then we can definitely use it. We'll just have to hope that the filtering for the toDash function gives us a lot more control than the filtering/options that the download function uses. It's probably fine for most users of the library, that just want to download the highest quality stream without touching the formats, but we want want fine grained control. Even with the filtering in the toDash function, we'll still need to do our own filtering, as our quality selector needs the list of adaptive formats, it'll just mean that we won't need line 620 in the Watch.js file. |
This pull request has conflicts, please resolve those before we can evaluate the pull request. |
75b9db1
to
2780633
Compare
Conflicts have been resolved. A maintainer will review the pull request shortly. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
Pull request was closed
* Filter out WebM DASH formats * Address pull request feedback
Filter out WebM DASH formats
Pull Request Type
Description
video.js only supports MP4 DASH, so when the player catches wind of the WebM DASH formats it breaks down. This pull request filters out the WebM DASH formats. It also adds a setting to choose between using the MP4 AV1 formats if they are available or always use the MP4 H.264 formats.
Only allowing the quality selector to see the MP4 H.264 formats, seems to make it work sometimes, unfortunately switching between qualities with AV1 formats is still broken.
AV1 formats retain more quality than H.264 formats, so they are definitely preferred, unfortunately they are also more demanding on your hardware, especially if you don't have dedicated hardware AV1 decoders.
This also fixes the duplicate qualities in the selector in almost all situations, HDR qualities still show two, they seem identical except the itag and almost double as high bitrate on one format compared to the other. My guess is that they might be different HDR implementations or maybe one is SDR and the other is HDR but they are both labelled as HDR.
LTT video about AV1: https://www.youtube.com/watch?v=WVjtK71qqXU
Tom Scott video about why YouTube's compression can't cope with snow and confetti (even though it's a 6 year old video it has AV1 formats, I wonder if YouTube used it for testing purposes): https://youtu.be/r6Rp-uo6HmI
Testing
Animals https://youtu.be/Ac07Qt84WDw
Confetti https://youtu.be/4JLLokZWDqE (this looks a lot better with AV1 compared to H264)
Desktop