@vkontakte/videoplayer-core 2.0.162-dev.cd8858cd1.0 → 2.0.162
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 +5 -5
- package/es2015.esm.js +40 -40
- package/esnext.cjs +5 -5
- package/esnext.esm.js +34 -34
- package/evergreen.esm.js +34 -34
- package/package.json +2 -2
- package/types/providers/DashProviderVirtual/lib/buffer/types.d.ts +2 -1
- package/types/providers/DashProviderVirtual/lib/buffer/virtualBuffer/baseVirtualBufferManager.d.ts +4 -3
- package/types/providers/DashProviderVirtual/lib/player/basePlayer.d.ts +2 -1
- package/types/providers/DashProviderVirtual/lib/player/livePlayer.d.ts +1 -1
- package/types/providers/DashProviderVirtual/lib/player/player.d.ts +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vkontakte/videoplayer-core",
|
|
3
|
-
"version": "2.0.162
|
|
3
|
+
"version": "2.0.162",
|
|
4
4
|
"author": "vk.com",
|
|
5
5
|
"description": "Videoplayer core library based on the vk.com platform",
|
|
6
6
|
"homepage": "https://vk.com",
|
|
@@ -42,6 +42,6 @@
|
|
|
42
42
|
"**/*.d.ts"
|
|
43
43
|
],
|
|
44
44
|
"dependencies": {
|
|
45
|
-
"@vkontakte/videoplayer-shared": "1.0.91
|
|
45
|
+
"@vkontakte/videoplayer-shared": "1.0.91"
|
|
46
46
|
}
|
|
47
47
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { Byte, IError, IRange, ISubject, IValueSubject, Milliseconds } from "@vkontakte/videoplayer-shared";
|
|
1
|
+
import type { Byte, IError, IRange, ISubject, ITracer, IValueSubject, Milliseconds } from "@vkontakte/videoplayer-shared";
|
|
2
2
|
import type { CommonInit, Manifest, Representation, Segment } from "../../../utils/parsers/types";
|
|
3
3
|
import type { Fetcher } from "../fetcher";
|
|
4
4
|
import type { ITuningConfig } from "../../../../utils/tuningConfig";
|
|
@@ -11,6 +11,7 @@ export declare enum SwithRepresentationMode {
|
|
|
11
11
|
}
|
|
12
12
|
export interface Dependencies {
|
|
13
13
|
fetcher: Fetcher;
|
|
14
|
+
tracer: ITracer;
|
|
14
15
|
tuning: ITuningConfig;
|
|
15
16
|
compatibilityMode?: boolean;
|
|
16
17
|
manifest: Manifest | null;
|
package/types/providers/DashProviderVirtual/lib/buffer/virtualBuffer/baseVirtualBufferManager.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import type { Fetcher, FetchParamsWithUrl, Priority, RepresentationFetchResult }
|
|
|
2
2
|
import type { CommonInit, ContainerParser, Representation, Segment } from "../../../../utils/parsers/types";
|
|
3
3
|
import { StreamKind } from "../../../../utils/parsers/types";
|
|
4
4
|
import type { ITuningConfig } from "../../../../../utils/tuningConfig";
|
|
5
|
-
import type { Byte, IError, IRange, ISubject, IValueSubject, Milliseconds, Seconds } from "@vkontakte/videoplayer-shared";
|
|
5
|
+
import type { Byte, IError, IRange, ISubject, ITracer, IValueSubject, Milliseconds, Seconds } from "@vkontakte/videoplayer-shared";
|
|
6
6
|
import { abortable, Subscription } from "@vkontakte/videoplayer-shared";
|
|
7
7
|
import type { NativeBufferManager } from "../nativeBufferManager";
|
|
8
8
|
import { SwithRepresentationMode, type Dependencies, type IBufferPlaybackQueueItem, type ISomeDataLoadedCallbackParams, type IVirtualBufferManager } from "../types";
|
|
@@ -17,6 +17,7 @@ export declare abstract class BaseVirtualBufferManager<T extends Segment> implem
|
|
|
17
17
|
protected readonly kind: StreamKind;
|
|
18
18
|
protected readonly nativeBufferManager: NativeBufferManager;
|
|
19
19
|
protected readonly fetcher: Fetcher;
|
|
20
|
+
protected readonly tracer: ITracer;
|
|
20
21
|
protected readonly tuning: ITuningConfig;
|
|
21
22
|
protected representations: Map<Representation["id"], Representation>;
|
|
22
23
|
protected playingRepresentationId: Representation["id"] | undefined;
|
|
@@ -51,7 +52,7 @@ export declare abstract class BaseVirtualBufferManager<T extends Segment> implem
|
|
|
51
52
|
protected subscription: Subscription;
|
|
52
53
|
protected readonly getCurrentPosition: () => Milliseconds | undefined;
|
|
53
54
|
protected readonly getCurrentStallDuration: () => Milliseconds | undefined;
|
|
54
|
-
protected constructor(kind: StreamKind, nativeBufferManager: NativeBufferManager, representations: Representation[], { fetcher, tuning, getCurrentPosition, getCurrentStallDuration, manifest }: Dependencies);
|
|
55
|
+
protected constructor(kind: StreamKind, nativeBufferManager: NativeBufferManager, representations: Representation[], { fetcher, tracer, tuning, getCurrentPosition, getCurrentStallDuration, manifest }: Dependencies);
|
|
55
56
|
protected abstract loadItems(itemsToLoad: IBufferPlaybackQueueItem<T>[], representation: Representation, priority?: Priority): Promise<void>;
|
|
56
57
|
protected abstract selectItemsToLoad(): IBufferPlaybackQueueItem<T>[];
|
|
57
58
|
protected abstract prepareFetchParams(items: IBufferPlaybackQueueItem<T>[], representation: Representation): FetchParamsWithUrl;
|
|
@@ -59,7 +60,7 @@ export declare abstract class BaseVirtualBufferManager<T extends Segment> implem
|
|
|
59
60
|
protected abstract updateRepresentationBaseUrl(representation: Representation, newBaseUrl: string): void;
|
|
60
61
|
startWith: ReturnType<typeof abortable<[Representation["id"]]>>;
|
|
61
62
|
switchTo(newRepresentationId: Representation["id"], mode?: SwithRepresentationMode): Promise<void>;
|
|
62
|
-
protected getSwitchWithAbort(): ReturnType<typeof abortable<[Representation["id"], SwithRepresentationMode], void>>;
|
|
63
|
+
protected getSwitchWithAbort(switchToTracer: ITracer): ReturnType<typeof abortable<[Representation["id"], SwithRepresentationMode], void>>;
|
|
63
64
|
prepareSeek(): Promise<void>;
|
|
64
65
|
seek(position: Milliseconds | undefined): Promise<void>;
|
|
65
66
|
maintain(currentPosition?: Milliseconds | undefined): Promise<void>;
|
|
@@ -20,6 +20,7 @@ export declare abstract class BasePlayer {
|
|
|
20
20
|
protected manifest: Manifest | null;
|
|
21
21
|
protected tuning: ITuningConfig;
|
|
22
22
|
protected tracer: ITracer;
|
|
23
|
+
protected stallTracer: ITracer;
|
|
23
24
|
protected forceVideoCodec?: VideoCodec;
|
|
24
25
|
protected stallTimeInWaitingExitAttemptMade: Milliseconds;
|
|
25
26
|
protected videoBufferManager: IVirtualBufferManager | null;
|
|
@@ -77,7 +78,7 @@ export declare abstract class BasePlayer {
|
|
|
77
78
|
protected constructor(params: Params);
|
|
78
79
|
protected abstract prepareManifestUrlString(manifestBaseUrlString: string, offset: number): string;
|
|
79
80
|
protected abstract setSourceInitDuration(): void;
|
|
80
|
-
protected abstract restoreAfterDeepStall(
|
|
81
|
+
protected abstract restoreAfterDeepStall(): Promise<void>;
|
|
81
82
|
initRepresentations: ReturnType<typeof abortable<[Representation["id"], Representation["id"] | undefined, IHLSSource | undefined]>>;
|
|
82
83
|
initManifest(element: HTMLVideoElement, manifestBaseUrlString: string, offset: number): Promise<void>;
|
|
83
84
|
initBuffer(): void;
|
|
@@ -20,7 +20,7 @@ export declare class LivePlayer extends BasePlayer {
|
|
|
20
20
|
protected tick(): Promise<void>;
|
|
21
21
|
protected setSourceInitDuration(): void;
|
|
22
22
|
protected isStallExceeded(timeInWaiting: Milliseconds): boolean;
|
|
23
|
-
protected restoreAfterDeepStall(
|
|
23
|
+
protected restoreAfterDeepStall(): Promise<void>;
|
|
24
24
|
protected updateManifest(): Promise<Manifest | null>;
|
|
25
25
|
protected prepareManifestUrlString(manifestBaseUrlString: string, offset: number): string;
|
|
26
26
|
protected updateManifestUrlWithTimeOffset(nextOffset: Milliseconds): void;
|
|
@@ -5,7 +5,7 @@ export declare class Player extends BasePlayer {
|
|
|
5
5
|
protected prepareManifestUrlString(manifestBaseUrlString: string, _offset: number): string;
|
|
6
6
|
protected initRepresentationSubscriptions(): void;
|
|
7
7
|
protected setSourceInitDuration(): void;
|
|
8
|
-
protected restoreAfterDeepStall(
|
|
8
|
+
protected restoreAfterDeepStall(): Promise<void>;
|
|
9
9
|
protected initDisableStallWatchdogSubscription(): void;
|
|
10
10
|
protected initEndOfVideoSubscription(): void;
|
|
11
11
|
}
|