-
Notifications
You must be signed in to change notification settings - Fork 110
FAQ
tom edited this page Mar 26, 2018
·
3 revisions
A: videoView.getVideoInfo().addOption(Option.create(IjkMediaPlayer.OPT_CATEGORY_FORMAT, "user_agent", "myAgent/1.0"));
A: compile 'com.github.tcking:giraffeplayer2:0.1.19-lazyLoad'
A: download from github CDN: https://github.com/tcking/GiraffePlayerLazyLoadFiles
A: Yes,first you copy so files to your server from https://github.com/tcking/GiraffePlayerLazyLoadFiles,and then setSoFetcher eg:
LazyLoadManager.setSoFetcher(new LazyLoadManager.SoFetcher() {
@Override
public String getURL(String abi, String soVersion) {
return "your server url";
}
});
A: Yes,you can configuration all player by PlayerManager.getInstance().getDefaultVideoInfo()
,eg:
PlayerManager.getInstance().getDefaultVideoInfo()
//set user-agent for all players
.addOption(Option.create(IjkMediaPlayer.OPT_CATEGORY_FORMAT, "user_agent", "myAgent/1.0"));
//Use persistent connections for all players
.addOption(Option.create(IjkMediaPlayer.OPT_CATEGORY_FORMAT, "multiple_requests", 1L))
videoInfo.addOption(Option.create(IjkMediaPlayer.OPT_CATEGORY_FORMAT, "headers", "Cookie: key=value\n"))