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 xapi video verbs #17

Open
wants to merge 149 commits into
base: master
from

Conversation

Projects
None yet
9 participants
@KirkJohnson
Copy link

KirkJohnson commented Nov 23, 2017

This pull request implements xAPI statements for the following video events: initialized, played, paused, seeked, finished, and interacted.

Context: h5p/h5p-interactive-video#40 (comment)

Here is the implementation chart of the new verbs in the different players (note that we did not implement in the Flash player, but can do so as future work):

xAPI Verb Youtube HTML5 Flash
seeked Youtube HTML5 Flash
interacted (volume changed) Youtube HTML5 Flash
completed Youtube HTML5 Flash
interacted (fullscreen) Youtube HTML5 Flash
played Youtube HTML5 Flash
initialized Youtube HTML5 Flash
paused Youtube HTML5 Flash

KirkJohnson and others added some commits Nov 6, 2017

Added Seeked Functionailty
Added code to handle seeked event and trigger an xAPI statement
Added xAPI extending functionality
added code for sending following events
-seek
-volume change
-fullscreen
-play
-pause
-Initiated

I haven’t actually been able to get the fullscreen event to trigger
Added xAPI for Youtube
Used Youtube Video API to implement:
-Seek
-Play
-Pause
-Initiated
This is all that was possible via their API
Ensure xAPI played event sent appropriately
Play wasn’t firing with play button was hit all the time so I added functionality in the state change event to evaluate if play event needed to be triggered.
Moved Competion Prams into a function
Moved completion params into a function
Reverted Changes on Video JS
Haven’t been able to get this code to call for testing in any video upload with Wordpress so I am not adding functionality for this.
Modifying for seek
Fine tuned seek event more.  It is working very well on HTML5 still need some work on Youtube for the events when a user is scrubbing.
Format Float on played segments
Made sure all floats in played segments were formatted to correct precision
Fix whitespace
maintainer uses 2 spaces for indentation, make sure to follow this style.
Refactor xAPI object function names
Use template getArgsXAPI{verb} instead of getxAPI{verb}Object
Refactor xAPI function names
xAPI verbs are past tense, so make the function names match.
Fix for misnamed variable
html5 video object has a property called currentTime, not current_time
Added Seeked Functionailty
Added code to handle seeked event and trigger an xAPI statement
Added xAPI extending functionality
added code for sending following events
-seek
-volume change
-fullscreen
-play
-pause
-Initiated

I haven’t actually been able to get the fullscreen event to trigger
Added xAPI for Youtube
Used Youtube Video API to implement:
-Seek
-Play
-Pause
-Initiated
This is all that was possible via their API

KirkJohnson and others added some commits Apr 4, 2018

Add video length to initialized statement
Was asked by Jon to add video length to the extensions sent by the intialized verb.
Merge branch 'add-xapi-video-verbs' of https://github.com/uhm-coe/h5p…
…-video into add-xapi-video-verbs

# Conflicts:
#	scripts/html5.js
#	scripts/youtube.js
COE User
Use Youtube API to pass correct duration
Youtube was passing 0 in for video duration so I changed this to use the api’s method to get video length.
@otacke

This comment has been minimized.

Copy link
Member

otacke commented Apr 28, 2018

A quick update: There are some free days in May that I'll try to use to come up with the "final implementation".

@thedeviousdev thedeviousdev referenced this pull request May 21, 2018

Open

Navigation Hotspot #90

figureone added some commits May 25, 2018

Revert 6dd68ac
Updating the currently playing segment start time when the video starts playing is required in certain scenarios. For example, If a user revisits a page with a youtube video that they had previously partially watched, the video will resume from where they left off. If we don’t set `playingSegmentStart` on the play event, the first playing segment recorded will start at 0 (the beginning of the video) rather than the timecode the video resumed from.
@figureone

This comment has been minimized.

Copy link

figureone commented May 25, 2018

Aloha @otacke, just checking in. Today I fixed some regressions caused by a botched merge last month (94ff7b3), everything looks good now.

I also reverted your commit 6dd68ac in 26b8f94 because I found an edge case where a newly initialized video resumed from where the user had previously left off, requiring that playingSegmentStart be set in the play event (otherwise a segment from 0 to the resumed timecode would be inserted).

@jmkevan has reviewed and tested video statements sent to an LRS and hasn't found any issues.

Let us know if you have any questions or comments! Cheers, -p

@otacke

This comment has been minimized.

Copy link
Member

otacke commented May 28, 2018

@figureone @jmkevan Thanks for the update, fixing the bug, and testing everything! I'm really sorry for not having worked on this issue, but I simply couldn't find the time so far.

@jmkevan

This comment has been minimized.

Copy link

jmkevan commented Jun 6, 2018

@otacke - Checking in on this. I hate to be pushy, but we have several projects that are running out of time to use this functionality. We are really hoping you can get this finalized in the next several weeks!

We appreciate all your time and effort!

  • Jon
@H5P-Helper

This comment has been minimized.

Copy link

H5P-Helper commented Jun 11, 2018

@jmkevan

This comment has been minimized.

Copy link

jmkevan commented Oct 5, 2018

Aloha @otacke - Just thought I would check-in and see if there are any updates

@otacke

This comment has been minimized.

Copy link
Member

otacke commented Oct 5, 2018

@jmkevan Actually: Yes! As you can see in our issue tracker, the ticket has been updated shortly and now lists Baduhenna as the "Fix Version". That means we want to invest some of our time to finish this task for the Baduhenna Release (that's just an internal name).

@jmkevan

This comment has been minimized.

Copy link

jmkevan commented Oct 5, 2018

That's fantastic. Thank Oliver!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment