shaka-player
Advanced tools
Comparing version 2.2.4 to 2.2.5
@@ -273,3 +273,3 @@ /** | ||
licenseServers: { | ||
'com.widevine.alpha': '//widevine-proxy.appspot.com/proxy' | ||
'com.widevine.alpha': '//proxy.uat.widevine.com/proxy' | ||
} | ||
@@ -324,3 +324,3 @@ }, | ||
licenseServers: { | ||
'com.widevine.alpha': '//widevine-proxy.appspot.com/proxy' | ||
'com.widevine.alpha': '//proxy.uat.widevine.com/proxy' | ||
} | ||
@@ -414,3 +414,3 @@ }, | ||
licenseServers: { | ||
'com.widevine.alpha': '//widevine-proxy.appspot.com/proxy' | ||
'com.widevine.alpha': '//proxy.uat.widevine.com/proxy' | ||
} | ||
@@ -500,3 +500,3 @@ }, | ||
licenseServers: { | ||
'com.widevine.alpha': '//widevine-proxy.appspot.com/proxy' | ||
'com.widevine.alpha': '//proxy.uat.widevine.com/proxy' | ||
} | ||
@@ -697,3 +697,3 @@ }, | ||
licenseServers: { | ||
'com.widevine.alpha': '//widevine-proxy.appspot.com/proxy' | ||
'com.widevine.alpha': '//proxy.uat.widevine.com/proxy' | ||
} | ||
@@ -700,0 +700,0 @@ }, |
@@ -26,3 +26,3 @@ // This file was autogenerated by third_party/closure/deps/depswriter.py. | ||
goog.addDependency('../../../lib/media/mp4_segment_index_parser.js', ['shaka.media.Mp4SegmentIndexParser'], ['goog.asserts', 'shaka.log', 'shaka.media.SegmentReference', 'shaka.util.Error', 'shaka.util.Mp4Parser']); | ||
goog.addDependency('../../../lib/media/playhead.js', ['shaka.media.Playhead'], ['goog.asserts', 'shaka.log', 'shaka.media.TimeRangesUtils', 'shaka.util.EventManager', 'shaka.util.FakeEvent', 'shaka.util.IDestroyable', 'shaka.util.StreamUtils']); | ||
goog.addDependency('../../../lib/media/playhead.js', ['shaka.media.Playhead'], ['goog.asserts', 'shaka.log', 'shaka.media.TimeRangesUtils', 'shaka.util.EventManager', 'shaka.util.FakeEvent', 'shaka.util.IDestroyable', 'shaka.util.StreamUtils', 'shaka.util.Timer']); | ||
goog.addDependency('../../../lib/media/playhead_observer.js', ['shaka.media.PlayheadObserver'], ['goog.asserts', 'shaka.media.TimeRangesUtils', 'shaka.util.ConfigUtils', 'shaka.util.EventManager', 'shaka.util.FakeEvent', 'shaka.util.IDestroyable', 'shaka.util.StreamUtils']); | ||
@@ -29,0 +29,0 @@ goog.addDependency('../../../lib/media/presentation_timeline.js', ['shaka.media.PresentationTimeline'], ['goog.asserts', 'shaka.log', 'shaka.media.SegmentReference']); |
@@ -1099,2 +1099,7 @@ /** | ||
/** | ||
* Return the manifest information if it's loaded. Otherwise, return null. | ||
* @return {?shakaExtern.Manifest} | ||
*/ | ||
shaka.Player.prototype.getManifest = function() {}; | ||
/** | ||
* Creates a SegmentIndex. | ||
@@ -1101,0 +1106,0 @@ * @param {!Array.<!shaka.media.SegmentReference>} references The list of |
@@ -1099,2 +1099,7 @@ /** | ||
/** | ||
* Return the manifest information if it's loaded. Otherwise, return null. | ||
* @return {?shakaExtern.Manifest} | ||
*/ | ||
shaka.Player.prototype.getManifest = function() {}; | ||
/** | ||
* Creates a SegmentIndex. | ||
@@ -1101,0 +1106,0 @@ * @param {!Array.<!shaka.media.SegmentReference>} references The list of |
@@ -97,3 +97,3 @@ # Shaka Upgrade Guide, v1.x => v2 | ||
'keySystem': 'com.widevine.alpha', | ||
'licenseServerUrl': '//widevine-proxy.appspot.com/proxy' | ||
'licenseServerUrl': '//proxy.uat.widevine.com/proxy' | ||
}]; | ||
@@ -128,3 +128,3 @@ } else if (schemeIdUri.toLowerCase() == | ||
servers: { | ||
'com.widevine.alpha': '//widevine-proxy.appspot.com/proxy' | ||
'com.widevine.alpha': '//proxy.uat.widevine.com/proxy' | ||
'com.microsoft.playready': '//playready.directtaps.net/pr/svc/rightsmanager.asmx' | ||
@@ -186,3 +186,3 @@ } | ||
'keySystem': 'com.widevine.alpha', | ||
'licenseServerUrl': '//widevine-proxy.appspot.com/proxy', | ||
'licenseServerUrl': '//proxy.uat.widevine.com/proxy', | ||
@@ -189,0 +189,0 @@ 'distinctiveIdentifierRequired': true, |
@@ -57,12 +57,11 @@ # Welcome to Shaka Player | ||
#### Join the community | ||
#### Join the announcement list | ||
If you want to discuss Shaka Player development or receive notifications when | ||
a new version is released, you should join our [users group]. | ||
If you want to receive release or survey announcements, you should join our | ||
[mailing list](https://groups.google.com/forum/#!forum/shaka-player-users). | ||
The list is very low volume. | ||
[users group]: https://groups.google.com/forum/#!forum/shaka-player-users | ||
#### Continue the Tutorials | ||
Next, check out {@tutorial basic-usage}. |
@@ -173,3 +173,3 @@ /** | ||
* @property {number} presentationTimeOffset | ||
* The presentation time offset of the stream. | ||
* The presentation time offset of the stream, in seconds. | ||
* @property {string} contentType | ||
@@ -176,0 +176,0 @@ * The type of the stream, 'audio', 'text', or 'video'. |
@@ -98,3 +98,3 @@ /** | ||
'loading', | ||
'unloading', | ||
'streaming', | ||
'texttrackvisibility', | ||
@@ -104,3 +104,4 @@ 'timelineregionadded', | ||
'timelineregionexit', | ||
'trackschanged' | ||
'trackschanged', | ||
'unloading' | ||
]; | ||
@@ -119,2 +120,3 @@ | ||
'getExpiration', | ||
'getManifest', | ||
'getManifestUri', | ||
@@ -121,0 +123,0 @@ 'getPlaybackRate', |
@@ -288,3 +288,3 @@ /** | ||
* initSegmentReference: shaka.media.InitSegmentReference, | ||
* presentationTimeOffset: (number|undefined) | ||
* scaledPresentationTimeOffset: number | ||
* }} | ||
@@ -304,4 +304,4 @@ * | ||
* The init segment for the stream. | ||
* @property {(number|undefined)} presentationTimeOffset | ||
* The presentationTimeOffset for the stream. | ||
* @property {number} scaledPresentationTimeOffset | ||
* The presentation time offset for the stream, in seconds. | ||
*/ | ||
@@ -1111,3 +1111,3 @@ shaka.dash.DashParser.StreamInfo; | ||
initSegmentReference: null, | ||
presentationTimeOffset: 0 | ||
scaledPresentationTimeOffset: 0 | ||
}; | ||
@@ -1127,3 +1127,3 @@ } | ||
initSegmentReference: streamInfo.initSegmentReference, | ||
presentationTimeOffset: streamInfo.presentationTimeOffset, | ||
presentationTimeOffset: streamInfo.scaledPresentationTimeOffset, | ||
mimeType: context.representation.mimeType, | ||
@@ -1130,0 +1130,0 @@ codecs: context.representation.codecs, |
@@ -60,3 +60,3 @@ /** | ||
* startNumber: number, | ||
* presentationTimeOffset: number, | ||
* scaledPresentationTimeOffset: number, | ||
* unscaledPresentationTimeOffset: number, | ||
@@ -75,6 +75,6 @@ * timeline: Array.<shaka.dash.MpdUtils.TimeRange> | ||
* The start number of the segments; 1 or greater. | ||
* @property {number} presentationTimeOffset | ||
* The presentationTimeOffset of the representation, in seconds. | ||
* @property {number} scaledPresentationTimeOffset | ||
* The presentation time offset of the representation, in seconds. | ||
* @property {number} unscaledPresentationTimeOffset | ||
* The presentationTimeOffset of the representation, in timescale units. | ||
* The presentation time offset of the representation, in timescale units. | ||
* @property {Array.<shaka.dash.MpdUtils.TimeRange>} timeline | ||
@@ -160,3 +160,3 @@ * The timeline of the representation, if given. Times in seconds. | ||
* @param {number} timescale | ||
* @param {number} presentationTimeOffset | ||
* @param {number} unscaledPresentationTimeOffset | ||
* @param {number} periodDuration The Period's duration in seconds. | ||
@@ -166,4 +166,5 @@ * Infinity indicates that the Period continues indefinitely. | ||
*/ | ||
shaka.dash.MpdUtils.createTimeline = function( | ||
segmentTimeline, timescale, presentationTimeOffset, periodDuration) { | ||
shaka.dash.MpdUtils.createTimeline = | ||
function(segmentTimeline, timescale, unscaledPresentationTimeOffset, | ||
periodDuration) { | ||
goog.asserts.assert( | ||
@@ -192,3 +193,3 @@ timescale > 0 && timescale < Infinity, | ||
if (t != null) | ||
t -= presentationTimeOffset; | ||
t -= unscaledPresentationTimeOffset; | ||
@@ -319,4 +320,5 @@ if (!d) { | ||
MpdUtils.inheritAttribute(context, callback, 'startNumber'); | ||
var presentationTimeOffset = | ||
MpdUtils.inheritAttribute(context, callback, 'presentationTimeOffset'); | ||
var unscaledPresentationTimeOffset = | ||
Number(MpdUtils.inheritAttribute(context, callback, | ||
'presentationTimeOffset')) || 0; | ||
var startNumber = XmlUtils.parseNonNegativeInt(startNumberStr || ''); | ||
@@ -332,7 +334,8 @@ if (startNumberStr == null || startNumber == null) | ||
timeline = MpdUtils.createTimeline( | ||
timelineNode, timescale, Number(presentationTimeOffset), | ||
timelineNode, timescale, unscaledPresentationTimeOffset, | ||
context.periodInfo.duration || Infinity); | ||
} | ||
var pto = (Number(presentationTimeOffset) / timescale) || 0; | ||
var scaledPresentationTimeOffset = | ||
(unscaledPresentationTimeOffset / timescale) || 0; | ||
return { | ||
@@ -342,4 +345,4 @@ timescale: timescale, | ||
startNumber: startNumber, | ||
presentationTimeOffset: pto, | ||
unscaledPresentationTimeOffset: Number(presentationTimeOffset), | ||
scaledPresentationTimeOffset: scaledPresentationTimeOffset, | ||
unscaledPresentationTimeOffset: unscaledPresentationTimeOffset, | ||
timeline: timeline | ||
@@ -346,0 +349,0 @@ }; |
@@ -90,10 +90,21 @@ /** | ||
var SegmentBase = shaka.dash.SegmentBase; | ||
var XmlUtils = shaka.util.XmlUtils; | ||
var presentationTimeOffset = MpdUtils.inheritAttribute( | ||
context, SegmentBase.fromInheritance_, 'presentationTimeOffset'); | ||
var unscaledPresentationTimeOffset = Number(MpdUtils.inheritAttribute( | ||
context, SegmentBase.fromInheritance_, 'presentationTimeOffset')) || 0; | ||
var timescaleStr = MpdUtils.inheritAttribute( | ||
context, SegmentBase.fromInheritance_, 'timescale'); | ||
var timescale = 1; | ||
if (timescaleStr) { | ||
timescale = XmlUtils.parsePositiveInt(timescaleStr) || 1; | ||
} | ||
var scaledPresentationTimeOffset = | ||
(unscaledPresentationTimeOffset / timescale) || 0; | ||
var init = | ||
SegmentBase.createInitSegment(context, SegmentBase.fromInheritance_); | ||
var index = SegmentBase.createSegmentIndex_( | ||
context, requestInitSegment, init, Number(presentationTimeOffset)); | ||
context, requestInitSegment, init, unscaledPresentationTimeOffset); | ||
@@ -105,3 +116,3 @@ return { | ||
initSegmentReference: init, | ||
presentationTimeOffset: Number(presentationTimeOffset) || 0 | ||
scaledPresentationTimeOffset: scaledPresentationTimeOffset | ||
}; | ||
@@ -121,3 +132,3 @@ }; | ||
* @param {string} containerType | ||
* @param {number} presentationTimeOffset | ||
* @param {number} unscaledPresentationTimeOffset | ||
* @return {shaka.dash.DashParser.SegmentIndexFunctions} | ||
@@ -127,3 +138,3 @@ */ | ||
context, requestInitSegment, init, uris, | ||
startByte, endByte, containerType, presentationTimeOffset) { | ||
startByte, endByte, containerType, unscaledPresentationTimeOffset) { | ||
var presentationTimeline = context.presentationTimeline; | ||
@@ -153,3 +164,3 @@ var fitLast = !context.dynamic || !context.periodInfo.isLastPeriod; | ||
references = shaka.media.Mp4SegmentIndexParser( | ||
indexData, startByte, uris, presentationTimeOffset); | ||
indexData, startByte, uris, unscaledPresentationTimeOffset); | ||
} else { | ||
@@ -159,3 +170,3 @@ goog.asserts.assert(initData, 'WebM requires init data'); | ||
references = parser.parse(indexData, initData, uris, | ||
presentationTimeOffset); | ||
unscaledPresentationTimeOffset); | ||
} | ||
@@ -208,3 +219,3 @@ | ||
* @param {shaka.media.InitSegmentReference} init | ||
* @param {number} presentationTimeOffset | ||
* @param {number} unscaledPresentationTimeOffset | ||
* @return {shaka.dash.DashParser.SegmentIndexFunctions} | ||
@@ -215,3 +226,3 @@ * @throws shaka.util.Error When there is a parsing error. | ||
shaka.dash.SegmentBase.createSegmentIndex_ = function( | ||
context, requestInitSegment, init, presentationTimeOffset) { | ||
context, requestInitSegment, init, unscaledPresentationTimeOffset) { | ||
var MpdUtils = shaka.dash.MpdUtils; | ||
@@ -280,3 +291,3 @@ var SegmentBase = shaka.dash.SegmentBase; | ||
context, requestInitSegment, init, indexUris, indexRange.start, | ||
indexRange.end, containerType, presentationTimeOffset); | ||
indexRange.end, containerType, unscaledPresentationTimeOffset); | ||
}; |
@@ -89,3 +89,3 @@ /** | ||
initSegmentReference: init, | ||
presentationTimeOffset: info.presentationTimeOffset | ||
scaledPresentationTimeOffset: info.scaledPresentationTimeOffset | ||
}; | ||
@@ -117,3 +117,3 @@ }; | ||
* startNumber: number, | ||
* presentationTimeOffset: number, | ||
* scaledPresentationTimeOffset: number, | ||
* timeline: Array.<shaka.dash.MpdUtils.TimeRange>, | ||
@@ -133,4 +133,4 @@ * mediaSegments: !Array.<shaka.dash.SegmentList.MediaSegment> | ||
* The start number of the segments; 1 or greater. | ||
* @property {number} presentationTimeOffset | ||
* The presentationTimeOffset of the representation, in seconds. | ||
* @property {number} scaledPresentationTimeOffset | ||
* The scaledPresentationTimeOffset of the representation, in seconds. | ||
* @property {Array.<shaka.dash.MpdUtils.TimeRange>} timeline | ||
@@ -189,3 +189,3 @@ * The timeline of the representation, if given. Times in seconds. | ||
startNumber: startNumber, | ||
presentationTimeOffset: segmentInfo.presentationTimeOffset, | ||
scaledPresentationTimeOffset: segmentInfo.scaledPresentationTimeOffset, | ||
timeline: segmentInfo.timeline, | ||
@@ -192,0 +192,0 @@ mediaSegments: mediaSegments |
@@ -108,3 +108,3 @@ /** | ||
initSegmentReference: init, | ||
presentationTimeOffset: info.presentationTimeOffset | ||
scaledPresentationTimeOffset: info.scaledPresentationTimeOffset | ||
}; | ||
@@ -119,3 +119,3 @@ }; | ||
* startNumber: number, | ||
* presentationTimeOffset: number, | ||
* scaledPresentationTimeOffset: number, | ||
* unscaledPresentationTimeOffset: number, | ||
@@ -137,6 +137,6 @@ * timeline: Array.<shaka.dash.MpdUtils.TimeRange>, | ||
* The start number of the segments; 1 or greater. | ||
* @property {number} presentationTimeOffset | ||
* The presentationTimeOffset of the representation, in seconds. | ||
* @property {number} scaledPresentationTimeOffset | ||
* The presentation time offset of the representation, in seconds. | ||
* @property {number} unscaledPresentationTimeOffset | ||
* The presentationTimeOffset of the representation, in timescale units. | ||
* The presentation time offset of the representation, in timescale units. | ||
* @property {Array.<shaka.dash.MpdUtils.TimeRange>} timeline | ||
@@ -184,3 +184,3 @@ * The timeline of the representation, if given. Times in seconds. | ||
startNumber: segmentInfo.startNumber, | ||
presentationTimeOffset: segmentInfo.presentationTimeOffset, | ||
scaledPresentationTimeOffset: segmentInfo.scaledPresentationTimeOffset, | ||
unscaledPresentationTimeOffset: segmentInfo.unscaledPresentationTimeOffset, | ||
@@ -298,3 +298,3 @@ timeline: segmentInfo.timeline, | ||
context, requestInitSegment, init, resolvedUris, 0, null, containerType, | ||
info.presentationTimeOffset); | ||
info.scaledPresentationTimeOffset); | ||
}; | ||
@@ -301,0 +301,0 @@ |
@@ -53,2 +53,6 @@ /** | ||
/** @type {function(*, ...*)} */ | ||
shaka.log.alwaysWarn = function() {}; | ||
/** @type {function(*, ...*)} */ | ||
shaka.log.error = function() {}; | ||
@@ -80,2 +84,4 @@ | ||
if (window.console && window.console.log.bind) { | ||
shaka.log.alwaysWarn = console.warn.bind(console); | ||
if (goog.DEBUG) { | ||
@@ -82,0 +88,0 @@ /** @type {number} */ |
@@ -105,4 +105,5 @@ /** | ||
/** @private {?number} */ | ||
this.expirationInterval_ = setInterval(this.pollExpiration_.bind(this), 1000); | ||
/** @private {?shaka.util.Timer} */ | ||
this.expirationTimer_ = new shaka.util.Timer(this.pollExpiration_.bind(this)); | ||
this.expirationTimer_.scheduleRepeated(1); | ||
@@ -191,5 +192,5 @@ // Add a catch to the Promise to avoid console logs about uncaught errors. | ||
if (this.expirationInterval_) { | ||
clearInterval(this.expirationInterval_); | ||
this.expirationInterval_ = null; | ||
if (this.expirationTimer_) { | ||
this.expirationTimer_.cancel(); | ||
this.expirationTimer_ = null; | ||
} | ||
@@ -199,4 +200,4 @@ | ||
this.keyStatusTimer_.cancel(); | ||
this.keyStatusTimer_ = null; | ||
} | ||
this.keyStatusTimer_ = null; | ||
@@ -203,0 +204,0 @@ this.currentDrmInfo_ = null; |
@@ -34,3 +34,3 @@ /** | ||
* contains the segments. | ||
* @param {number} presentationTimeOffset | ||
* @param {number} unscaledPresentationTimeOffset | ||
* @return {!Array.<!shaka.media.SegmentReference>} | ||
@@ -40,3 +40,3 @@ * @throws {shaka.util.Error} | ||
shaka.media.Mp4SegmentIndexParser = function( | ||
sidxData, sidxOffset, uris, presentationTimeOffset) { | ||
sidxData, sidxOffset, uris, unscaledPresentationTimeOffset) { | ||
@@ -51,3 +51,3 @@ var Mp4SegmentIndexParser = shaka.media.Mp4SegmentIndexParser; | ||
sidxOffset, | ||
presentationTimeOffset, | ||
unscaledPresentationTimeOffset, | ||
uris, | ||
@@ -77,3 +77,3 @@ box); | ||
* @param {number} sidxOffset | ||
* @param {number} presentationTimeOffset | ||
* @param {number} unscaledPresentationTimeOffset | ||
* @param {!Array.<string>} uris The possible locations of the MP4 file that | ||
@@ -87,3 +87,3 @@ * contains the segments. | ||
sidxOffset, | ||
presentationTimeOffset, | ||
unscaledPresentationTimeOffset, | ||
uris, | ||
@@ -129,4 +129,5 @@ box) { | ||
// Substract the presentationTimeOffset | ||
var unscaledStartTime = earliestPresentationTime - presentationTimeOffset; | ||
// Substract the presentation time offset | ||
var unscaledStartTime = | ||
earliestPresentationTime - unscaledPresentationTimeOffset; | ||
var startByte = sidxOffset + box.size + firstOffset; | ||
@@ -133,0 +134,0 @@ |
@@ -27,2 +27,3 @@ /** | ||
goog.require('shaka.util.StreamUtils'); | ||
goog.require('shaka.util.Timer'); | ||
@@ -86,7 +87,7 @@ | ||
/** @private {?number} */ | ||
this.trickPlayIntervalId_ = null; | ||
/** @private {?shaka.util.Timer} */ | ||
this.trickPlayTimer_ = null; | ||
/** @private {?number} */ | ||
this.gapJumpIntervalId_ = null; | ||
/** @private {?shaka.util.Timer} */ | ||
this.gapJumpTimer_ = null; | ||
@@ -140,3 +141,4 @@ /** @private {number} */ | ||
// See: https://goo.gl/sbSHp9 and https://goo.gl/cuAcYd | ||
this.gapJumpIntervalId_ = setInterval(pollGap, 250); | ||
this.gapJumpTimer_ = new shaka.util.Timer(pollGap); | ||
this.gapJumpTimer_.scheduleRepeated(0.25); | ||
}; | ||
@@ -150,10 +152,10 @@ | ||
if (this.trickPlayIntervalId_ != null) { | ||
window.clearInterval(this.trickPlayIntervalId_); | ||
this.trickPlayIntervalId_ = null; | ||
if (this.trickPlayTimer_ != null) { | ||
this.trickPlayTimer_.cancel(); | ||
this.trickPlayTimer_ = null; | ||
} | ||
if (this.gapJumpIntervalId_ != null) { | ||
window.clearInterval(this.gapJumpIntervalId_); | ||
this.gapJumpIntervalId_ = null; | ||
if (this.gapJumpTimer_ != null) { | ||
this.gapJumpTimer_.cancel(); | ||
this.gapJumpTimer_ = null; | ||
} | ||
@@ -252,5 +254,5 @@ | ||
shaka.media.Playhead.prototype.setPlaybackRate = function(rate) { | ||
if (this.trickPlayIntervalId_ != null) { | ||
window.clearInterval(this.trickPlayIntervalId_); | ||
this.trickPlayIntervalId_ = null; | ||
if (this.trickPlayTimer_ != null) { | ||
this.trickPlayTimer_.cancel(); | ||
this.trickPlayTimer_ = null; | ||
} | ||
@@ -266,5 +268,7 @@ | ||
// called again from setBuffering(). | ||
this.trickPlayIntervalId_ = window.setInterval(function() { | ||
var trickPlay = (function() { | ||
this.video_.currentTime += rate / 4; | ||
}.bind(this), 250); | ||
}.bind(this)); | ||
this.trickPlayTimer_ = new shaka.util.Timer(trickPlay); | ||
this.trickPlayTimer_.scheduleRepeated(0.25); | ||
} | ||
@@ -271,0 +275,0 @@ }; |
@@ -84,3 +84,3 @@ /** | ||
* contains the segments. | ||
* @param {number} presentationTimeOffset | ||
* @param {number} unscaledPresentationTimeOffset | ||
@@ -93,3 +93,3 @@ * @return {!Array.<!shaka.media.SegmentReference>} | ||
shaka.media.WebmSegmentIndexParser.prototype.parse = function( | ||
cuesData, initData, uris, presentationTimeOffset) { | ||
cuesData, initData, uris, unscaledPresentationTimeOffset) { | ||
var tuple = this.parseWebmContainer_(initData); | ||
@@ -108,3 +108,3 @@ var parser = new shaka.util.EbmlParser(new DataView(cuesData)); | ||
cuesElement, tuple.segmentOffset, tuple.timecodeScale, tuple.duration, | ||
uris, presentationTimeOffset); | ||
uris, unscaledPresentationTimeOffset); | ||
}; | ||
@@ -248,3 +248,3 @@ | ||
* @param {!Array.<string>} uris | ||
* @param {number} presentationTimeOffset | ||
* @param {number} unscaledPresentationTimeOffset | ||
* @return {!Array.<!shaka.media.SegmentReference>} | ||
@@ -256,3 +256,3 @@ * @throws {shaka.util.Error} | ||
cuesElement, segmentOffset, timecodeScale, duration, uris, | ||
presentationTimeOffset) { | ||
unscaledPresentationTimeOffset) { | ||
var references = []; | ||
@@ -277,5 +277,5 @@ var getUris = function() { return uris; }; | ||
// Substract presentationTimeOffset from unscalled time | ||
// Substract presentation time offset from unscaled time | ||
var currentTime = timecodeScale * | ||
(tuple.unscaledTime - presentationTimeOffset); | ||
(tuple.unscaledTime - unscaledPresentationTimeOffset); | ||
var currentOffset = segmentOffset + tuple.relativeOffset; | ||
@@ -282,0 +282,0 @@ |
@@ -71,3 +71,3 @@ /** | ||
} else { | ||
shaka.log.warning('The use of stateless text parsers is deprecated.'); | ||
shaka.log.alwaysWarn('The use of stateless text parsers is deprecated.'); | ||
shaka.text.TextEngine.parserMap_[mimeType] = | ||
@@ -74,0 +74,0 @@ shaka.text.TextEngine.TextParserWrapper_.bind(null, plugin); |
@@ -59,1 +59,16 @@ /** | ||
}; | ||
/** | ||
* Schedule the timer, canceling any previous scheduling. Timer will | ||
* automatically reschedule after the callback fires. | ||
* @param {number} seconds | ||
*/ | ||
shaka.util.Timer.prototype.scheduleRepeated = function(seconds) { | ||
this.cancel(); | ||
var repeat = (function() { | ||
this.callback_(); | ||
this.id_ = setTimeout(repeat, seconds * 1000); | ||
}.bind(this)); | ||
this.id_ = setTimeout(repeat, seconds * 1000); | ||
}; |
{ | ||
"name": "shaka-player", | ||
"description": "DASH/EME video player library", | ||
"version": "2.2.4", | ||
"version": "2.2.5", | ||
"homepage": "https://github.com/google/shaka-player", | ||
@@ -6,0 +6,0 @@ "author": "Google", |
@@ -65,4 +65,4 @@ # ![Shaka Player](docs/shaka-player-logo.png) | ||
* [hosted builds on cdnjs](https://cdnjs.com/libraries/shaka-player) | ||
* [mailing list](https://groups.google.com/forum/#!forum/shaka-player-users) | ||
(join for release announcements or to discuss development) | ||
* [announcement list](https://groups.google.com/forum/#!forum/shaka-player-users) | ||
(join for release and survey announcements) | ||
* [hosted API docs](http://shaka-player-demo.appspot.com/docs/api/index.html) | ||
@@ -69,0 +69,0 @@ * [tutorials](http://shaka-player-demo.appspot.com/docs/api/tutorial-welcome.html) |
@@ -186,3 +186,3 @@ /** | ||
' <AdaptationSet mimeType="video/mp4">', | ||
' <SegmentBase presentationTimeOffset="10">', | ||
' <SegmentBase presentationTimeOffset="90000">', | ||
' <Initialization sourceURL="init.mp4" range="201-300" />', | ||
@@ -231,3 +231,4 @@ ' </SegmentBase>', | ||
' <Representation bandwidth="1">', | ||
' <SegmentBase indexRange="30-900" presentationTimeOffset="20" />', | ||
' <SegmentBase indexRange="30-900" ', | ||
' presentationTimeOffset="200" />', | ||
' </Representation>', | ||
@@ -234,0 +235,0 @@ ' </AdaptationSet>', |
@@ -169,3 +169,3 @@ /** | ||
licenseServers: { | ||
'com.widevine.alpha': '//widevine-proxy.appspot.com/proxy' | ||
'com.widevine.alpha': '//proxy.uat.widevine.com/proxy' | ||
}, | ||
@@ -172,0 +172,0 @@ duration: 30 |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
17493278
87244