-
Notifications
You must be signed in to change notification settings - Fork 232
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
Add support for videojs 5.x #107
Conversation
@wmcmurray and @kahwee thanks a lot for your PRs. I am very sorry it took us so long to take a look at them. |
init: function (player, options) { | ||
vjs.Component.call(this, player, options); | ||
constructor: function (player, options) { | ||
vjsComponent.call(this, player, options); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will this component work on videojs 4.x??
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could still use the init
property instead of constructor
because it is still supported even if it is deprecated (as described in the second exemple here).
But other parts of this PR will break with videojs 4.x anyway (like the videojs.getComponent
method)... Is that okay if this plugin support only 5.x ? An other plugin I need to use seems to support only the latest 5.x version, that's why I had to add support for 5.x in your plugin 😉
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@wmcmurray The think is that we need to support 4.x for a few months still.
We could create a VJS5 branch and try to keep them both updated until we find a better solution.
Would that work for you?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@carpasse Ok then I suggest that you merge my other pull request #105 (that we have closed) in the master branch, it contains fixes that make the debug page usable, then I hope those changes will disappear from this pull request (hehe) as they will already be merged, then you can make a branch for 5.x and merge this pull request inside.
After that, I'll probably add more features support in the master branch, that we'll merge into 5.x branch when needed.
Sounds good ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@wmcmurray yep. Lets do it like that I have already reopened the PR
Very interested in seeing this get merged as we need VAST/VPAID support in our version 5 player. I've found something while testing out this branch that if an a I'd be more than happy to dig in and help resolve the issue, but figured I'd mention it here first in case you can find / solve it faster than me. EDIT: not sure if it matters, but the original content we're playing before the ad begins is an RTMP stream. EDIT 2: also, just found that |
@alex-phillips can you reproduce this issue the latest release of the plugin? |
@carpasse Actually, yes. My mistake. This is an issue in the current master branch as well. |
@carpasse I've opened a PR for this fix. From what I can tell, it's a race condition where the VAST code is calling Hopefully this can get merged in and @wmcmurray can rebase to include this fix as I'll be using his branch since our player is version 5. |
restoring player tech after ad
So... I rebased this branch and fixed some new bugs. About this fix that fixed issue #73, I had to remove it because videojs 5.x seems to prevent plugins to mess with the player tech (as explained here ). I tried to use the Then I finally realized that in fact, there was no bug anyway. As specified here if you pass the @carpasse could you do the 5.x branch soon ? :) |
Sure, no problem. Thanks! |
@wmcmurray did you test this fix with mobile browser like Safari on Iphone and Chrome on Android/Iphone. I cannot make it work on mobile browser, although there's no errorr at all, the plugin initialized and then freeze, video playback cannot start too. |
@whatvn Oh ! No I haven't tested it on mobile browsers :/ |
Hi everyone, I will base in your commits and update the scripts so the plugin can work in both videojs 4.x as well 5.x. branch that I will start working https://github.com/MailOnline/videojs-vast-vpaid/tree/videojs-5x |
@Fetz as I mentioned in last comment, v5 branch of this project does not work on mobile, I double checked with safari and android on iOS. I did a simple trick to make it works. I manually trigger player.trigger("play") after initializing vastClient, then Ads and media can be played fine. |
@wmcmurray We have finally added support for videojs 5.x including your changes. If you are not happy with it please reopen the PR. |
NOTE: I copied the relevant changes from this pull request #86 and I fixed what wasn't working. I did this because I needed a working version ASAP for my colleagues.
I also did this pull request on top of my other pull request (#105) because I needed those changes applied.
...So, it works, but I've seen some strange stuff that (I believe) are not related to this plugin :
timeupdate
event is not triggered on flash ads, which cause the remaining time to stay stuck at-0:46
in the demo page (it's the duration of the video that will play after the ad).I hope you'll merge this soon, thanks !
Will fix issue #74