@vkontakte/videoplayer-core 2.0.129-dev.90163d61.0 → 2.0.129-dev.91760fac.0
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.js +10 -66
- package/es2015.esm.js +10 -66
- package/es2018.cjs.js +9 -65
- package/es2018.esm.js +9 -65
- package/esnext.cjs.js +9 -65
- package/esnext.esm.js +9 -65
- package/evergreen.esm.js +8 -64
- package/package.json +2 -2
- package/types/player/Player.d.ts +2 -9
- package/types/player/types.d.ts +0 -5
- package/types/providers/ChromecastProvider/ChromecastInitializer/index.d.ts +1 -5
- package/types/providers/ChromecastProvider/index.d.ts +0 -2
- package/types/providers/DashLiveProvider/DashLiveProvider.d.ts +0 -1
- package/types/providers/DashLiveProvider/utils/FilesFetcher.d.ts +1 -2
- package/types/providers/DashLiveProvider/utils/LiveDashPlayer.d.ts +0 -1
- package/types/providers/DashLiveProvider/utils/ThroughputEstimator.d.ts +0 -4
- package/types/providers/DashProvider/baseDashProvider.d.ts +2 -2
- package/types/providers/DashProvider/lib/buffer.d.ts +2 -1
- package/types/providers/DashProvider/lib/fetcher.d.ts +3 -4
- package/types/providers/DashProvider/lib/player.d.ts +2 -4
- package/types/providers/ProviderContainer/index.d.ts +0 -2
- package/types/providers/WebRTCLiveProvider/WebRTCLiveProvider.d.ts +0 -1
- package/types/providers/types.d.ts +1 -4
- package/types/providers/utils/HTMLVideoElement/DroppedFramesManager.d.ts +1 -3
- package/types/providers/utils/HTMLVideoElement/observable.d.ts +2 -0
- package/types/utils/autoSelectTrack.d.ts +3 -4
- package/types/utils/smoothedValue/baseSmoothedValue.d.ts +0 -3
- package/types/utils/tuningConfig.d.ts +3 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vkontakte/videoplayer-core",
|
|
3
|
-
"version": "2.0.129-dev.
|
|
3
|
+
"version": "2.0.129-dev.91760fac.0",
|
|
4
4
|
"author": "vk.com",
|
|
5
5
|
"description": "Videoplayer core library based on the vk.com platform",
|
|
6
6
|
"homepage": "https://vk.com",
|
|
@@ -49,7 +49,7 @@
|
|
|
49
49
|
"**/*.d.ts"
|
|
50
50
|
],
|
|
51
51
|
"dependencies": {
|
|
52
|
-
"@vkontakte/videoplayer-shared": "
|
|
52
|
+
"@vkontakte/videoplayer-shared": "1.0.57-dev.71da56af.0",
|
|
53
53
|
"hls.js": "~1.4.7"
|
|
54
54
|
}
|
|
55
55
|
}
|
package/types/player/Player.d.ts
CHANGED
|
@@ -1,14 +1,11 @@
|
|
|
1
1
|
import { IOptionalTuningConfig } from '../utils/tuningConfig';
|
|
2
|
-
import { IError, ILogEntry, Seconds, Subject, ValueSubject, QualityLimits, VideoQuality
|
|
2
|
+
import { IError, ILogEntry, Seconds, Subject, ValueSubject, QualityLimits, VideoQuality } from '@vkontakte/videoplayer-shared';
|
|
3
3
|
import { ChromecastState, HttpConnectionType, IAudioStream, IConfig, ICueSettings, IExternalTextTrack, IPlayer, ISeekRequest, ISources, ITextTrack, IVideoStream, PlaybackRate, PlaybackState, PredefinedQualityLimits, StartEnd, Surface, VideoFormat } from './types';
|
|
4
4
|
export default class Player implements IPlayer {
|
|
5
5
|
private subscription;
|
|
6
6
|
private domContainer;
|
|
7
7
|
private providerContainer?;
|
|
8
8
|
private chromecastInitializer;
|
|
9
|
-
private logger;
|
|
10
|
-
private tracer;
|
|
11
|
-
private abrLogger;
|
|
12
9
|
private config;
|
|
13
10
|
private tuning;
|
|
14
11
|
private throughputEstimator;
|
|
@@ -109,10 +106,9 @@ export default class Player implements IPlayer {
|
|
|
109
106
|
element$: ValueSubject<HTMLVideoElement | undefined>;
|
|
110
107
|
tuningConfigName$: ValueSubject<string[]>;
|
|
111
108
|
enableDebugTelemetry$: ValueSubject<boolean>;
|
|
112
|
-
dumpTelemetry: (receiver: (value: Record<string, any>) => void) => void;
|
|
113
109
|
getCurrentTime$: ValueSubject<null>;
|
|
114
110
|
};
|
|
115
|
-
constructor(tuning?: IOptionalTuningConfig
|
|
111
|
+
constructor(tuning?: IOptionalTuningConfig);
|
|
116
112
|
initVideo(config: IConfig): IPlayer;
|
|
117
113
|
destroy(): void;
|
|
118
114
|
prepare(): IPlayer;
|
|
@@ -179,7 +175,6 @@ export default class Player implements IPlayer {
|
|
|
179
175
|
*/
|
|
180
176
|
releaseCamera(): this;
|
|
181
177
|
getExactTime(): Seconds;
|
|
182
|
-
getAllLogs(): ILogEntry[];
|
|
183
178
|
private getScene3D;
|
|
184
179
|
private setIntrinsicVideoSize;
|
|
185
180
|
private initDesiredStateSubscriptions;
|
|
@@ -187,9 +182,7 @@ export default class Player implements IPlayer {
|
|
|
187
182
|
private initChromecastSubscription;
|
|
188
183
|
private initStartingVideoTrack;
|
|
189
184
|
private setStartingVideoTrack;
|
|
190
|
-
private initLogs;
|
|
191
185
|
private initDebugTelemetry;
|
|
192
|
-
private initTracerSubscription;
|
|
193
186
|
private initWakeLock;
|
|
194
187
|
private setVideoTrackIdByQuality;
|
|
195
188
|
private getActiveLiveDelay;
|
package/types/player/types.d.ts
CHANGED
|
@@ -62,10 +62,6 @@ export interface IPlayer {
|
|
|
62
62
|
* Может быть точнее, чем `info.position$` в промежутках между timeupdate
|
|
63
63
|
*/
|
|
64
64
|
getExactTime(): number;
|
|
65
|
-
/**
|
|
66
|
-
* Возвращает все логи с момента инициализации плеера
|
|
67
|
-
*/
|
|
68
|
-
getAllLogs(): ILogEntry[];
|
|
69
65
|
experimental: {
|
|
70
66
|
/**
|
|
71
67
|
* Элемент, который сейчас вставлен в container.
|
|
@@ -74,7 +70,6 @@ export interface IPlayer {
|
|
|
74
70
|
element$: IValueObservable<HTMLVideoElement | undefined>;
|
|
75
71
|
tuningConfigName$: IValueSubject<string[]>;
|
|
76
72
|
enableDebugTelemetry$: IValueSubject<boolean>;
|
|
77
|
-
dumpTelemetry: (receiver: (value: Record<string, any>) => void) => void;
|
|
78
73
|
/** функция вычисления текущей позиции проигрывания из под провадера (если расчет нестандартный) */
|
|
79
74
|
getCurrentTime$: IValueSubject<(() => number) | null>;
|
|
80
75
|
};
|
|
@@ -1,12 +1,9 @@
|
|
|
1
|
-
import { ISubject, IValueSubject,
|
|
1
|
+
import { ISubject, IValueSubject, IError } from '@vkontakte/videoplayer-shared';
|
|
2
2
|
import { ChromecastState } from '../../../player/types';
|
|
3
3
|
import { IChromecastConnection, IChromecastInitializer } from './types';
|
|
4
4
|
interface IParams {
|
|
5
5
|
receiverApplicationId?: string;
|
|
6
6
|
isDisabled?: boolean;
|
|
7
|
-
dependencies: {
|
|
8
|
-
logger: ILogger;
|
|
9
|
-
};
|
|
10
7
|
}
|
|
11
8
|
export declare class ChromecastInitializer implements IChromecastInitializer {
|
|
12
9
|
readonly connection$: IValueSubject<IChromecastConnection | undefined>;
|
|
@@ -15,7 +12,6 @@ export declare class ChromecastInitializer implements IChromecastInitializer {
|
|
|
15
12
|
contentId?: string;
|
|
16
13
|
private readonly realCastState$;
|
|
17
14
|
private readonly subscription;
|
|
18
|
-
private readonly log;
|
|
19
15
|
private readonly params;
|
|
20
16
|
private isDestroyed;
|
|
21
17
|
constructor(params: IParams);
|
|
@@ -11,7 +11,6 @@ export default class ChromecastProvider implements IProvider {
|
|
|
11
11
|
private loadMediaTimeoutSubscription;
|
|
12
12
|
private videoState;
|
|
13
13
|
private params;
|
|
14
|
-
private log;
|
|
15
14
|
constructor(params: IParams);
|
|
16
15
|
destroy(): void;
|
|
17
16
|
private subscribe;
|
|
@@ -27,7 +26,6 @@ export default class ChromecastProvider implements IProvider {
|
|
|
27
26
|
private createMediaInfo;
|
|
28
27
|
private createLoadRequest;
|
|
29
28
|
private loadMedia;
|
|
30
|
-
private logRemoteEvent;
|
|
31
29
|
private syncPlayback;
|
|
32
30
|
}
|
|
33
31
|
export {};
|
|
@@ -9,8 +9,7 @@ export default class FilesFetcher {
|
|
|
9
9
|
private TIMEOUT;
|
|
10
10
|
private BITRATE_ESTIMATOR;
|
|
11
11
|
private MAX_PARALLEL_REQUESTS;
|
|
12
|
-
|
|
13
|
-
constructor(RETRY_COUNT: number, TIMEOUT: number, BITRATE_ESTIMATOR: any, MAX_PARALLEL_REQUESTS: number, logger: (...args: any[]) => void);
|
|
12
|
+
constructor(RETRY_COUNT: number, TIMEOUT: number, BITRATE_ESTIMATOR: any, MAX_PARALLEL_REQUESTS: number);
|
|
14
13
|
private limitCompleteCount;
|
|
15
14
|
private _sendRequest;
|
|
16
15
|
private _getParallelRequestCount;
|
|
@@ -15,12 +15,9 @@
|
|
|
15
15
|
* active time = (1.1 - 1.0) + (0.5 - 0.2) = 0.4
|
|
16
16
|
* throughput = total size / active time = 6500 bytes/sec
|
|
17
17
|
*/
|
|
18
|
-
type ILogger = (...args: any[]) => void;
|
|
19
18
|
export default class ThroughputEstimator {
|
|
20
19
|
private intervals;
|
|
21
20
|
private currentRate;
|
|
22
|
-
private logger;
|
|
23
|
-
constructor(logger: ILogger);
|
|
24
21
|
private _updateRate;
|
|
25
22
|
private _createInterval;
|
|
26
23
|
private _doMergeIntervals;
|
|
@@ -30,4 +27,3 @@ export default class ThroughputEstimator {
|
|
|
30
27
|
addInterval(timeStart: number, timeEnd: number, bytes: number): boolean;
|
|
31
28
|
getBitRate(): number;
|
|
32
29
|
}
|
|
33
|
-
export {};
|
|
@@ -3,7 +3,7 @@ import { CommonInit, IProviderSubscriptionInfo, ProviderState, Representation, S
|
|
|
3
3
|
import { IProvider, IProviderParams } from '../../providers/types';
|
|
4
4
|
import { TrackHistory } from '../../utils/autoSelectTrack';
|
|
5
5
|
import { IStateMachine } from '../../utils/StateMachine/types';
|
|
6
|
-
import { ISubscription,
|
|
6
|
+
import { ISubscription, Milliseconds } from '@vkontakte/videoplayer-shared';
|
|
7
7
|
import { Player } from './lib/player';
|
|
8
8
|
import { Scene3D } from '../../utils/3d/Scene3D';
|
|
9
9
|
import DroppedFramesManager from '../../providers/utils/HTMLVideoElement/DroppedFramesManager';
|
|
@@ -20,7 +20,6 @@ export default abstract class BaseDashProvider implements IProvider {
|
|
|
20
20
|
protected video: HTMLVideoElement;
|
|
21
21
|
protected player: Player;
|
|
22
22
|
protected params: IParams;
|
|
23
|
-
protected tracer: ITracer;
|
|
24
23
|
protected textTracksManager: TextTrackManager;
|
|
25
24
|
protected droppedFramesManager: DroppedFramesManager;
|
|
26
25
|
protected stallsManager: StallsManager;
|
|
@@ -51,6 +50,7 @@ export default abstract class BaseDashProvider implements IProvider {
|
|
|
51
50
|
protected init3DScene: (init: CommonInit) => void;
|
|
52
51
|
protected destroy3DScene: () => void;
|
|
53
52
|
protected playIfAllowed(): void;
|
|
53
|
+
private getStreamById;
|
|
54
54
|
destroy(): void;
|
|
55
55
|
}
|
|
56
56
|
export {};
|
|
@@ -108,7 +108,8 @@ export declare class BufferManager {
|
|
|
108
108
|
private pruneBuffer;
|
|
109
109
|
private abortBuffer;
|
|
110
110
|
getDebugBufferState(): IRange<Milliseconds> | undefined;
|
|
111
|
-
|
|
111
|
+
getBufferedTo(): number | null;
|
|
112
|
+
getForwardBufferDuration(currentPosition?: Milliseconds | undefined): Milliseconds;
|
|
112
113
|
private detectGaps;
|
|
113
114
|
private detectGapsWhenIdle;
|
|
114
115
|
private checkEjectedSegments;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { HttpConnectionType } from '../../../player/types';
|
|
2
2
|
import type ThroughputEstimator from '../../../utils/ThroughputEstimator';
|
|
3
|
-
import { Byte, IValueSubject, Milliseconds, IRange, Subject,
|
|
3
|
+
import { Byte, IValueSubject, Milliseconds, IRange, Subject, IError } from '@vkontakte/videoplayer-shared';
|
|
4
4
|
import { CommonInit, GenericContainerParser, Segment, SegmentReference } from './types';
|
|
5
5
|
export declare enum RangeMethod {
|
|
6
6
|
HEADER = 0,
|
|
@@ -10,7 +10,6 @@ export interface IParams {
|
|
|
10
10
|
throughputEstimator?: ThroughputEstimator;
|
|
11
11
|
requestQuic: boolean;
|
|
12
12
|
compatibilityMode?: boolean;
|
|
13
|
-
tracer: ITracer;
|
|
14
13
|
useEnableSubtitlesParam?: boolean;
|
|
15
14
|
}
|
|
16
15
|
export type Priority = 'high' | 'low' | 'auto';
|
|
@@ -35,7 +34,6 @@ export type RepresentationFetchResult = {
|
|
|
35
34
|
export declare class Fetcher {
|
|
36
35
|
private throughputEstimator;
|
|
37
36
|
private requestQuic;
|
|
38
|
-
private tracer;
|
|
39
37
|
lastConnectionType$: IValueSubject<HttpConnectionType | undefined>;
|
|
40
38
|
lastConnectionReused$: IValueSubject<boolean | undefined>;
|
|
41
39
|
lastRequestFirstBytes$: IValueSubject<Milliseconds | undefined>;
|
|
@@ -45,7 +43,8 @@ export declare class Fetcher {
|
|
|
45
43
|
private subscription;
|
|
46
44
|
private compatibilityMode;
|
|
47
45
|
private useEnableSubtitlesParam;
|
|
48
|
-
|
|
46
|
+
private readonly abortSubscriptionSet;
|
|
47
|
+
constructor({ throughputEstimator, requestQuic, compatibilityMode, useEnableSubtitlesParam }: IParams);
|
|
49
48
|
private onHeadersReceived;
|
|
50
49
|
fetchManifest: (param_0: string) => Promise<string | null | undefined>;
|
|
51
50
|
fetch: (param_0: string, param_1: FetchParams) => Promise<ArrayBuffer | null | undefined>;
|
|
@@ -3,7 +3,7 @@ import { CommonInit, LiveStreamStatus, Manifest, Representation, StreamKind, Tex
|
|
|
3
3
|
import StateMachine from '../../../utils/StateMachine/StateMachine';
|
|
4
4
|
import type ThroughputEstimator from '../../../utils/ThroughputEstimator';
|
|
5
5
|
import { ITuningConfig } from '../../../utils/tuningConfig';
|
|
6
|
-
import { IError, ISubject,
|
|
6
|
+
import { IError, ISubject, IValueSubject, Milliseconds, Subject } from '@vkontakte/videoplayer-shared';
|
|
7
7
|
export declare enum State {
|
|
8
8
|
NONE = "none",
|
|
9
9
|
MANIFEST_READY = "manifest_ready",
|
|
@@ -14,7 +14,6 @@ export interface Params {
|
|
|
14
14
|
throughputEstimator: ThroughputEstimator;
|
|
15
15
|
tuning: ITuningConfig;
|
|
16
16
|
compatibilityMode?: boolean;
|
|
17
|
-
tracer: ITracer;
|
|
18
17
|
}
|
|
19
18
|
export declare class Player {
|
|
20
19
|
private element;
|
|
@@ -22,7 +21,6 @@ export declare class Player {
|
|
|
22
21
|
private source;
|
|
23
22
|
private manifest;
|
|
24
23
|
private tuning;
|
|
25
|
-
private tracer;
|
|
26
24
|
private videoBufferManager;
|
|
27
25
|
private audioBufferManager;
|
|
28
26
|
private bufferManagers;
|
|
@@ -42,6 +40,7 @@ export declare class Player {
|
|
|
42
40
|
lastConnectionReused$: IValueSubject<boolean | undefined>;
|
|
43
41
|
lastRequestFirstBytes$: IValueSubject<Milliseconds | undefined>;
|
|
44
42
|
currentLiveTextRepresentation$: IValueSubject<TextRepresentation | null>;
|
|
43
|
+
private timeoutSourceOpenId;
|
|
45
44
|
isLive$: IValueSubject<boolean>;
|
|
46
45
|
isActiveLive$: IValueSubject<boolean>;
|
|
47
46
|
isLowLatency$: IValueSubject<boolean>;
|
|
@@ -82,7 +81,6 @@ export declare class Player {
|
|
|
82
81
|
getStreams(): Manifest['streams'] | undefined;
|
|
83
82
|
setPreloadOnly(preloadOnly: boolean): void;
|
|
84
83
|
destroy(): void;
|
|
85
|
-
private initTracerSubscription;
|
|
86
84
|
private isManualDecreasePlaybackInLive;
|
|
87
85
|
private normolizeLiveOffset;
|
|
88
86
|
private tick;
|
|
@@ -21,8 +21,6 @@ export default class ProviderContainer implements IProviderContainer {
|
|
|
21
21
|
private subscription;
|
|
22
22
|
private screenFormatsIterator;
|
|
23
23
|
private chromecastFormatsIterator;
|
|
24
|
-
private log;
|
|
25
|
-
private tracer;
|
|
26
24
|
private params;
|
|
27
25
|
private failoverIndex;
|
|
28
26
|
private volumeMultiplierManager;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ITuningConfig } from '../utils/tuningConfig';
|
|
2
|
-
import {
|
|
2
|
+
import { ISubject, IValueSubject, Milliseconds, Seconds, IRange, IError, QualityLimits, IWarning } from '@vkontakte/videoplayer-shared';
|
|
3
3
|
import { IChromecastInitializer } from '../providers/ChromecastProvider/ChromecastInitializer/types';
|
|
4
4
|
import { HttpConnectionType, IAudioStream, IAudioTrack, ICueSettings, ISources, IVideoStream, SeekState } from '../player/types';
|
|
5
5
|
import { IExternalTextTrack, IInternalTextTrack, ITextTrack, IVideoTrack, IVolumeState, PlaybackState, PlaybackRate } from '../player/types';
|
|
@@ -15,9 +15,6 @@ export interface IProviderDependencies {
|
|
|
15
15
|
dependencies: {
|
|
16
16
|
throughputEstimator: ThroughputEstimator;
|
|
17
17
|
chromecastInitializer: IChromecastInitializer;
|
|
18
|
-
logger: ILogger;
|
|
19
|
-
tracer: ITracer;
|
|
20
|
-
abrLogger: IComponentLogger;
|
|
21
18
|
};
|
|
22
19
|
}
|
|
23
20
|
export interface IProviderParams<TSourceType> extends IProviderDependencies {
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import { type ExactVideoQuality,
|
|
1
|
+
import { type ExactVideoQuality, IObservable, Subject } from '@vkontakte/videoplayer-shared';
|
|
2
2
|
import { ITuningConfig } from '../../../utils/tuningConfig';
|
|
3
3
|
import { IVideoTrack } from '../../../player/types';
|
|
4
4
|
import { IStateMachine } from '../../../utils/StateMachine/types';
|
|
5
5
|
interface IConnectData {
|
|
6
|
-
logger: ILogger;
|
|
7
6
|
video: HTMLVideoElement;
|
|
8
7
|
tracks: IVideoTrack[];
|
|
9
8
|
droppedFramesChecker: ITuningConfig['droppedFramesChecker'];
|
|
@@ -14,7 +13,6 @@ interface IConnectData {
|
|
|
14
13
|
declare class DroppedFramesManager {
|
|
15
14
|
onDroopedVideoFramesLimit$: Subject<void>;
|
|
16
15
|
private subscription;
|
|
17
|
-
private log;
|
|
18
16
|
private video;
|
|
19
17
|
private droppedFramesChecker;
|
|
20
18
|
private isAuto;
|
|
@@ -6,6 +6,7 @@ export interface IObservableVideo {
|
|
|
6
6
|
canplay$: IObservable<undefined>;
|
|
7
7
|
ended$: IObservable<undefined>;
|
|
8
8
|
looped$: IObservable<Seconds>;
|
|
9
|
+
loopExpected$: IObservable<undefined>;
|
|
9
10
|
error$: IObservable<IError>;
|
|
10
11
|
seeked$: IObservable<undefined>;
|
|
11
12
|
seeking$: IObservable<undefined>;
|
|
@@ -23,5 +24,6 @@ export interface IObservableVideo {
|
|
|
23
24
|
inFullscreen$: IValueObservable<boolean>;
|
|
24
25
|
enterPip$: IObservable<PictureInPictureEvent>;
|
|
25
26
|
leavePip$: IObservable<PictureInPictureEvent>;
|
|
27
|
+
destroy: () => void;
|
|
26
28
|
}
|
|
27
29
|
export declare const observe: (video: HTMLVideoElement) => IObservableVideo;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ITuningConfig } from '../utils/tuningConfig';
|
|
2
|
-
import { Kbps, Milliseconds, IRectangle, type ExactVideoQuality, QualityLimits
|
|
2
|
+
import { Kbps, Milliseconds, IRectangle, type ExactVideoQuality, QualityLimits } from '@vkontakte/videoplayer-shared';
|
|
3
3
|
import { IAudioTrack, IBaseTrack, IVideoTrack } from '../player/types';
|
|
4
4
|
interface IConstraints<T extends IBaseTrack> {
|
|
5
5
|
container?: IRectangle;
|
|
@@ -15,7 +15,6 @@ interface IConstraints<T extends IBaseTrack> {
|
|
|
15
15
|
droppedVideoMaxQualityLimit?: ExactVideoQuality;
|
|
16
16
|
stallsVideoMaxQualityLimit?: ExactVideoQuality;
|
|
17
17
|
stallsPredictedThroughput?: Kbps;
|
|
18
|
-
abrLogger: IComponentLogger;
|
|
19
18
|
}
|
|
20
19
|
export declare class TrackHistory<T extends IBaseTrack> {
|
|
21
20
|
last: T | undefined;
|
|
@@ -26,6 +25,6 @@ export declare class TrackHistory<T extends IBaseTrack> {
|
|
|
26
25
|
}
|
|
27
26
|
export declare const defaultEmptyArrayErrorMessage = "Assertion \"ABR Tracks is empty array\" failed";
|
|
28
27
|
export declare const getMinPossibleAudioForVideo: (videoTrack: IVideoTrack, videoTracks: IVideoTrack[], audioTracks: IAudioTrack[], minVideoAudioRatio: number) => IAudioTrack | undefined;
|
|
29
|
-
export declare const autoSelectVideoTrack: (videoTracks: IVideoTrack[], { container, estimatedThroughput, tuning, limits, reserve, forwardBufferHealth, playbackRate, current, history, visible, droppedVideoMaxQualityLimit, stallsVideoMaxQualityLimit, stallsPredictedThroughput,
|
|
30
|
-
export declare const autoSelectAudioTrackForVideo: (selectedVideoTrack: IVideoTrack, videoTracks: IVideoTrack[], audioTracks: IAudioTrack[], { estimatedThroughput, tuning, playbackRate, forwardBufferHealth, history,
|
|
28
|
+
export declare const autoSelectVideoTrack: (videoTracks: IVideoTrack[], { container, estimatedThroughput, tuning, limits, reserve, forwardBufferHealth, playbackRate, current, history, visible, droppedVideoMaxQualityLimit, stallsVideoMaxQualityLimit, stallsPredictedThroughput, }: IConstraints<IVideoTrack>) => IVideoTrack;
|
|
29
|
+
export declare const autoSelectAudioTrackForVideo: (selectedVideoTrack: IVideoTrack, videoTracks: IVideoTrack[], audioTracks: IAudioTrack[], { estimatedThroughput, tuning, playbackRate, forwardBufferHealth, history, stallsPredictedThroughput, }: IConstraints<IAudioTrack>) => IAudioTrack | undefined;
|
|
31
30
|
export {};
|
|
@@ -2,9 +2,6 @@ import { ISmoothedValue, IParams } from '../../utils/smoothedValue/types';
|
|
|
2
2
|
import { IValueSubject } from '@vkontakte/videoplayer-shared';
|
|
3
3
|
export declare abstract class BaseSmoothedValue implements ISmoothedValue {
|
|
4
4
|
private prevReported;
|
|
5
|
-
private rawSeries$;
|
|
6
|
-
private smoothedSeries$;
|
|
7
|
-
private reportedSeries$;
|
|
8
5
|
protected smoothed: number;
|
|
9
6
|
protected pastMeasures: number[];
|
|
10
7
|
protected takenMeasures: number;
|
|
@@ -81,6 +81,8 @@ export type ITuningConfig = {
|
|
|
81
81
|
};
|
|
82
82
|
enableBaseUrlSupport: boolean;
|
|
83
83
|
maxSegmentRetryCount: number;
|
|
84
|
+
sourceOpenTimeout: number;
|
|
85
|
+
rejectOnSourceOpenTimeout: boolean;
|
|
84
86
|
};
|
|
85
87
|
dashCmafLive: {
|
|
86
88
|
maxActiveLiveOffset: Milliseconds;
|
|
@@ -144,6 +146,7 @@ export type ITuningConfig = {
|
|
|
144
146
|
stripRangeHeader: boolean;
|
|
145
147
|
flushShortLoopedBuffers: boolean;
|
|
146
148
|
insufficientBufferRuleMargin: Milliseconds;
|
|
149
|
+
seekNearDurationBias: Seconds;
|
|
147
150
|
dashSeekInSegmentDurationThreshold: Milliseconds;
|
|
148
151
|
dashSeekInSegmentAlwaysSeekDelta: Milliseconds;
|
|
149
152
|
endGapTolerance: Milliseconds;
|