-
-
Notifications
You must be signed in to change notification settings - Fork 306
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
Wrong JWPlayer provider & General player issues #10
Comments
"@hola.org/jwplayer-hlsjs" is not initialized. You have to add https://cdn.jsdelivr.net/npm/hls.js@latest script. Then in a browser's console you will see 'init hola/hls provider v0.0.79 hls v0.11.0' message. It means that the provider is initialized. |
Thanks, that worked. Another question, I have some configurations from my old HLS provider and I would like to make some changes to the P2P configuration (like changing the tracker). But I could not change the default settings for HLS and P2P. Can you give me a little help with that? I do not have an intermediate knowledge in javascript |
You have to configure P2P Hls.js Engine instance like this: var engine = new p2pml.hlsjs.Engine({
loader: {
trackerAnnounce: [ "wss://tracker1.xyz/", "wss://tracker2.com/" ]
}
}); Engine configuration documentation: HybridLoader settings documentaion (i.e. |
Thank you, your help is very appreciated :) |
I reopened this to ask one more info. I'm using this: but it does not seem to have any effect |
You have to use liveSyncDuration parameter of Hls.js playback engine. It is in seconds. p2pml.hlsjs.initJwPlayer(player, {liveSyncDuration: 60, loader: engine.createLoaderClass() }); |
Nothing changed :/ |
Most likely buffering issues are related to Hls.js engine itself. You have to test it with raw Hls.js without P2P and player integrations. And if it doesn't work as expected report issues to Hls.js project. You can use this fiddle as the base for your testing: https://jsfiddle.net/yhLnqu3t/ |
I make this fiddle if you want to view what i'm saying: https://jsfiddle.net/hmyapb2n/1/ |
There is another way of initialization that should be more correct. Please check if it works for you. Also it will output hls.js configuration into console: var engine = new p2pml.hlsjs.Engine();
var player = jwplayer("player");
player.setup({
autostart: true,
sources: [{
file: "https://wowza.peer5.com/live/smil:bbb_abr.smil/playlist.m3u8",
type: "mp4"
}],
});
player.hola_config = {
liveSyncDuration: 60,
loader: engine.createLoaderClass()
};
var provider = require("@hola.org/jwplayer-hlsjs");
provider.attach();
p2pml.hlsjs.initJwPlayer(player);
setTimeout(() => console.log(player.hls.config), 2000); |
No results. Something is stucking "maxBufferLength" to 30 seconds, like the jwplayer default hls provider. In console, the config is showed as expected. But in player don't work :/ |
I see other issue here. When the jwplayer is configured to show ads with VAST (not tested with google IMA), the player dies with error "Error in "time" event handler: TypeError: Cannot convert undefined or null to object". The player also does not save the quality and audio settings, and I saw that in later versions the subtitles also do not work as they should. Apparently these problems are from the holajs provider. Is there any way to use another HLS provider? Advertisement test: https://jsfiddle.net/hmyapb2n/4/ |
Looks like the problems go from hola HLS provider. P2P Media Loader supports hls.js and Shaka Player playback engines. We can integrate with players that use one of these playback engines built-in or via a plugin. In the case of JWPlayer we found only this plugin that works via hls.js |
Hi Yokutto, how do you check if liveSyncDuration setting is applied? I just tried mrlika's example and it worked. But would like to see what you're getting and how did you solve it if you did? thanks |
Can't reproduce the issue - JWPlayer requires a paid plan to display VAST. Open source JWPlayer has no VAST support. |
Hi, I tried to create a jwplayer instance in HLS with P2P, but it does not seem to work. In my tests the HLS is always loaded by the "provider.hlsjs.js" (default hls script of jwplayer), in the demo example i see that the segments are loaded by the initiator "p2p-media-loader-hlsjs.min.js". I can not see the difference between the test I did and the demo, could anyone explain what I did wrong?
Demo: https://jsfiddle.net/gkob21fv/1/
Browser: Chrome 70 win10
The text was updated successfully, but these errors were encountered: