@vkontakte/videoplayer-core 2.0.174 → 2.0.175
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/es2015.cjs +6 -6
- package/es2015.esm.js +17 -17
- package/esnext.cjs +6 -6
- package/esnext.esm.js +9 -9
- package/evergreen.esm.js +9 -9
- package/package.json +2 -2
- package/types/providers/DashProviderVirtual/lib/buffer/types.d.ts +1 -0
- package/types/providers/DashProviderVirtual/lib/buffer/virtualBuffer/baseVirtualBufferManager.d.ts +5 -1
- package/types/providers/DashProviderVirtual/lib/player/basePlayer.d.ts +2 -1
- package/types/utils/tuningConfig.d.ts +9 -17
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vkontakte/videoplayer-core",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.175",
|
|
4
4
|
"author": "vk.ru",
|
|
5
5
|
"description": "Videoplayer core library based on the vk.ru platform",
|
|
6
6
|
"homepage": "https://vk.ru",
|
|
@@ -42,6 +42,6 @@
|
|
|
42
42
|
"**/*.d.ts"
|
|
43
43
|
],
|
|
44
44
|
"dependencies": {
|
|
45
|
-
"@vkontakte/videoplayer-shared": "1.0.
|
|
45
|
+
"@vkontakte/videoplayer-shared": "1.0.104"
|
|
46
46
|
}
|
|
47
47
|
}
|
|
@@ -40,6 +40,7 @@ export interface IVirtualBufferManager<T extends Segment = Segment> {
|
|
|
40
40
|
calculateDurationFromSegments(): Milliseconds;
|
|
41
41
|
getActiveSegmentProgress(): VideoSegmentLoadProgress | undefined;
|
|
42
42
|
getMpdSegmentDuration(): Milliseconds | undefined;
|
|
43
|
+
getGaps(): IRange<Milliseconds>[];
|
|
43
44
|
destroy(): void;
|
|
44
45
|
get lastDataObtainedTimestamp(): Milliseconds;
|
|
45
46
|
}
|
package/types/providers/DashProviderVirtual/lib/buffer/virtualBuffer/baseVirtualBufferManager.d.ts
CHANGED
|
@@ -29,6 +29,7 @@ export declare abstract class BaseVirtualBufferManager<T extends Segment> implem
|
|
|
29
29
|
protected parsedInitData: Map<Representation["id"], CommonInit>;
|
|
30
30
|
protected forwardBufferRepresentations: Map<Representation["id"], T[]>;
|
|
31
31
|
protected segments: Map<Representation["id"], T[]>;
|
|
32
|
+
protected gaps: IRange<Milliseconds>[];
|
|
32
33
|
protected containerParser: ContainerParser;
|
|
33
34
|
protected bufferPlaybackQueue: IBufferPlaybackQueueItem<T>[];
|
|
34
35
|
protected downloadingBufferItems: IBufferPlaybackQueueItem<T>[];
|
|
@@ -75,6 +76,8 @@ export declare abstract class BaseVirtualBufferManager<T extends Segment> implem
|
|
|
75
76
|
getActiveSegmentProgress(): VideoSegmentLoadProgress | undefined;
|
|
76
77
|
getMpdSegmentDuration(): Milliseconds | undefined;
|
|
77
78
|
get lastDataObtainedTimestamp(): Milliseconds;
|
|
79
|
+
getGaps(): IRange<Milliseconds>[];
|
|
80
|
+
protected searchGaps(): void;
|
|
78
81
|
setTarget(time: Milliseconds): void;
|
|
79
82
|
setPreloadOnly(preloadOnly: boolean): void;
|
|
80
83
|
destroy(): void;
|
|
@@ -105,7 +108,8 @@ export declare abstract class BaseVirtualBufferManager<T extends Segment> implem
|
|
|
105
108
|
protected loadInits(): Promise<void>;
|
|
106
109
|
protected loadInitIfNeeded(representation: Representation, requestedPriority?: Priority, critical?: boolean): Promise<void>;
|
|
107
110
|
protected loadInit(representation: Representation, requestedPriority?: Priority, critical?: boolean): Promise<void>;
|
|
108
|
-
private
|
|
111
|
+
private lockForNativeOps;
|
|
112
|
+
private lockForSwitchInit;
|
|
109
113
|
protected maintainNativeBuffer(signal: AbortSignal): Promise<void>;
|
|
110
114
|
protected maintainPlaybackBuffer(position: Milliseconds): Promise<void>;
|
|
111
115
|
protected actualizeLastSegmentInfo(currentPosition: Milliseconds): void;
|
|
@@ -23,7 +23,6 @@ export declare abstract class BasePlayer {
|
|
|
23
23
|
protected stallTracer: ITracer | null;
|
|
24
24
|
protected forceVideoCodec?: VideoCodec;
|
|
25
25
|
protected stallStartTime: Milliseconds | null;
|
|
26
|
-
protected lastForceSeekTimestamp: Milliseconds | null;
|
|
27
26
|
protected videoBufferManager: IVirtualBufferManager | null;
|
|
28
27
|
protected audioBufferManager: IVirtualBufferManager | null;
|
|
29
28
|
protected bufferManagers: IVirtualBufferManager[];
|
|
@@ -117,4 +116,6 @@ export declare abstract class BasePlayer {
|
|
|
117
116
|
protected initBufferLengthSubscription(): void;
|
|
118
117
|
protected initTracerSubscription(): void;
|
|
119
118
|
protected tick(): Promise<void>;
|
|
119
|
+
private jumpToMaxBufferStartIfNeeded;
|
|
120
|
+
private collectGapEndsContaining;
|
|
120
121
|
}
|
|
@@ -209,12 +209,12 @@ export type ITuningConfig = {
|
|
|
209
209
|
usePersistentGaps: boolean;
|
|
210
210
|
abrThrottle: number;
|
|
211
211
|
useVideoElementWaitingCurrentTimeReassign: boolean;
|
|
212
|
-
useVideoElementProgressCurrentTimeReassign: boolean;
|
|
213
212
|
stallWatchdogInterval: Milliseconds;
|
|
214
213
|
liveUpdateInterval: Milliseconds;
|
|
215
214
|
liveStallReinitInterval: Milliseconds;
|
|
216
215
|
ignoreNetworkErrorsOnLoadInit: boolean;
|
|
217
216
|
bufferTolerance: Milliseconds;
|
|
217
|
+
useBufferGapWatchdog: boolean;
|
|
218
218
|
minNativeBufferSize: Milliseconds;
|
|
219
219
|
removeTimeShiftFromSegment: Milliseconds;
|
|
220
220
|
tickMaintainInterval: Milliseconds;
|
|
@@ -262,22 +262,6 @@ export type ITuningConfig = {
|
|
|
262
262
|
/** Включает отправку телеметрии трейсера (resume) при выборе ABR качества не выше lowQualityTelemetryLimit */
|
|
263
263
|
tracerResumeOnLowQuality: boolean;
|
|
264
264
|
/**
|
|
265
|
-
* Эксперимент: при `true` отключает `await this.reinitDecoderIfNeeded(shouldForceSeek)`
|
|
266
|
-
* внутри `stallWatchdogIntervalCallback`. По умолчанию `false` — текущее поведение
|
|
267
|
-
* (force-seek раз в секунду при глубоком stall). Гипотеза: возможно, force-seek из
|
|
268
|
-
* watchdog'а сам по себе тормозит восстановление на длинных столлах (аналог B1,
|
|
269
|
-
* но через полное отключение reinit, а не троттлинг частоты).
|
|
270
|
-
*/
|
|
271
|
-
disableStallWatchdogReinitDecoder: boolean;
|
|
272
|
-
/**
|
|
273
|
-
* Эксперимент: при `destroy()` резолвить callback'и `currentTask` и всех задач в очереди,
|
|
274
|
-
* чтобы их промисы (`await this.queue.append(...)`, `await this.queue.remove(...)`) не висели
|
|
275
|
-
* вечно после разрушения очереди. По умолчанию `false` — поведение как до эксперимента:
|
|
276
|
-
* `queue = []; currentTask = null` без вызова callback'ов, промисы зависают (pre-existing behaviour).
|
|
277
|
-
* Включать поэтапно, начиная с процента трафика, для A/B по метрикам утечек и восстановления.
|
|
278
|
-
*/
|
|
279
|
-
resolveQueueOnDestroy: boolean;
|
|
280
|
-
/**
|
|
281
265
|
* Освобождает застрявшую загрузку сегментов в `DashProvider`: запись из `activeSegments`,
|
|
282
266
|
* когда её загрузчик закончил работу или когда `warmUpMediaSource()` переоткрыл
|
|
283
267
|
* `mediaSource`, и колбэки задач `sourceBufferTaskQueue`, когда очередь разрушается
|
|
@@ -294,6 +278,13 @@ export type ITuningConfig = {
|
|
|
294
278
|
* дешевле замершего воспроизведения.
|
|
295
279
|
*/
|
|
296
280
|
recoverStuckSegmentLoading: boolean;
|
|
281
|
+
/**
|
|
282
|
+
* UVP-11760: в `maintainNativeBuffer` не учитывать `switchMutex` при early-return, чтобы
|
|
283
|
+
* pre-buffered сегменты могли скармливаться в MSE пока `switchTo` висит на `loadInit`.
|
|
284
|
+
* При `false` (по умолчанию) — поведение до фикса: `switchMutex` блокирует `maintainNativeBuffer`.
|
|
285
|
+
* При `true` — эксперимент: `switchMutex` не блокирует `maintainNativeBuffer`.
|
|
286
|
+
*/
|
|
287
|
+
enableMaintainNativeBufferSwitchMutexBypass: boolean;
|
|
297
288
|
};
|
|
298
289
|
dashCmafLive: {
|
|
299
290
|
externalStopControl: boolean;
|
|
@@ -404,6 +395,7 @@ export type ITuningConfig = {
|
|
|
404
395
|
useDashLiveProviderVirtual: boolean;
|
|
405
396
|
useDashLiveProviderVirtualMobile: boolean;
|
|
406
397
|
useSafariEndlessRequestBugfix: boolean;
|
|
398
|
+
useAbortableGeneratorReturnOnAbort: boolean;
|
|
407
399
|
/**
|
|
408
400
|
* Ручка для фикса сброса playbackRate при перемотке live-трансляции на Safari.
|
|
409
401
|
*
|