Skip to content

Commit

Permalink
feat(config): pass dash config (#14)
Browse files Browse the repository at this point in the history
  • Loading branch information
Dan Ziv committed Jun 29, 2017
1 parent 24e6e78 commit d4af905
Show file tree
Hide file tree
Showing 6 changed files with 83 additions and 43 deletions.
40 changes: 28 additions & 12 deletions dist/playkit-dash.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/playkit-dash.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/playkit-dash.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/playkit-dash.min.js.map

Large diffs are not rendered by default.

13 changes: 13 additions & 0 deletions src/dash-adapter.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,19 @@ export default class DashAdapter extends BaseMediaSourceAdapter {
*/
_loadPromise: ?Promise<Object>;

/**
* Factory method to create media source adapter.
* @function createAdapter
* @param {HTMLVideoElement} videoElement - The video element that the media source adapter work with.
* @param {Object} source - The source Object.
* @param {Object} config - The player configuration.
* @returns {IMediaSourceAdapter} - New instance of the run time media source adapter.
* @static
*/
static createAdapter(videoElement: HTMLVideoElement, source: Source, config: Object): IMediaSourceAdapter {
return new this(videoElement, source, config.playback.options.html5.dash);
}

/**
* Checks if dash adapter can play a given mime type
* @function canPlayType
Expand Down
Loading

0 comments on commit d4af905

Please sign in to comment.