@vkontakte/videoplayer-core 2.0.154-dev.48c0527e.0 → 2.0.154-dev.6d21d9b3.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 +184 -0
- package/es2015.esm.js +184 -0
- package/es2018.cjs +131 -77
- package/es2018.esm.js +129 -75
- package/es2024.cjs +135 -81
- package/es2024.esm.js +133 -79
- package/esnext.cjs +135 -81
- package/esnext.esm.js +133 -79
- package/evergreen.esm.js +134 -80
- package/package.json +2 -2
- package/types/enums/AndroidPreferredFormat.d.ts +6 -6
- package/types/enums/IOSPreferredFormat.d.ts +2 -2
- package/types/enums/WebmCodecStrategy.d.ts +5 -5
- package/types/index.d.ts +13 -16
- package/types/player/Player.d.ts +210 -217
- package/types/player/types.d.ts +589 -589
- package/types/player/utils/optimisticPosition.d.ts +7 -7
- package/types/player/utils/selectContainer.d.ts +1 -1
- package/types/providers/ChromecastPresentationApiProvider/ChromecastPresentationApiConnector.d.ts +106 -106
- package/types/providers/ChromecastPresentationApiProvider/ChromecastPresentationApiInitializer.d.ts +23 -23
- package/types/providers/ChromecastPresentationApiProvider/ChromecastPresentationApiProvider.d.ts +34 -34
- package/types/providers/ChromecastPresentationApiProvider/ProgressTicker.d.ts +9 -9
- package/types/providers/ChromecastPresentationApiProvider/index.d.ts +3 -3
- package/types/providers/ChromecastPresentationApiProvider/types.d.ts +31 -31
- package/types/providers/ChromecastPresentationApiProvider/utils.d.ts +1 -1
- package/types/providers/ChromecastProvider/ChromecastInitializer/index.d.ts +22 -22
- package/types/providers/ChromecastProvider/ChromecastInitializer/types.d.ts +22 -22
- package/types/providers/ChromecastProvider/index.d.ts +23 -23
- package/types/providers/ChromecastProvider/types.d.ts +7 -7
- package/types/providers/ChromecastProvider/utils.d.ts +1 -1
- package/types/providers/DashLiveProvider/DashLiveProvider.d.ts +33 -32
- package/types/providers/DashLiveProvider/index.d.ts +1 -1
- package/types/providers/DashLiveProvider/types.d.ts +17 -17
- package/types/providers/DashLiveProvider/utils/FilesFetcher.d.ts +23 -23
- package/types/providers/DashLiveProvider/utils/LiveDashPlayer.d.ts +150 -149
- package/types/providers/DashLiveProvider/utils/ThroughputEstimator.d.ts +30 -12
- package/types/providers/DashLiveProvider/utils/liveDashPlayerUtil.d.ts +22 -19
- package/types/providers/DashProvider/baseDashProvider.d.ts +56 -56
- package/types/providers/DashProvider/dashCmafLiveProvider.d.ts +6 -6
- package/types/providers/DashProvider/dashProvider.d.ts +4 -4
- package/types/providers/DashProvider/index.d.ts +2 -2
- package/types/providers/DashProvider/lib/ElementSizeManager.d.ts +14 -14
- package/types/providers/DashProvider/lib/LiveTextManager.d.ts +21 -21
- package/types/providers/DashProvider/lib/buffer.d.ts +122 -123
- package/types/providers/DashProvider/lib/fetcher.d.ts +69 -70
- package/types/providers/DashProvider/lib/player.d.ts +107 -109
- package/types/providers/DashProvider/lib/sourceBufferTaskQueue.d.ts +17 -17
- package/types/providers/DashProvider/lib/types.d.ts +20 -20
- package/types/providers/DashProvider/lib/utils.d.ts +4 -4
- package/types/providers/DashProviderVirtual/baseDashProvider.d.ts +57 -57
- package/types/providers/DashProviderVirtual/consts.d.ts +2 -2
- package/types/providers/DashProviderVirtual/dashCmafLiveProvider.d.ts +8 -8
- package/types/providers/DashProviderVirtual/dashProvider.d.ts +6 -6
- package/types/providers/DashProviderVirtual/index.d.ts +2 -2
- package/types/providers/DashProviderVirtual/lib/ElementSizeManager.d.ts +14 -15
- package/types/providers/DashProviderVirtual/lib/LiveTextManager.d.ts +21 -21
- package/types/providers/DashProviderVirtual/lib/buffer/nativeBufferManager.d.ts +17 -17
- package/types/providers/DashProviderVirtual/lib/buffer/sourceBufferTaskQueue.d.ts +17 -17
- package/types/providers/DashProviderVirtual/lib/buffer/types.d.ts +39 -39
- package/types/providers/DashProviderVirtual/lib/buffer/virtualBuffer/baseVirtualBufferManager.d.ts +92 -94
- package/types/providers/DashProviderVirtual/lib/buffer/virtualBuffer/byteRangeVirtualBufferManager.d.ts +19 -19
- package/types/providers/DashProviderVirtual/lib/buffer/virtualBuffer/liveVirtualBuffer.d.ts +25 -25
- package/types/providers/DashProviderVirtual/lib/buffer/virtualBuffer/templateVirtualBufferManager.d.ts +19 -19
- package/types/providers/DashProviderVirtual/lib/buffer/virtualBuffer/virtualBufferFactory.d.ts +4 -4
- package/types/providers/DashProviderVirtual/lib/fetcher.d.ts +67 -68
- package/types/providers/DashProviderVirtual/lib/player/basePlayer.d.ts +100 -103
- package/types/providers/DashProviderVirtual/lib/player/livePlayer.d.ts +34 -34
- package/types/providers/DashProviderVirtual/lib/player/player.d.ts +9 -9
- package/types/providers/DashProviderVirtual/lib/player/types.d.ts +13 -13
- package/types/providers/DashProviderVirtual/lib/types.d.ts +20 -20
- package/types/providers/DashProviderVirtual/lib/utils.d.ts +4 -4
- package/types/providers/HlsLiveProvider/LiveTextManager.d.ts +35 -35
- package/types/providers/HlsLiveProvider/index.d.ts +28 -28
- package/types/providers/HlsLiveProvider/seekBackTimeExtractor.d.ts +1 -1
- package/types/providers/HlsProvider/index.d.ts +19 -18
- package/types/providers/HlsProvider/manifestDataExtractor.d.ts +13 -13
- package/types/providers/MpegProvider/index.d.ts +17 -16
- package/types/providers/ProviderContainer/index.d.ts +46 -45
- package/types/providers/ProviderContainer/types.d.ts +16 -16
- package/types/providers/ProviderContainer/utils/formatsSupport.d.ts +9 -9
- package/types/providers/ProviderContainer/utils/playbackHangup.d.ts +8 -9
- package/types/providers/WebRTCLiveProvider/WebRTCLiveClient.d.ts +185 -185
- package/types/providers/WebRTCLiveProvider/WebRTCLiveProvider.d.ts +57 -57
- package/types/providers/WebRTCLiveProvider/interface/WebRTCLiveClientOptions.d.ts +6 -6
- package/types/providers/types.d.ts +103 -102
- package/types/providers/utils/HTMLVideoElement/DroppedFramesManager.d.ts +39 -40
- package/types/providers/utils/HTMLVideoElement/TextTrackManager.d.ts +28 -28
- package/types/providers/utils/HTMLVideoElement/forcePlay.d.ts +5 -5
- package/types/providers/utils/HTMLVideoElement/observable.d.ts +25 -25
- package/types/providers/utils/HTMLVideoElement/pool.d.ts +2 -2
- package/types/providers/utils/LiveOffset/index.d.ts +12 -12
- package/types/providers/utils/LiveOffset/types.d.ts +8 -8
- package/types/providers/utils/StallsManager.d.ts +49 -49
- package/types/providers/utils/debug.d.ts +12 -13
- package/types/providers/utils/extractConnectionHeaders.d.ts +3 -3
- package/types/providers/utils/generateLiveUrl.d.ts +4 -4
- package/types/providers/utils/guessNetworkErrorCause.d.ts +1 -1
- package/types/providers/utils/mergeIntervals.d.ts +1 -1
- package/types/providers/utils/okQualityStringToVideoQuality.d.ts +1 -1
- package/types/providers/utils/parsers/ietf/index.d.ts +8 -8
- package/types/providers/utils/parsers/index.d.ts +1 -1
- package/types/providers/utils/parsers/mpd.d.ts +1 -1
- package/types/providers/utils/parsers/mpeg/BoxModel.d.ts +17 -18
- package/types/providers/utils/parsers/mpeg/BoxParser.d.ts +15 -15
- package/types/providers/utils/parsers/mpeg/BoxTypeEnum.d.ts +27 -27
- package/types/providers/utils/parsers/mpeg/box.d.ts +68 -68
- package/types/providers/utils/parsers/mpeg/boxes/avc1.d.ts +5 -5
- package/types/providers/utils/parsers/mpeg/boxes/equi.d.ts +18 -18
- package/types/providers/utils/parsers/mpeg/boxes/ftyp.d.ts +14 -14
- package/types/providers/utils/parsers/mpeg/boxes/index.d.ts +26 -27
- package/types/providers/utils/parsers/mpeg/boxes/mdat.d.ts +12 -12
- package/types/providers/utils/parsers/mpeg/boxes/mdia.d.ts +5 -5
- package/types/providers/utils/parsers/mpeg/boxes/mfhd.d.ts +8 -8
- package/types/providers/utils/parsers/mpeg/boxes/minf.d.ts +5 -5
- package/types/providers/utils/parsers/mpeg/boxes/moof.d.ts +5 -5
- package/types/providers/utils/parsers/mpeg/boxes/moov.d.ts +5 -5
- package/types/providers/utils/parsers/mpeg/boxes/mvhd.d.ts +32 -32
- package/types/providers/utils/parsers/mpeg/boxes/prhd.d.ts +13 -13
- package/types/providers/utils/parsers/mpeg/boxes/proj.d.ts +5 -5
- package/types/providers/utils/parsers/mpeg/boxes/sidx.d.ts +43 -43
- package/types/providers/utils/parsers/mpeg/boxes/st3d.d.ts +16 -16
- package/types/providers/utils/parsers/mpeg/boxes/stbl.d.ts +5 -5
- package/types/providers/utils/parsers/mpeg/boxes/stsd.d.ts +8 -8
- package/types/providers/utils/parsers/mpeg/boxes/sv3d.d.ts +5 -5
- package/types/providers/utils/parsers/mpeg/boxes/tfdt.d.ts +14 -14
- package/types/providers/utils/parsers/mpeg/boxes/tfhd.d.ts +19 -19
- package/types/providers/utils/parsers/mpeg/boxes/tkhd.d.ts +39 -39
- package/types/providers/utils/parsers/mpeg/boxes/traf.d.ts +5 -5
- package/types/providers/utils/parsers/mpeg/boxes/trak.d.ts +5 -5
- package/types/providers/utils/parsers/mpeg/boxes/trun.d.ts +28 -28
- package/types/providers/utils/parsers/mpeg/boxes/unknown.d.ts +5 -4
- package/types/providers/utils/parsers/mpeg/boxes/uuid.d.ts +10 -10
- package/types/providers/utils/parsers/mpeg/fullBox.d.ts +12 -12
- package/types/providers/utils/parsers/mpeg/isobmff.d.ts +7 -7
- package/types/providers/utils/parsers/types.d.ts +133 -131
- package/types/providers/utils/parsers/webm/ebml.d.ts +62 -62
- package/types/providers/utils/parsers/webm/webm.d.ts +1 -1
- package/types/providers/utils/restorePlaybackRateInSafari.d.ts +17 -17
- package/types/providers/utils/syncDesiredState.d.ts +12 -8
- package/types/providers/utils/syncPlaybackState.d.ts +2 -2
- package/types/providers/utils/videoStreamRepresentaionsFilter.d.ts +2 -2
- package/types/utils/3d/Camera3D.d.ts +11 -11
- package/types/utils/3d/CameraRotationManager.d.ts +59 -59
- package/types/utils/3d/Scene3D.d.ts +129 -129
- package/types/utils/3d/types.d.ts +14 -14
- package/types/utils/ClientChecker/ClientChecker.d.ts +19 -19
- package/types/utils/ClientChecker/index.d.ts +2 -2
- package/types/utils/ClientChecker/services/AudioChecker.d.ts +7 -7
- package/types/utils/ClientChecker/services/BrowserChecker.d.ts +36 -36
- package/types/utils/ClientChecker/services/DeviceChecker.d.ts +38 -38
- package/types/utils/ClientChecker/services/DisplayChecker.d.ts +20 -20
- package/types/utils/ClientChecker/services/VideoChecker.d.ts +35 -35
- package/types/utils/ClientChecker/types/checker.d.ts +1 -1
- package/types/utils/ClientChecker/types/currentClientBrowser.d.ts +10 -10
- package/types/utils/ClientChecker/types/currentClientDevice.d.ts +8 -8
- package/types/utils/ClientChecker/types/userAgentData.d.ts +21 -21
- package/types/utils/StateMachine/StateMachine.d.ts +17 -17
- package/types/utils/StateMachine/types.d.ts +56 -56
- package/types/utils/StatefulIterator/index.d.ts +13 -13
- package/types/utils/ThroughputEstimator.d.ts +22 -22
- package/types/utils/VolumeMultiplierManager/VolumeMultiplierManager.d.ts +20 -20
- package/types/utils/VolumeMultiplierManager/index.d.ts +1 -1
- package/types/utils/autoSelectTrack.d.ts +27 -28
- package/types/utils/buffer/createTimeRanges.d.ts +1 -2
- package/types/utils/buffer/getBufferedRangeForPosition.d.ts +2 -2
- package/types/utils/buffer/getForwardBufferDuration.d.ts +1 -1
- package/types/utils/buffer/getTotalBufferDuration.d.ts +1 -1
- package/types/utils/buffer/isPositionBuffered.d.ts +1 -1
- package/types/utils/buffer/isSourceBufferValid.d.ts +1 -1
- package/types/utils/changePlaybackRate.d.ts +1 -1
- package/types/utils/decodingInfoLogger.d.ts +1 -1
- package/types/utils/mediaSource.d.ts +5 -1
- package/types/utils/observeElementVisibility.d.ts +1 -1
- package/types/utils/playbackTelemetry.d.ts +4 -4
- package/types/utils/playerOptions.d.ts +3 -3
- package/types/utils/qualityLimits.d.ts +14 -15
- package/types/utils/setStateWithSubscribe.d.ts +3 -6
- package/types/utils/smoothedValue/baseSmoothedValue.d.ts +16 -16
- package/types/utils/smoothedValue/emaAndMaSmoothedValue.d.ts +5 -5
- package/types/utils/smoothedValue/emaTopExtremumValue.d.ts +8 -8
- package/types/utils/smoothedValue/smoothedValueFactory.d.ts +4 -4
- package/types/utils/smoothedValue/twoEmaSmoothedValue.d.ts +6 -6
- package/types/utils/smoothedValue/types.d.ts +16 -16
- package/types/utils/tuningConfig.d.ts +275 -276
- package/types/utils/videoFormat.d.ts +1 -1
|
@@ -1,4 +1,8 @@
|
|
|
1
|
-
export declare const getWindowMediaSource: () =>
|
|
1
|
+
export declare const getWindowMediaSource: () => {
|
|
2
|
+
new (): ManagedMediaSource;
|
|
3
|
+
prototype: ManagedMediaSource;
|
|
4
|
+
isTypeSupported(type: string): boolean;
|
|
5
|
+
};
|
|
2
6
|
export declare const isManagedMediaSourceSupported: () => boolean;
|
|
3
7
|
export declare const isMediaSourceSupported: () => boolean;
|
|
4
8
|
export declare const getMediaSource: () => MediaSource | ManagedMediaSource;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { IObservable } from '@vkontakte/videoplayer-shared';
|
|
2
2
|
declare const observeElementVisibility: (element: Element, options?: IntersectionObserverInit) => IObservable<boolean>;
|
|
3
3
|
export default observeElementVisibility;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { IEmitter } from '@vkontakte/videoplayer-shared';
|
|
2
2
|
declare let store: Record<string, any>;
|
|
3
3
|
export declare const setEnabled: (value: boolean) => void;
|
|
4
4
|
export declare const clear: () => void;
|
|
5
5
|
export declare const dump: (receiver: (value: typeof store) => void) => void;
|
|
6
6
|
export declare const storeMeta: (name: string, value: unknown) => void;
|
|
7
7
|
export declare class TimeSeries<Value> implements IEmitter<Value> {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
8
|
+
private name;
|
|
9
|
+
constructor(name: string);
|
|
10
|
+
next(value: Value): void;
|
|
11
11
|
}
|
|
12
12
|
export {};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { DevNullEntry } from '@vkontakte/videoplayer-shared';
|
|
2
2
|
export type IPlayerOptions = {
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
playerId?: string;
|
|
4
|
+
onDevNullLog?: (entry: DevNullEntry) => void;
|
|
5
5
|
};
|
|
@@ -1,23 +1,22 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import type { ExactVideoQuality, Nullable, QualityLimits } from "@vkontakte/videoplayer-shared";
|
|
1
|
+
import { IVideoTrack, PredefinedQualityLimits } from '../player/types';
|
|
2
|
+
import { ExactVideoQuality, Nullable, QualityLimits } from '@vkontakte/videoplayer-shared';
|
|
4
3
|
export declare function getQualityLimitsPredefinedType(limits: QualityLimits, highQualityLimit: ExactVideoQuality, trafficSavingLimit: ExactVideoQuality): PredefinedQualityLimits;
|
|
5
4
|
type LimitsAsHeightValidParams = {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
5
|
+
limits?: {
|
|
6
|
+
min?: number;
|
|
7
|
+
max?: number;
|
|
8
|
+
};
|
|
9
|
+
highestAvailableHeight: Nullable<number>;
|
|
10
|
+
lowestAvailableHeight: Nullable<number>;
|
|
12
11
|
};
|
|
13
|
-
export declare function areLimitsInvalid(limits: Nullable<QualityLimits>, highestAvailableQuality: Nullable<ExactVideoQuality>, lowestAvailableQuality: Nullable<ExactVideoQuality>): boolean;
|
|
12
|
+
export declare function areLimitsInvalid(limits: Nullable<QualityLimits>, highestAvailableQuality: Nullable<ExactVideoQuality>, lowestAvailableQuality: Nullable<ExactVideoQuality>): boolean | (null | undefined);
|
|
14
13
|
/**
|
|
15
|
-
* Проверяем лимиты качества, когда указана высота качества.
|
|
16
|
-
*/
|
|
17
|
-
export declare function areLimitsInvalidInHeights({ limits, highestAvailableHeight, lowestAvailableHeight }: LimitsAsHeightValidParams): boolean;
|
|
14
|
+
* Проверяем лимиты качества, когда указана высота качества.
|
|
15
|
+
*/
|
|
16
|
+
export declare function areLimitsInvalidInHeights({ limits, highestAvailableHeight, lowestAvailableHeight }: LimitsAsHeightValidParams): boolean | (null | undefined);
|
|
18
17
|
type TrackFitsLimitsParams = {
|
|
19
|
-
|
|
20
|
-
|
|
18
|
+
limits: QualityLimits;
|
|
19
|
+
track: IVideoTrack;
|
|
21
20
|
};
|
|
22
21
|
export declare function trackFitsLimits({ limits, track }: TrackFitsLimitsParams): boolean;
|
|
23
22
|
export {};
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
import type { IValueSubject } from
|
|
2
|
-
import type { IStateMachine } from
|
|
3
|
-
export declare const setStateWithSubscribe: <
|
|
4
|
-
State,
|
|
5
|
-
Value
|
|
6
|
-
>(nextState: State | undefined, currentState: IStateMachine<State | undefined>, availableValues: IValueSubject<Array<Value>> | undefined, predicate: (value: Value) => boolean) => void;
|
|
1
|
+
import type { IValueSubject } from '@vkontakte/videoplayer-shared';
|
|
2
|
+
import type { IStateMachine } from '../utils/StateMachine/types';
|
|
3
|
+
export declare const setStateWithSubscribe: <State, Value>(nextState: State | undefined, currentState: IStateMachine<State | undefined>, availableValues: IValueSubject<Array<Value>> | undefined, predicate: (value: Value) => boolean) => void;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
1
|
+
import { ISmoothedValue, IParams } from '../../utils/smoothedValue/types';
|
|
2
|
+
import { IValueSubject } from '@vkontakte/videoplayer-shared';
|
|
3
3
|
export declare abstract class BaseSmoothedValue implements ISmoothedValue {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
4
|
+
private prevReported;
|
|
5
|
+
private rawSeries$;
|
|
6
|
+
private smoothedSeries$;
|
|
7
|
+
private reportedSeries$;
|
|
8
|
+
protected smoothed: number;
|
|
9
|
+
protected pastMeasures: number[];
|
|
10
|
+
protected takenMeasures: number;
|
|
11
|
+
protected measuresCursor: number;
|
|
12
|
+
protected params: IParams;
|
|
13
|
+
smoothed$: IValueSubject<number>;
|
|
14
|
+
debounced$: IValueSubject<number>;
|
|
15
|
+
constructor(params: IParams);
|
|
16
|
+
protected abstract updateSmoothedValue(value: number): void;
|
|
17
|
+
next(value: number): void;
|
|
18
18
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { BaseSmoothedValue } from
|
|
1
|
+
import { IEmaAndMaParams } from '../../utils/smoothedValue/types';
|
|
2
|
+
import { BaseSmoothedValue } from '../../utils/smoothedValue/baseSmoothedValue';
|
|
3
3
|
export declare class EmaAndMaSmoothedValue extends BaseSmoothedValue {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
4
|
+
private emaSmoothed;
|
|
5
|
+
constructor(params: IEmaAndMaParams);
|
|
6
|
+
protected updateSmoothedValue(value: number): void;
|
|
7
7
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { BaseSmoothedValue } from
|
|
2
|
-
import
|
|
1
|
+
import { BaseSmoothedValue } from '../../utils/smoothedValue/baseSmoothedValue';
|
|
2
|
+
import { IEmaTopExtremumParams } from '../../utils/smoothedValue/types';
|
|
3
3
|
export declare class EmaTopExtremumValue extends BaseSmoothedValue {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
4
|
+
private readonly extremumInterval;
|
|
5
|
+
private furtherValues;
|
|
6
|
+
private currentTopExtremumValue;
|
|
7
|
+
constructor(params: IEmaTopExtremumParams);
|
|
8
|
+
next(value: number): void;
|
|
9
|
+
protected updateSmoothedValue(value: number): void;
|
|
10
10
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
1
|
+
import { ITuningConfig } from '../../utils/tuningConfig';
|
|
2
|
+
import { ISmoothedValue } from '../../utils/smoothedValue/types';
|
|
3
3
|
export declare class SmoothedValueFactory {
|
|
4
|
-
|
|
5
|
-
|
|
4
|
+
static getSmoothedValue(initialThroughput: number, fastDirection: 1 | -1, tuning: ITuningConfig['throughputEstimator']): ISmoothedValue;
|
|
5
|
+
static getLiveBufferSmoothedValue(initialBufferLength: number, tuning: ITuningConfig['dashCmafLive']['lowLatency']['bufferEstimator']): ISmoothedValue;
|
|
6
6
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { BaseSmoothedValue } from
|
|
1
|
+
import { ITwoEmaParams } from '../../utils/smoothedValue/types';
|
|
2
|
+
import { BaseSmoothedValue } from '../../utils/smoothedValue/baseSmoothedValue';
|
|
3
3
|
export declare class TwoEmaSmoothedValue extends BaseSmoothedValue {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
4
|
+
private slow;
|
|
5
|
+
private fast;
|
|
6
|
+
constructor(params: ITwoEmaParams);
|
|
7
|
+
protected updateSmoothedValue(value: number): void;
|
|
8
8
|
}
|
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { IValueSubject } from '@vkontakte/videoplayer-shared';
|
|
2
2
|
export interface IParams {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
3
|
+
initial: number;
|
|
4
|
+
changeThreshold: number;
|
|
5
|
+
deviationDepth: number;
|
|
6
|
+
deviationFactor: number;
|
|
7
|
+
label?: string;
|
|
8
8
|
}
|
|
9
9
|
export interface IEmaAndMaParams extends IParams {
|
|
10
|
-
|
|
11
|
-
|
|
10
|
+
emaAlpha: number;
|
|
11
|
+
basisTrendChangeCount: number;
|
|
12
12
|
}
|
|
13
13
|
export interface ITwoEmaParams extends IParams {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
emaAlphaSlow: number;
|
|
15
|
+
emaAlphaFast: number;
|
|
16
|
+
fastDirection: 1 | -1;
|
|
17
17
|
}
|
|
18
18
|
export interface IEmaTopExtremumParams extends IParams {
|
|
19
|
-
|
|
20
|
-
|
|
19
|
+
emaAlpha: number;
|
|
20
|
+
extremumInterval: number;
|
|
21
21
|
}
|
|
22
22
|
export interface ISmoothedValue {
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
23
|
+
smoothed$: IValueSubject<number>;
|
|
24
|
+
debounced$: IValueSubject<number>;
|
|
25
|
+
next(value: number): void;
|
|
26
26
|
}
|