stormcloud-video-player 0.7.10 → 0.7.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/stormcloud-vp.min.js +1 -1
- package/lib/index.cjs +573 -964
- package/lib/index.cjs.map +1 -1
- package/lib/index.d.cts +20 -29
- package/lib/index.d.ts +20 -29
- package/lib/index.js +574 -965
- package/lib/index.js.map +1 -1
- package/lib/player/StormcloudVideoPlayer.cjs +411 -887
- package/lib/player/StormcloudVideoPlayer.cjs.map +1 -1
- package/lib/player/StormcloudVideoPlayer.d.cts +20 -24
- package/lib/players/HlsPlayer.cjs +411 -887
- package/lib/players/HlsPlayer.cjs.map +1 -1
- package/lib/players/HlsPlayer.d.cts +1 -1
- package/lib/players/index.cjs +411 -887
- package/lib/players/index.cjs.map +1 -1
- package/lib/sdk/adstormPlayer.cjs +9 -1
- package/lib/sdk/adstormPlayer.cjs.map +1 -1
- package/lib/sdk/adstormPlayer.d.cts +1 -1
- package/lib/{types-ClqQZM3U.d.cts → types-DrBGHN4q.d.cts} +2 -7
- package/lib/ui/StormcloudVideoPlayer.cjs +573 -964
- package/lib/ui/StormcloudVideoPlayer.cjs.map +1 -1
- package/lib/ui/StormcloudVideoPlayer.d.cts +1 -1
- package/lib/utils/tracking.d.cts +1 -1
- package/package.json +1 -1
package/lib/index.d.cts
CHANGED
|
@@ -35,12 +35,7 @@ interface StormcloudVideoPlayerConfig {
|
|
|
35
35
|
disableFiller?: boolean;
|
|
36
36
|
adTransitionGapMs?: number;
|
|
37
37
|
singlePipelineMode?: boolean;
|
|
38
|
-
|
|
39
|
-
interface Scte35Marker {
|
|
40
|
-
type: "start" | "end" | "progress";
|
|
41
|
-
ptsSeconds?: number;
|
|
42
|
-
durationSeconds?: number;
|
|
43
|
-
raw?: unknown;
|
|
38
|
+
projectId?: string;
|
|
44
39
|
}
|
|
45
40
|
interface AdController {
|
|
46
41
|
initialize: () => void;
|
|
@@ -130,9 +125,7 @@ declare class StormcloudVideoPlayer {
|
|
|
130
125
|
private currentAdBreakStartWallClockMs;
|
|
131
126
|
private expectedAdBreakDurationMs;
|
|
132
127
|
private adStopTimerId;
|
|
133
|
-
private adStartTimerId;
|
|
134
128
|
private adFailsafeTimerId;
|
|
135
|
-
private ptsDriftEmaMs;
|
|
136
129
|
private adPodQueue;
|
|
137
130
|
private lastHeartbeatTime;
|
|
138
131
|
private heartbeatInterval;
|
|
@@ -155,11 +148,15 @@ declare class StormcloudVideoPlayer {
|
|
|
155
148
|
private isShowingPlaceholder;
|
|
156
149
|
private timeUpdateHandler?;
|
|
157
150
|
private emptiedHandler?;
|
|
151
|
+
private adInsertionPollingId;
|
|
152
|
+
private lastAdInsertionPoint;
|
|
153
|
+
private processedAdInsertionUpdatedAt;
|
|
154
|
+
private adInsertionOffsetTimerId;
|
|
158
155
|
private totalAdRequestsInBreak;
|
|
159
156
|
private readonly maxTotalAdRequestsPerBreak;
|
|
160
157
|
private pendingAdBreak;
|
|
161
158
|
private prefetchTimerId;
|
|
162
|
-
private
|
|
159
|
+
private savedMutedStateBeforeAd;
|
|
163
160
|
private consecutiveFailures;
|
|
164
161
|
private readonly maxConsecutiveFailures;
|
|
165
162
|
private lastAdRequestTime;
|
|
@@ -175,7 +172,7 @@ declare class StormcloudVideoPlayer {
|
|
|
175
172
|
private fillerVideo;
|
|
176
173
|
private fillerBreakTimerId;
|
|
177
174
|
private debugLogEntries;
|
|
178
|
-
private
|
|
175
|
+
private adInsertionDebugHistory;
|
|
179
176
|
constructor(config: StormcloudVideoPlayerConfig);
|
|
180
177
|
private adRequest;
|
|
181
178
|
load(): Promise<void>;
|
|
@@ -188,16 +185,6 @@ declare class StormcloudVideoPlayer {
|
|
|
188
185
|
private stopFillerBreakTimer;
|
|
189
186
|
private attach;
|
|
190
187
|
private shouldUseNativeHls;
|
|
191
|
-
private onId3Tag;
|
|
192
|
-
private parseScte35FromId3;
|
|
193
|
-
private decodeId3ValueToText;
|
|
194
|
-
private onScte35Marker;
|
|
195
|
-
private parseCueOutDuration;
|
|
196
|
-
private parseCueOutCont;
|
|
197
|
-
private parseAttributeList;
|
|
198
|
-
private toNumber;
|
|
199
|
-
private isManifestBasedMarker;
|
|
200
|
-
private parseScte35Binary;
|
|
201
188
|
private initializeTracking;
|
|
202
189
|
private sendHeartbeatIfNeeded;
|
|
203
190
|
getCurrentAdIndex(): number;
|
|
@@ -213,6 +200,12 @@ declare class StormcloudVideoPlayer {
|
|
|
213
200
|
private runAdPrefetch;
|
|
214
201
|
private clearPendingAdBreak;
|
|
215
202
|
private cancelAndClearPreloadedTokens;
|
|
203
|
+
private startAdInsertionPolling;
|
|
204
|
+
private stopAdInsertionPolling;
|
|
205
|
+
private fetchAdInsertionPoint;
|
|
206
|
+
private checkAdInsertionInManifest;
|
|
207
|
+
private fragmentMatchesSegment;
|
|
208
|
+
private clearAdInsertionOffsetTimer;
|
|
216
209
|
private startContinuousFetchLoop;
|
|
217
210
|
private runContinuousFetchLoop;
|
|
218
211
|
private handleAdStart;
|
|
@@ -224,9 +217,6 @@ declare class StormcloudVideoPlayer {
|
|
|
224
217
|
private scheduleAdStopCountdown;
|
|
225
218
|
private clearAdStopTimer;
|
|
226
219
|
private ensureAdStoppedByTimer;
|
|
227
|
-
private scheduleAdStartIn;
|
|
228
|
-
private clearAdStartTimer;
|
|
229
|
-
private updatePtsDrift;
|
|
230
220
|
private handleAdPodComplete;
|
|
231
221
|
private handleAdFailure;
|
|
232
222
|
private startAdRequestWatchdog;
|
|
@@ -235,14 +225,15 @@ declare class StormcloudVideoPlayer {
|
|
|
235
225
|
private clearAdFailsafeTimer;
|
|
236
226
|
private logAdState;
|
|
237
227
|
private getRemainingAdMs;
|
|
238
|
-
private pushScteMarker;
|
|
239
228
|
private pushDebugLog;
|
|
240
|
-
|
|
229
|
+
private pushAdInsertionDebug;
|
|
230
|
+
getAdInsertionDebugLog(): ReadonlyArray<{
|
|
241
231
|
timestampMs: number;
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
232
|
+
event: string;
|
|
233
|
+
segmentName: string;
|
|
234
|
+
offsetSeconds?: number;
|
|
235
|
+
updatedAt?: string;
|
|
236
|
+
detail?: string;
|
|
246
237
|
}>;
|
|
247
238
|
getDebugLogs(): ReadonlyArray<{
|
|
248
239
|
timestampMs: number;
|
package/lib/index.d.ts
CHANGED
|
@@ -35,12 +35,7 @@ interface StormcloudVideoPlayerConfig {
|
|
|
35
35
|
disableFiller?: boolean;
|
|
36
36
|
adTransitionGapMs?: number;
|
|
37
37
|
singlePipelineMode?: boolean;
|
|
38
|
-
|
|
39
|
-
interface Scte35Marker {
|
|
40
|
-
type: "start" | "end" | "progress";
|
|
41
|
-
ptsSeconds?: number;
|
|
42
|
-
durationSeconds?: number;
|
|
43
|
-
raw?: unknown;
|
|
38
|
+
projectId?: string;
|
|
44
39
|
}
|
|
45
40
|
interface AdController {
|
|
46
41
|
initialize: () => void;
|
|
@@ -130,9 +125,7 @@ declare class StormcloudVideoPlayer {
|
|
|
130
125
|
private currentAdBreakStartWallClockMs;
|
|
131
126
|
private expectedAdBreakDurationMs;
|
|
132
127
|
private adStopTimerId;
|
|
133
|
-
private adStartTimerId;
|
|
134
128
|
private adFailsafeTimerId;
|
|
135
|
-
private ptsDriftEmaMs;
|
|
136
129
|
private adPodQueue;
|
|
137
130
|
private lastHeartbeatTime;
|
|
138
131
|
private heartbeatInterval;
|
|
@@ -155,11 +148,15 @@ declare class StormcloudVideoPlayer {
|
|
|
155
148
|
private isShowingPlaceholder;
|
|
156
149
|
private timeUpdateHandler?;
|
|
157
150
|
private emptiedHandler?;
|
|
151
|
+
private adInsertionPollingId;
|
|
152
|
+
private lastAdInsertionPoint;
|
|
153
|
+
private processedAdInsertionUpdatedAt;
|
|
154
|
+
private adInsertionOffsetTimerId;
|
|
158
155
|
private totalAdRequestsInBreak;
|
|
159
156
|
private readonly maxTotalAdRequestsPerBreak;
|
|
160
157
|
private pendingAdBreak;
|
|
161
158
|
private prefetchTimerId;
|
|
162
|
-
private
|
|
159
|
+
private savedMutedStateBeforeAd;
|
|
163
160
|
private consecutiveFailures;
|
|
164
161
|
private readonly maxConsecutiveFailures;
|
|
165
162
|
private lastAdRequestTime;
|
|
@@ -175,7 +172,7 @@ declare class StormcloudVideoPlayer {
|
|
|
175
172
|
private fillerVideo;
|
|
176
173
|
private fillerBreakTimerId;
|
|
177
174
|
private debugLogEntries;
|
|
178
|
-
private
|
|
175
|
+
private adInsertionDebugHistory;
|
|
179
176
|
constructor(config: StormcloudVideoPlayerConfig);
|
|
180
177
|
private adRequest;
|
|
181
178
|
load(): Promise<void>;
|
|
@@ -188,16 +185,6 @@ declare class StormcloudVideoPlayer {
|
|
|
188
185
|
private stopFillerBreakTimer;
|
|
189
186
|
private attach;
|
|
190
187
|
private shouldUseNativeHls;
|
|
191
|
-
private onId3Tag;
|
|
192
|
-
private parseScte35FromId3;
|
|
193
|
-
private decodeId3ValueToText;
|
|
194
|
-
private onScte35Marker;
|
|
195
|
-
private parseCueOutDuration;
|
|
196
|
-
private parseCueOutCont;
|
|
197
|
-
private parseAttributeList;
|
|
198
|
-
private toNumber;
|
|
199
|
-
private isManifestBasedMarker;
|
|
200
|
-
private parseScte35Binary;
|
|
201
188
|
private initializeTracking;
|
|
202
189
|
private sendHeartbeatIfNeeded;
|
|
203
190
|
getCurrentAdIndex(): number;
|
|
@@ -213,6 +200,12 @@ declare class StormcloudVideoPlayer {
|
|
|
213
200
|
private runAdPrefetch;
|
|
214
201
|
private clearPendingAdBreak;
|
|
215
202
|
private cancelAndClearPreloadedTokens;
|
|
203
|
+
private startAdInsertionPolling;
|
|
204
|
+
private stopAdInsertionPolling;
|
|
205
|
+
private fetchAdInsertionPoint;
|
|
206
|
+
private checkAdInsertionInManifest;
|
|
207
|
+
private fragmentMatchesSegment;
|
|
208
|
+
private clearAdInsertionOffsetTimer;
|
|
216
209
|
private startContinuousFetchLoop;
|
|
217
210
|
private runContinuousFetchLoop;
|
|
218
211
|
private handleAdStart;
|
|
@@ -224,9 +217,6 @@ declare class StormcloudVideoPlayer {
|
|
|
224
217
|
private scheduleAdStopCountdown;
|
|
225
218
|
private clearAdStopTimer;
|
|
226
219
|
private ensureAdStoppedByTimer;
|
|
227
|
-
private scheduleAdStartIn;
|
|
228
|
-
private clearAdStartTimer;
|
|
229
|
-
private updatePtsDrift;
|
|
230
220
|
private handleAdPodComplete;
|
|
231
221
|
private handleAdFailure;
|
|
232
222
|
private startAdRequestWatchdog;
|
|
@@ -235,14 +225,15 @@ declare class StormcloudVideoPlayer {
|
|
|
235
225
|
private clearAdFailsafeTimer;
|
|
236
226
|
private logAdState;
|
|
237
227
|
private getRemainingAdMs;
|
|
238
|
-
private pushScteMarker;
|
|
239
228
|
private pushDebugLog;
|
|
240
|
-
|
|
229
|
+
private pushAdInsertionDebug;
|
|
230
|
+
getAdInsertionDebugLog(): ReadonlyArray<{
|
|
241
231
|
timestampMs: number;
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
232
|
+
event: string;
|
|
233
|
+
segmentName: string;
|
|
234
|
+
offsetSeconds?: number;
|
|
235
|
+
updatedAt?: string;
|
|
236
|
+
detail?: string;
|
|
246
237
|
}>;
|
|
247
238
|
getDebugLogs(): ReadonlyArray<{
|
|
248
239
|
timestampMs: number;
|