@vkontakte/videoplayer-core 2.0.113-dev.53b63d90.0 → 2.0.113-dev.85777574.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 +16 -16
- package/es2015.esm.js +16 -16
- package/es2018.cjs.js +17 -17
- package/es2018.esm.js +17 -17
- package/esnext.cjs.js +10 -10
- package/esnext.esm.js +9 -9
- package/evergreen.esm.js +10 -10
- package/package.json +2 -2
- package/types/providers/DashProvider/baseDashProvider.d.ts +6 -0
- package/types/providers/DashProvider/lib/LiveTextManager.d.ts +2 -0
- package/types/providers/DashProvider/lib/utils.d.ts +5 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vkontakte/videoplayer-core",
|
|
3
|
-
"version": "2.0.113-dev.
|
|
3
|
+
"version": "2.0.113-dev.85777574.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": "1.0.45-dev.
|
|
52
|
+
"@vkontakte/videoplayer-shared": "1.0.45-dev.74fc43b7.0",
|
|
53
53
|
"hls.js": "~1.4.7"
|
|
54
54
|
}
|
|
55
55
|
}
|
|
@@ -8,6 +8,7 @@ import { Player } from './lib/player';
|
|
|
8
8
|
import { ILiveOffset } from '../utils/LiveOffset/types';
|
|
9
9
|
import { Scene3D } from '../../utils/3d/Scene3D';
|
|
10
10
|
import DroppedFramesManager from '../../providers/utils/HTMLVideoElement/DroppedFramesManager';
|
|
11
|
+
import TextTrackManager from '../../providers/utils/HTMLVideoElement/TextTrackManager';
|
|
11
12
|
type IParams = IProviderParams<IDashURLSource> & {
|
|
12
13
|
sourceHls?: IHLSSource;
|
|
13
14
|
};
|
|
@@ -20,6 +21,7 @@ export default abstract class BaseDashProvider implements IProvider {
|
|
|
20
21
|
protected params: IParams;
|
|
21
22
|
protected tracer: ITracer;
|
|
22
23
|
protected elementSize$: ValueSubject<IRectangle<number> | undefined>;
|
|
24
|
+
protected textTracksManager: TextTrackManager | null;
|
|
23
25
|
protected droppedFramesManager: DroppedFramesManager;
|
|
24
26
|
protected videoTracksMap: Map<IVideoTrack, {
|
|
25
27
|
stream: Stream;
|
|
@@ -29,6 +31,10 @@ export default abstract class BaseDashProvider implements IProvider {
|
|
|
29
31
|
stream: Stream;
|
|
30
32
|
representation: Representation;
|
|
31
33
|
}>;
|
|
34
|
+
protected textTracksMap: Map<IInternalTextTrack, {
|
|
35
|
+
stream: Stream;
|
|
36
|
+
representation: Representation;
|
|
37
|
+
}>;
|
|
32
38
|
protected videoStreamsMap: Map<Stream, IVideoTrack[]>;
|
|
33
39
|
protected audioStreamsMap: Map<Stream, IAudioTrack[]>;
|
|
34
40
|
protected videoTrackSwitchHistory: TrackHistory<IVideoTrack>;
|
|
@@ -3,6 +3,8 @@ import { Dependencies } from './buffer';
|
|
|
3
3
|
import { Manifest, Stream, TextRepresentation } from './types';
|
|
4
4
|
export declare class LiveTextManager {
|
|
5
5
|
currentRepresentation$: IValueSubject<TextRepresentation | null>;
|
|
6
|
+
private readonly maxRepresentations;
|
|
7
|
+
private representationsCursor;
|
|
6
8
|
private representations;
|
|
7
9
|
private readonly getCurrentPosition;
|
|
8
10
|
private currentSegment;
|
|
@@ -3,7 +3,11 @@ import { IAudioStream, IAudioTrack, IInternalTextTrack, IVideoStream, IVideoTrac
|
|
|
3
3
|
export declare const representationToVideoTrack: ({ id, width, height, bitrate, fps, quality: qualityString }: Representation) => IVideoTrack | undefined;
|
|
4
4
|
export declare const representationToAudioTrack: ({ id, bitrate }: Representation) => IAudioTrack;
|
|
5
5
|
export declare const selectAudioForVideo: (videoTrack: IVideoTrack, videoTracks: IVideoTrack[], audioTracks: IAudioTrack[]) => IAudioTrack | undefined;
|
|
6
|
-
export declare const representationToTextTrack: ({ language, label, id, url, isAuto }:
|
|
6
|
+
export declare const representationToTextTrack: ({ language, label }: Stream, { id, url, isAuto }: Representation & {
|
|
7
|
+
url: string;
|
|
8
|
+
isAuto: boolean;
|
|
9
|
+
}) => IInternalTextTrack;
|
|
10
|
+
export declare const textRepresentationToTextTrack: ({ language, label, id, url, isAuto }: TextRepresentation) => IInternalTextTrack;
|
|
7
11
|
export declare const streamToIAudioStream: ({ id, language, label, codecs, isDefault }: Stream) => IAudioStream;
|
|
8
12
|
export declare const streamToIVideoStream: ({ id, language, label, hdr, codecs }: Stream) => IVideoStream;
|
|
9
13
|
export declare const isTemplateSegment: (segment: Segment) => segment is TemplateSegment;
|