-
-
Notifications
You must be signed in to change notification settings - Fork 483
feat(Player): automatically select best buffer duration #7358
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
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -158,8 +158,6 @@ | |
<string name="show_updates">Check updates automatically</string> | ||
<string name="related_streams">Related content</string> | ||
<string name="related_streams_summary">Show similar streams alongside what you watch</string> | ||
<string name="buffering_goal">Preloading</string> | ||
<string name="buffering_goal_summary">Max. amount of seconds of video to buffer</string> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. In any case we will also need to remove all translations of this because otherwise there are likely going to be issues with Weblate There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I assumed Weblate would manage that itself when someone updates the translations for that language? It's not that much work, but it seems something that should be done automatically (e.g. it is for There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not 100% sure. In the past, I already had build issues due to some string resources messed up by Weblate, but I'm not 100% what used to cause it back then. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Here's what happens if you only remove the source string: https://github.com/you-apps/WallYou/actions/runs/14822641921/job/41611687792#step:4:300. So no, Weblate doesn't seem to handle it. |
||
<string name="playerVideoFormat">Video format for player</string> | ||
<string name="no_audio">No audio</string> | ||
<string name="no_video">No video</string> | ||
|
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.
I think this method is only called when the player is created for the first time, so it stays the same during autoplay or starting other videos (except if the current player is getting closed by the user).
But isn't it very likely that the available RAM is going to change when playing the next video, e.g. via autoplay?
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.
The method also isn't very accurate, since it doesn't include memory used by the kernel :)
Changed it to be based on the total memory that the device has.
Alternatively we could also just choose a value, but in either case I would like to remove this setting, as it's not really user-friendly or helpful.
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.
Sorry for comments here but as a user I feel there should be two options in setting " auto" and "custom" . You can set "auto" by default but if some users want to change it they will. For me this setting save a lots of data uses
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.
The PR actually tries to simplify the preferences and remove "unnecessary"/"unintuitive" preferences that are not really easy to understand or useful.
So adding a new option to toggle between auto and custom would be like the opposite of what this PR is trying to achieve imho.
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.
What's the issue with the (current) default, that requires you changing it?
The (network) data that is consumed is the same, it's just distributed differently.
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.
I want to share my experience with adjusting the buffer size for video streaming. By default, the app has buffer size of 50 seconds, but due to limited data from my provider, I reduced it to 10 seconds.How does this save data? A smaller buffer size reduces data usage when I skip videos. For example, if I'm watching a video and decide I don’t like it after a few seconds, THEN I only consume 10 seconds of buffered data instead of 50 seconds. This prevents wasting data on content I don’t watch.
By the way I tested this PR with a 3-minute video, the app cached nearly the entire video in just a few seconds. If I stopped watching and switched to another video, the cached data for the first video was wasted. A larger buffer size means more data is downloaded upfront, which is inefficient if I frequently skip videos.This is why I recommend keeping a buffer size setting but allowing users to adjust it. A smaller buffer, like 10 seconds, balances smooth playback with minimal data waste, especially for users with limited data plans.