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

Configure player method #93

Closed
allenevans opened this issue Jun 9, 2015 · 1 comment
Closed

Configure player method #93

allenevans opened this issue Jun 9, 2015 · 1 comment
Labels
flag: good first issue This might be a relatively easy issue; good for new contributors status: archived Archived and locked; will not be updated type: code health A code health issue type: enhancement New feature or request
Milestone

Comments

@allenevans
Copy link

It would be nice to have a generalized configure method on the player which accepts an object literal to specify values such as buffer size.

var mediaPlayer = new shaka.player.Player(videoElement);
mediaPlayer.setStreamBufferSize(120);

would become:

var mediaPlayer = new shaka.player.Player(videoElement);
mediaPlayer.configure({ streamBufferSize : 120 });

One significant advantage of doing this will be to reduce coupling to the specific player api methods. For example, if setStreamBufferSize was renamed to setBufferSize, the player would break whereas changing the name in the object literal will simply mean the values are ignored and playback would continue.

This would be helpful when A/B testing between player versions.

@joeyparrish
Copy link
Member

I agree completely. Configuration methods that did not already exist on Player in v1.3.1 could be moved purely to the new configure() interface. Other configuration methods could be rewritten to delegate to configure internally, and would then be closure-annotated with "deprecated".

@joeyparrish joeyparrish added type: enhancement New feature or request type: code health A code health issue flag: good first issue This might be a relatively easy issue; good for new contributors labels Jun 9, 2015
@joeyparrish joeyparrish modified the milestone: v1.5.0 Jul 1, 2015
@tdrews tdrews self-assigned this Jul 9, 2015
@tdrews tdrews closed this as completed in 59723f1 Jul 13, 2015
joeyparrish added a commit that referenced this issue Jul 15, 2015
The configure test was setting the timeout to a very small number
and did not reset the config.

Ultimately, this should be fixed by reachitecting the settings to
avoid static variables so that settings are per-instance.

Bug introduced in issue #93
Phase one of issue #126

Change-Id: Icfae6cd425677929115878477eca26d9292d2dff
@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
flag: good first issue This might be a relatively easy issue; good for new contributors status: archived Archived and locked; will not be updated type: code health A code health issue type: enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

5 participants