Skip to content
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

No way to check if automatic adaptation enabled #29

Closed
sanbornhilland opened this issue Mar 10, 2015 · 5 comments
Closed

No way to check if automatic adaptation enabled #29

sanbornhilland opened this issue Mar 10, 2015 · 5 comments
Labels
status: archived Archived and locked; will not be updated type: enhancement New feature or request

Comments

@sanbornhilland
Copy link
Contributor

I can't see a way to check if adaptation is enabled or not. I think it would be useful to have a method player.getAdaptationEnabled() that just returns the value of adaptationEnabled_.

@joeyparrish
Copy link
Member

Hrm... It's easy enough to add, and I don't mind doing it. But out of curiosity, why is it useful? I had thought that there would be two basic use cases:

  1. Adaptation always enabled or disabled, and therefore set once programmatically.
  2. Adaptation always controlled by some application UI element, and therefore set on interaction with that element.

When would you want to query the state? How would your application lose track of whether or not adaptation was enabled?

@joeyparrish joeyparrish self-assigned this Mar 10, 2015
@sanbornhilland
Copy link
Contributor Author

I agree with you that it is easy enough to keep track of but if it's ever ambiguous what the starting state is or just not known what the starting state is, it seems like there is the potential to get out of sync. To me it seems like it's the responsibility of the player to manage its own state and that way whoever is using it can't ever get out of sync or make the wrong assumption about what state it is in.

Also, I'm happy to submit a pull request so you can concentrate on higher priority stuff. Maybe this won't be generally considered useful.

@joeyparrish joeyparrish removed their assignment Mar 10, 2015
@joeyparrish joeyparrish added the type: enhancement New feature or request label Mar 10, 2015
@joeyparrish
Copy link
Member

I'm not sure it would get out of sync, though. It's easy to set explicitly as soon as Player is created.

In any case, this debate is purely philosophical. I don't object to the feature. Please feel free to submit a pull request.

It may be a bit more pain than contributing to the typical open-source project, but Google does require a one-time contributor agreement as outlined in CONTRIBUTING.md.

And thanks for offering to contribute. You're the first!

sanbornhilland pushed a commit to sanbornhilland/shaka-player that referenced this issue Mar 11, 2015
@Awais-cb
Copy link

this is the way of checking if abr is enabled or not

shakaPlayer.getConfiguration().abr.enabled

it returns true or false accordingly.

@joeyparrish
Copy link
Member

@Awais-cb, this thread was closed 2.5 years ago. Please try not to reopen very old threads. Shaka Player looks very different today than it did in 2015. Thanks!

@shaka-project shaka-project locked and limited conversation to collaborators Mar 22, 2018
@shaka-bot shaka-bot added the status: archived Archived and locked; will not be updated label Apr 15, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
status: archived Archived and locked; will not be updated type: enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

5 participants