setPlayheadPosition (Browser): Difference between revisions

From Engineering Client Portal

(Created page with "{{Breadcrumb|}} {{Breadcrumb|Digital}} {{Breadcrumb|Browser SDK API Reference}} {{CurrentBreadcrumb}} Category:Digital Category:Browser SDK API Reference For situation...")
 
m (updated input parameter to reflect spec for live playhead position)
 
(One intermediate revision by one other user not shown)
Line 6: Line 6:
*Not receive playhead updates when the content playback is paused, is being buffered, or stopped.
*Not receive playhead updates when the content playback is paused, is being buffered, or stopped.
'''When streaming VOD (Video On Demand)''', the playhead position is the current location of the player from the beginning of the asset in seconds (0, 1, 2, 3, …).
'''When streaming VOD (Video On Demand)''', the playhead position is the current location of the player from the beginning of the asset in seconds (0, 1, 2, 3, …).
'''When streaming live content,''' the playhead position passed is the current UTC time in seconds.
'''When streaming live content,''' the playhead position passed is the current Unix timestamp (seconds since Jan-1-1970 UTC).
'''For Digital Audio streaming Live or On Demand content,''' the playhead position passed is the current UTC time in seconds.
'''For Digital Audio streaming Live or On Demand content,''' the playhead position passed is the current Unix timestamp (seconds since Jan-1-1970 UTC).


== Syntax ==
== Syntax ==
Line 27: Line 27:
| event || setPlayheadPosition
| event || setPlayheadPosition
|-
|-
| playheadposition || The position of playhead while the streaming is in progress (integer).
| playheadposition || An Integer value representing the time in content in seconds (VOD – Video On Demand) or the current Unix timestamp (seconds since Jan-1-1970 UTC) (live).
|}
|}



Latest revision as of 18:37, 10 January 2019

Engineering Portal / Digital / Browser SDK API Reference / setPlayheadPosition (Browser)
For situations where CMS data is used in conjunction with Nielsen’s SDK, the application needs to call setPlayheadPosition in the SDK every second. For proper reporting, the SDK should:

  • Receive a playhead position update every second on the playback of content.
  • Not receive playhead updates when the content playback is paused, is being buffered, or stopped.

When streaming VOD (Video On Demand), the playhead position is the current location of the player from the beginning of the asset in seconds (0, 1, 2, 3, …). When streaming live content, the playhead position passed is the current Unix timestamp (seconds since Jan-1-1970 UTC). For Digital Audio streaming Live or On Demand content, the playhead position passed is the current Unix timestamp (seconds since Jan-1-1970 UTC).

Syntax

ggPM('49', playheadposition); //For VA users only


International (Germany) implementation

ggPM("setPlayheadPosition", playheadposition); // Except VA users

Input Parameters

Parameter Description
event setPlayheadPosition
playheadposition An Integer value representing the time in content in seconds (VOD – Video On Demand) or the current Unix timestamp (seconds since Jan-1-1970 UTC) (live).

Notes

The playhead position must be passed as an integer in parameter 2. Send the progress event to SDK at an interval not greater than 10 seconds, when the content is playing. An interval of one second is recommended for most implementations. For accurate time tracking, it is important to send the whole range of playhead positions from the player.

  • If playing starts at zero, pass the first value as zero (not ‘one’).
  • When the player is paused or stopped, send setPlayheadPosition along with the respective stop / end to the SDK.

Video On Demand Content

ggPM(setPlayheadPosition, setPlayheadPosition);

Live Content through JavaScript

ggPM(setPlayheadPosition, (Date.now()/1000));

Live Event through Flash

ggCom.getInstance().PM('setPlayheadPosition',Math.floor((new Date()).getTime()/1000));